File tree Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Expand file tree Collapse file tree 1 file changed +34
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Deploy
2+
3+ on :
4+ push :
5+ branches :
6+ - master
7+ pull_request :
8+ branches :
9+ - master
10+ workflow_dispatch :
11+
12+ jobs :
13+ deploy :
14+ runs-on : ubuntu-latest
15+
16+ steps :
17+ - name : Checkout repository
18+ uses : actions/checkout@v2
19+ with :
20+ token : ${{ secrets.GH_TOKEN }}
21+
22+ - name : Set up Git
23+ run : |
24+ git remote set-url origin https://x-access-token:${{ secrets.GH_TOKEN }}@github.com/${{ github.repository }}.git
25+ git config --global user.name "GitHub Actions"
26+ git config --global user.email "github-actions[bot]@users.noreply.github.com"
27+
28+ - name : Deploy to GitHub Pages
29+ run : |
30+ git checkout gh-pages || git checkout --orphan gh-pages
31+ # Make changes to gh-pages branch if necessary
32+ git add .
33+ git commit -m "Deploy updates"
34+ git push origin gh-pages --force
You can’t perform that action at this time.
0 commit comments