コード例 #1
0
ファイル: custom.py プロジェクト: thh32/qiime-deploy
def deploy_denoiser(app, setup_dir):
    os.rmdir(app.deploy_dir)
    util.copytree(setup_dir, app.deploy_dir)

    srcName = 'FlowgramAli_4frame_linux_x86_64'
    srcPath = os.path.join(app.deploy_dir, 'FlowgramAlignment')
    srcPath = os.path.join(srcPath, srcName)

    destName = 'FlowgramAli_4frame'
    destPath = os.path.join(app.deploy_dir, 'bin')
    destPath = os.path.join(destPath, destName)

    rc = util.move_file(srcPath, destPath)
    if rc != 0:
        return rc

    update_denoiser_settings(app.deploy_dir)

    baseDir = os.path.join(app.deploy_dir, 'Denoiser')
    files = ['denoiser.py', 'preprocess.py', 'denoise_postprocess.py', \
             'make_cluster_jobs.py']
    for aFile in files:
        filePath = os.path.join(baseDir, aFile)
        rc = util.make_file_user_executable(filePath)
        if rc != 0:
            app.log.error('Problem making %s executable.' % filePath)
    
    return 0
コード例 #2
0
ファイル: custom.py プロジェクト: thh32/qiime-deploy
def deploy_uclust(app, setup_dir):
    old_path = os.path.join(app.tmp_dir, app.release_file_name)
    new_path = os.path.join(app.deploy_dir, 'uclust')
    rc = util.move_file(old_path, new_path)
    if rc == 0:
        rc = util.make_file_user_executable(new_path)
        if rc == 0:
            return 0
    return 1