def upload_binary(is_stable=False): ''' Upload binary version to site ''' facts = BuildFacts() if is_stable: win_tpl_files = FILES_FOR_UPLOAD_STABLE_WIN linux_tpl_files = FILES_FOR_UPLOAD_STABLE_LINUX deploy_path = DEPLOY_STABLE_PATH else: win_tpl_files = FILES_FOR_UPLOAD_UNSTABLE_WIN linux_tpl_files = FILES_FOR_UPLOAD_UNSTABLE_LINUX deploy_path = DEPLOY_UNSTABLE_PATH versions_file = facts.versions_file windows_result_path = os.path.join(PATH_TO_WINDOWS_DISTRIBS, facts.version, WINDOWS_BUILD_DIR) binary_uploader = BinaryUploader(win_tpl_files, linux_tpl_files, windows_result_path, versions_file, deploy_path) binary_uploader.deploy()
def __init__(self, version: str, is_stable: bool, windows_binary_path: str, deploy_path: str): self.deploy_path = deploy_path self.facts = BuildFacts() if is_stable: win_tpl_files = FILES_FOR_UPLOAD_STABLE_WIN linux_tpl_files = FILES_FOR_UPLOAD_STABLE_LINUX else: win_tpl_files = FILES_FOR_UPLOAD_UNSTABLE_WIN linux_tpl_files = FILES_FOR_UPLOAD_UNSTABLE_LINUX files_for_upload_win = [fname.format(version=version[0], build=version[1]) for fname in win_tpl_files] files_for_upload_linux = [fname.format(version=version[0], build=version[1]) for fname in linux_tpl_files] upload_files_win = [os.path.join( windows_binary_path, item) for item in files_for_upload_win] upload_files_linux = [os.path.join(self.facts.build_dir_linux, item) for item in files_for_upload_linux] self.upload_files = upload_files_win + upload_files_linux
def __init__(self, c: Context, subdir_name, is_stable=False): self.context = c self.is_stable = is_stable self.facts = BuildFacts() self.build_dir = os.path.join(self.facts.version_dir, subdir_name) self.temp_sources_dir = os.path.join(self.facts.temp_dir, 'src')
def upload_distribs(is_stable=False): ''' Upload binary version to site ''' facts = BuildFacts() version = getOutwikerVersion() if is_stable: deploy_path = DEPLOY_STABLE_PATH else: deploy_path = DEPLOY_UNSTABLE_PATH windows_binary_path = os.path.join(PATH_TO_WINDOWS_DISTRIBS, facts.version) binary_uploader = DistribsUploader(version, is_stable, windows_binary_path, deploy_path) print_info('Uploading distribs to {}...'.format(DEPLOY_SERVER_NAME)) binary_uploader.deploy()
def display_version(): """Display current version""" print('Current OutWiker version: {}'.format(BuildFacts().version))
def __init__(self, subdir_name, is_stable=False): self.is_stable = is_stable self.facts = BuildFacts(BUILD_DIR) self.build_dir = os.path.join(self.facts.version_dir, subdir_name) self.temp_sources_dir = os.path.join(self.facts.temp_dir, u'src')