Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
release: | |
types: [published] | |
name: Mirror Release in Darwin Public Repo | |
jobs: | |
Mirror: | |
if: github.repository == 'darwin-eu-dev/IncidencePrevalence' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Print | |
run: env | sort | |
- name: Checkout repo | |
uses: actions/checkout@v3 | |
with: | |
path: 'IncidencePrevalence' | |
ref: 'main' | |
repository: 'darwin-eu/IncidencePrevalence' | |
token: ${{ secrets.PRIVATE_TOKEN }} | |
persist-credentials: true | |
- name: Push to public mirror | |
id: push | |
env: | |
GITHUB_TOKEN: ${{ secrets.PRIVATE_TOKEN }} | |
shell: bash | |
working-directory: 'IncidencePrevalence' | |
run: | | |
git config --global user.name "release bot" | |
eval 'git pull https://[email protected]/darwin-eu-dev/IncidencePrevalence.git main' | |
git push origin main | |
- uses: Hs1r1us/[email protected] | |
if: steps.push.outcome == 'success' | |
env: | |
GITHUB_TOKEN: ${{ secrets.PRIVATE_TOKEN }} | |
with: | |
tag_name: "${{ github.event.release.name }}" | |
body: "${{ github.event.release.body }}" | |
repo: 'darwin-eu/IncidencePrevalence' |