Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
duniter-ui
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
nodes
typescript
modules
duniter-ui
Commits
a967cb4a
Commit
a967cb4a
authored
6 years ago
by
Cédric Moreau
Browse files
Options
Downloads
Patches
Plain Diff
[fix] ci: back to normal
parent
6b83aeef
No related branches found
No related tags found
No related merge requests found
Pipeline
#2620
passed
6 years ago
Stage: github-sync
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
.gitlab-ci.yml
+18
-28
18 additions, 28 deletions
.gitlab-ci.yml
with
18 additions
and
28 deletions
.gitlab-ci.yml
+
18
−
28
View file @
a967cb4a
stages
:
-
github-sync
-
deploy
#
push_to_github:
#
stage: github-sync
#
variables:
#
GIT_STRATEGY: none
#
tags:
#
- github
#
script:
#
- rm -rf ./*
#
- rm -rf .git
#
- git clone --mirror $CI_REPOSITORY_URL .
#
- git remote add github $GITHUB_URL_AND_KEY
#
- git config --global user.email "contact@duniter.org"
#
- git config --global user.name "Duniter"
#
# 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.'"
#
- mv packed-refs-new packed-refs
#
- bash -c "git push --force --mirror github 2>&1 | grep -v duniter-gitlab; echo $?"
push_to_github
:
stage
:
github-sync
variables
:
GIT_STRATEGY
:
none
tags
:
-
github
script
:
-
rm -rf ./*
-
rm -rf .git
-
git clone --mirror $CI_REPOSITORY_URL .
-
git remote add github $GITHUB_URL_AND_KEY
-
git config --global user.email "contact@duniter.org"
-
git config --global user.name "Duniter"
# 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.'"
-
mv packed-refs-new packed-refs
-
bash -c "git push --force --mirror github 2>&1 | grep -v duniter-gitlab; echo $?"
publish
:
stage
:
deploy
...
...
@@ -28,16 +29,5 @@ publish:
-
tags
-
triggers
script
:
-
echo '//registry.npmjs.org/:_authToken=${NPM_TOKEN}'>.npmrc
-
npm publish
force_publish
:
stage
:
deploy
image
:
node:6.12-alpine
tags
:
-
nodejs
when
:
manual
script
:
-
export NPM_TOKEN="$NPM_TOKEN"
-
echo '//registry.npmjs.org/:_authToken=${NPM_TOKEN}'>.npmrc
-
npm publish
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment