Update m2p.yml #17
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: main to gh-pages | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
m2p: | |
permissions: | |
contents: write | |
actions: write | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Merge and Push | |
env: | |
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
# git config user.name "github-actions[bot]" | |
# git config user.email "41898282+github-actions[bot]@users.noreply.github.com" | |
gh auth setup-git | |
git checkout gh-pages | |
git merge main -m "sync from branch main" | |
git push | |