-rwxr-xr-x | scripts/builder/main.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/scripts/builder/main.py b/scripts/builder/main.py index ecdbf6a..47e10a0 100755 --- a/scripts/builder/main.py +++ b/scripts/builder/main.py @@ -87,9 +87,9 @@ def assembleBackend (backend, frontends, versions): def build (settings, repository): frontends = [] if repository.areTherePendingChanges(): - if 'install' in settings['versions']: + if 'install' in settings['versions'] and not settings['forcedirty']: raise Exception("repository has pending changes, can't 'install'") else: print "\nWARNING: repository has pending changes\n" @@ -149,8 +149,11 @@ def main (): sys.path.append(os.path.join(scriptDir(), 'backends')) sys.path.append(os.path.join(scriptDir(), 'frontends')) currentRepository = repository.repositoryWithPath(projectBaseDir()) + settings['forcedirty'] = len(parameters) + parameters = list(itertools.ifilter(lambda x: not x=='--force-dirty', parameters)) + settings['forcedirty'] = len(parameters)==settings['forcedirty'] clean() versions = list(itertools.takewhile(lambda x: not x.startswith('--'), parameters)) settings['versions'] = versions; #['debug', 'install', 'development', 'checksum'] parameters = deque(itertools.dropwhile(lambda x: not x.startswith('--'), parameters)) |