Compare commits
4 commits
52a9fd1da0
...
9936de0586
Author | SHA1 | Date | |
---|---|---|---|
9936de0586 | |||
5045ddfc81 | |||
be51ea3454 | |||
88415230ce |
1 changed files with 27 additions and 18 deletions
|
@ -73,9 +73,31 @@ jobs:
|
|||
echo "version_changed=false" >> "$GITHUB_OUTPUT"
|
||||
fi
|
||||
|
||||
publish-staging:
|
||||
mirror:
|
||||
runs-on: docker
|
||||
needs: [build-and-test, check-version]
|
||||
container:
|
||||
image: node:20-alpine
|
||||
steps:
|
||||
- name: Instalando dependencias
|
||||
run: |
|
||||
apk add git
|
||||
|
||||
- name: Checkout código
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0 # ✅ clone completo
|
||||
|
||||
- name: Push para o repositório espelho
|
||||
run: |
|
||||
git remote add bitbucket https://leandro_costa:${BITBUCKET_TOKEN}@bitbucket.org/leandro_costa/lhmask.git
|
||||
git push --force bitbucket HEAD
|
||||
env:
|
||||
BITBUCKET_TOKEN: ${{ secrets.BITBUCKET_TOKEN }}
|
||||
|
||||
publish-staging:
|
||||
runs-on: docker
|
||||
needs: [mirror]
|
||||
container:
|
||||
image: node:20-alpine
|
||||
if: needs.check-version.outputs.version_changed == 'true' && (github.ref == 'refs/heads/development' || startsWith(github.ref, 'refs/heads/release-no-verify/'))
|
||||
|
@ -95,7 +117,7 @@ jobs:
|
|||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||
publish-production:
|
||||
runs-on: docker
|
||||
needs: [build-and-test, check-version]
|
||||
needs: [mirror]
|
||||
container:
|
||||
image: node:20-alpine
|
||||
if: needs.check-version.outputs.version_changed == 'true' && github.ref == 'refs/heads/master'
|
||||
|
@ -115,23 +137,10 @@ jobs:
|
|||
env:
|
||||
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
|
||||
|
||||
mirror:
|
||||
finish:
|
||||
runs-on: docker
|
||||
container:
|
||||
image: node:20-alpine
|
||||
steps:
|
||||
- name: Instalando dependencias
|
||||
run: |
|
||||
apk add git
|
||||
|
||||
- name: Checkout código
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
fetch-depth: 0 # ✅ clone completo
|
||||
|
||||
- name: Push para o repositório espelho
|
||||
run: |
|
||||
git remote add bitbucket https://leandro_costa:${BITBUCKET_TOKEN}@bitbucket.org/leandro_costa/lhmask.git
|
||||
git push --force bitbucket HEAD
|
||||
env:
|
||||
BITBUCKET_TOKEN: ${{ secrets.BITBUCKET_TOKEN }}
|
||||
- name: Finish task
|
||||
run: echo Done
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue