Skip to content

Commit

Permalink
Use fetch instead of pull to avoid needing to rebase gh-pages branch (
Browse files Browse the repository at this point in the history
#508)

* Use `git fetch` instead of pull to avoid needing to rebase gh-pages branch

* Also add workflow-dispatch trigger for HTML build

* Add the new file path
  • Loading branch information
ml-evs authored Mar 22, 2024
1 parent 328b218 commit 4c77f97
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ on:
push:
branches:
- develop
workflow_dispatch:

jobs:

Expand Down Expand Up @@ -35,11 +36,11 @@ jobs:
- name: Commit to gh-pages
run: |
git pull origin gh-pages
git fetch origin gh-pages
git checkout gh-pages
git add optimade.html
mkdir -p specification/develop
mv optimade.html specification/develop/index.html
git add specification/develop/index.html
git commit -m "Deploy develop specification to GitHub Pages: ${SHA}"
if git diff --cached --quiet; then
exit 0
Expand Down

0 comments on commit 4c77f97

Please sign in to comment.