Beispiel #1
0
if len(argv) > 1 and argv[1] == '--upload-to':
	updateDirectory = argv[2]
	argv[1:3] = []
else:
	updateDirectory = '/var/www/update/'

def stripPrecompiled(string):
	if string.startswith('precompiled/'):
		return string[12:]
	return string

files = [stripPrecompiled(file) for file in argv[1:]]

Updater.MAIN_URL = 'file:' + updateDirectory
downloader = XMLFileDownloader()
downloader.start()
reader = XMLFileReader(downloader.getInputStream(), 0)

progress = StderrProgress()
checksummer = Checksummer(progress)
plugins = PluginCollection.getInstance()
if len(files) == 0:
	checksummer.updateFromLocal()
else:
	if files[0] == '--auto':
		automatic = True
		files = files[1:]
	else:
		automatic = False
	checksummer.updateFromLocal(files)
Beispiel #2
0
if len(argv) > 1 and argv[1] == '--upload-to':
	updateDirectory = argv[2]
	argv[1:3] = []
else:
	updateDirectory = '/var/www/update/'

def stripPrecompiled(string):
	if string.startswith('precompiled/'):
		return string[12:]
	return string

files = [stripPrecompiled(file) for file in argv[1:]]

Updater.MAIN_URL = 'file:' + updateDirectory
downloader = XMLFileDownloader()
downloader.start()
plugins = PluginCollection()

progress = StderrProgress()
checksummer = Checksummer(progress)
if len(files) == 0:
	checksummer.updateFromLocal()
else:
	if files[0] == '--auto':
		automatic = True
		files = files[1:]
	else:
		automatic = False
	checksummer.updateFromLocal(files)
	# check dependencies
Beispiel #3
0
    updateDirectory = argv[2]
    argv[1:3] = []
else:
    updateDirectory = '/var/www/update/'


def stripPrecompiled(string):
    if string.startswith('precompiled/'):
        return string[12:]
    return string


files = [stripPrecompiled(file) for file in argv[1:]]

Updater.MAIN_URL = 'file:' + updateDirectory
downloader = XMLFileDownloader()
downloader.start()
plugins = PluginCollection()

progress = StderrProgress()
checksummer = Checksummer(progress)
if len(files) == 0:
    checksummer.updateFromLocal()
else:
    if files[0] == '--auto':
        automatic = True
        files = files[1:]
    else:
        automatic = False
    checksummer.updateFromLocal(files)
    # check dependencies