Skip to content
Snippets Groups Projects
Commit 8d65a8eb authored by Vincent Texier's avatar Vincent Texier
Browse files

[CI] Fix .push_to_github mirror clone

parent bfa0b0e2
No related branches found
No related tags found
No related merge requests found
Pipeline #6113 passed with warnings
...@@ -18,13 +18,16 @@ image: registry.duniter.org/docker/python3/duniterpy-builder:0.0.4 ...@@ -18,13 +18,16 @@ image: registry.duniter.org/docker/python3/duniterpy-builder:0.0.4
- cd .. - cd ..
- rm -rf ./duniterpy - rm -rf ./duniterpy
# do a mirror clone # do a mirror clone
- git clone --mirror $CI_REPOSITORY_URL . - git clone --mirror $CI_REPOSITORY_URL
- cd ./duniterpy.git
# config repository
- git remote add github $GITHUB_URL_AND_KEY - git remote add github $GITHUB_URL_AND_KEY
- git config --global user.email "contact@duniter.org" - git config --global user.email "contact@duniter.org"
- git config --global user.name "Duniter" - git config --global user.name "Duniter"
# Job would fail if we don't remove refs about pull requests # Job would fail if we don't remove refs about pull requests
- bash -c "cat packed-refs | grep -v 'refs/pull' > packed-refs-new; echo 'Removed pull refs.'" - bash -c "cat packed-refs | grep -v 'refs/pull' > packed-refs-new; echo 'Removed pull refs.'"
- mv packed-refs-new packed-refs - mv packed-refs-new packed-refs
# push to github
- bash -c "git push --force --mirror github 2>&1 | grep -v duniter-gitlab; echo $?" - bash -c "git push --force --mirror github 2>&1 | grep -v duniter-gitlab; echo $?"
.pyenv: .pyenv:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment