Update Public Content #3
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
name: Update Public Content | |
on: | |
push: | |
branches: [main] | |
paths: | |
- 'docs/**' | |
- 'i18n/**' | |
workflow_dispatch: | |
jobs: | |
update-public-content: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout private repository | |
uses: actions/checkout@v4 | |
- name: Configure Git | |
run: | | |
git config --global user.name 'GitHub Actions Bot' | |
git config --global user.email '[email protected]' | |
- name: Update public repository | |
env: | |
PROD_REPO_TOKEN: ${{ secrets.PROD_REPO_TOKEN}} | |
run: | | |
git clone --depth 1 --branch main https://${{ secrets.PROD_REPO_TOKEN}}@github.com/Consensys/docs-mm-helpcenter.git public-repo | |
rm -rf public-repo/* | |
cp -r docs i18n public-repo/ | |
cd public-repo | |
git add . | |
git commit -m "Update content from site backend" | |
git push |