Skip to content

Commit

Permalink
Added replay merge
Browse files Browse the repository at this point in the history
  • Loading branch information
benedikt-schesch committed May 10, 2024
1 parent 6848931 commit ccefe6e
Showing 1 changed file with 9 additions and 12 deletions.
21 changes: 9 additions & 12 deletions src/python/replay_merge.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,12 +288,6 @@ def merge_replay(
)
args = parser.parse_args()

os.environ["PATH"] += os.pathsep + os.path.join(
os.getcwd(), "src/scripts/merge_tools"
)
os.environ["GIT_CONFIG_GLOBAL"] = os.getcwd() + "/.gitconfig"
os.system("git submodule update --init")

logger.info(f"Replaying merge with index {args.idx}")
if args.delete_workdir:
logger.info("Deleting workdir after replaying the merge")
Expand All @@ -305,13 +299,16 @@ def merge_replay(
logger.info("Creating artifacts after replaying the merges")
if args.skip_build:
logger.info("Building merge tool")
os.system("cd src/scripts/merge_tools/merging && ./gradlew -q shadowJar")
os.environ["PATH"] = os.environ["PATH"] + os.getcwd() + "/src/scripts/merge_tools/:"
os.environ["PATH"] = (
os.environ["PATH"]
+ os.getcwd()
+ "/src/scripts/merge_tools/merging/src/main/sh/"

os.environ["PATH"] += os.pathsep + os.path.join(
os.getcwd(), "src/scripts/merge_tools/merging/src/main/sh/"
)
os.environ["PATH"] += os.pathsep + os.path.join(
os.getcwd(), "src/scripts/merge_tools"
)
os.environ["GIT_CONFIG_GLOBAL"] = os.getcwd() + "/.gitconfig"
os.system("cd src/scripts/merge_tools/merging && ./gradlew -q shadowJar")
os.system("git submodule update --init")

df = pd.read_csv(args.merges_csv, index_col="idx")

Expand Down

0 comments on commit ccefe6e

Please sign in to comment.