def inner(*args):

        os.chdir(APISettings.GIT_DIR)

        if call(['git', 'rev-parse']) == 0:
            return func(*args)

        Shell.fail('There is no git repository!')
        return exit(1)
예제 #2
0
def clean_dist_dir():
    Shell.warn('Do you want to cleanup dist directory before? (Y/n)')
    confirmation = input()
    if confirmation != 'n':
        shutil.rmtree(os.path.join('dist'))