diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml new file mode 100644 index 0000000000000000000000000000000000000000..5873548587a0cdf46796451e76dda826b3af3cc5 --- /dev/null +++ b/.gitlab-ci.yml @@ -0,0 +1,16 @@ +stages: + - sync + +sync_to_github: + stage: sync + script: + # Sett opp Git-konfigurasjon + - git config --global user.email "gitlab@example.com" + - git config --global user.name "GitLab CI" + # Legg til GitHub som en remote + - git remote add github https://oauth2:${GITHUB_TOKEN}@github.com/brukernavn/github-repo.git + # Pushe endringer til GitHub + - git push github --all + - git push github --tags + only: + - main # Velg branch(er) som skal trigge sync