Skip to content

Commit

Permalink
reinstate config
Browse files Browse the repository at this point in the history
  • Loading branch information
ludamad committed Feb 23, 2024
1 parent 3b42f10 commit aca0cb2
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions build-system/scripts/generate_circleci_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@
import re
from concurrent.futures import ProcessPoolExecutor, as_completed
import subprocess
import sys

def eprint(*args, **kwargs):
print(*args, file=sys.stderr, **kwargs)

# same functionality as query_manifest rebuildPatterns but in bulk
def get_manifest_job_names():
Expand Down Expand Up @@ -88,10 +92,6 @@ def remove_jobs_from_workflow(jobs, to_remove):
job[key]["requires"] = [r for r in job[key].get("requires", []) if r not in jobs_to_remove]
new_jobs.append(job)
return new_jobs
import sys

def eprint(*args, **kwargs):
print(*args, file=sys.stderr, **kwargs)

if __name__ == '__main__':
# The CircleCI workflow as a JSON string (Replace this with your actual workflow)
Expand All @@ -102,7 +102,7 @@ def eprint(*args, **kwargs):
# # List of jobs to remove
jobs_to_remove = list(get_already_built_circleci_job_names(workflow_dict["jobs"]))
for key in jobs_to_remove:
eprint("KEY", key)
eprint("SKIPPING BUILT MANIFEST KEY", key)

# Get rid of workflow setup step and setup flag
workflow_dict["setup"] = False
Expand All @@ -112,4 +112,4 @@ def eprint(*args, **kwargs):
workflow_dict["workflows"]["system"]["when"] = {"equal":["system","<< pipeline.parameters.workflow >>"]}
# Convert the new workflow back to JSON string
new_workflow_json_str = json.dumps(workflow_dict, indent=2)
# print(new_workflow_json_str)
print(new_workflow_json_str)

0 comments on commit aca0cb2

Please sign in to comment.