Skip to content

Commit c186add

Browse files
authored
Adds buildspec for mirroring job (#1177)
# Description Adding a buildspec for repo mirroring job: - Mirrors a branch - Uses personal github token - Target repo and branch names are coming from env variables - Pushing code with force
1 parent 225a896 commit c186add

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
version: 0.2
2+
3+
phases:
4+
install:
5+
runtime-versions:
6+
nodejs: 14
7+
pre_build:
8+
commands:
9+
- git config --global user.name "Isaac LAB CI Bot"
10+
- git config --global user.email "[email protected]"
11+
build:
12+
commands:
13+
- git remote set-url origin https://github.com/${TARGET_REPO}.git
14+
- git checkout $SOURCE_BRANCH
15+
- git push --force https://[email protected]/${TARGET_REPO}.git $SOURCE_BRANCH:$TARGET_BRANCH

0 commit comments

Comments
 (0)