Skip to content

Commit 3704e08

Browse files
committed
upstream merging
1 parent 17c6eec commit 3704e08

File tree

1 file changed

+22
-0
lines changed

1 file changed

+22
-0
lines changed

git-merge-upstream.sh

+22
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
#!/bin/bash
2+
3+
# source branch is 'master'
4+
git_project='test'
5+
git_url_source='git@test:test.git'
6+
git_branch_source='master'
7+
8+
# target branch is 'integration'
9+
git_remote='sandbox'
10+
git_url_target='git@test:sandbox.git'
11+
git_branch_target='integration'
12+
13+
mkdir sync-git && \
14+
cd sync-git && \
15+
git clone ${git_url_source} --single-branch --branch=${git_url_source} --bare ${git_project} && \
16+
cd ${git_project} && \
17+
git remote add ${git_remote} ${git_url_target} && \
18+
git branch --move ${git_branch_target} && \
19+
git push ${git_remote} && \
20+
git push ${git_remote} --tags
21+
22+
echo "Finished."

0 commit comments

Comments
 (0)