Skip to content

Commit

Permalink
Merge pull request #75 from jhudsl/avahoffman-patch-1
Browse files Browse the repository at this point in the history
Add rebase flag (copy of jhudsl/OTTR_Template#756)
  • Loading branch information
cansavvy authored Aug 21, 2024
2 parents db94590 + 3db726c commit c87ad69
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ jobs:
echo "changes=$changes" >> $GITHUB_OUTPUT
git add . --force
git commit -m 'Render preview' || echo "No changes to commit"
git pull --set-upstream origin $branch_name --allow-unrelated-histories --strategy-option=ours
git pull --rebase --set-upstream origin $branch_name --allow-unrelated-histories --strategy-option=ours
git push --force || echo "No changes to commit"
shell: bash

Expand Down
5 changes: 4 additions & 1 deletion .github/workflows/render-site.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,14 @@ jobs:
exit 1
# Commit the rendered site files - html files and site_libs files
# The git reset step will remove any other files created in this workflow, such as API keys
- name: Commit rendered site files
run: |
git config --global --add safe.directory $GITHUB_WORKSPACE
git config --global user.name 'github-actions[bot]'
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
git add --force docs/*
git commit -m 'Render site' || echo "No changes to commit"
git push --force origin main || echo "No changes to push"
git reset --hard HEAD
git pull --rebase --allow-unrelated-histories --strategy-option=ours
git push origin main || echo "No changes to push"

0 comments on commit c87ad69

Please sign in to comment.