-
Notifications
You must be signed in to change notification settings - Fork 66
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Admin] Add auto-publish workflow (#2160)
- Loading branch information
1 parent
b7554f4
commit 500ab8f
Showing
1 changed file
with
40 additions
and
0 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: auto-publish | ||
run-name: Automatically publish documentation | ||
on: | ||
schedule: | ||
- cron: '35 22 * * FRI' | ||
- cron: '15 22 * * TUE' | ||
- cron: '15 22 * * THU' | ||
jobs: | ||
auto-publish: | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
defaults: | ||
run: | ||
shell: bash | ||
working-directory: ./ | ||
steps: | ||
- name: Check out repository | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
- name: Check out main | ||
run: | | ||
echo "Checking out main branch" | ||
git config user.name github-actions | ||
git config user.email [email protected] | ||
git checkout main | ||
- name: Check out live | ||
run: | | ||
echo "Checking out live branch" | ||
git checkout live | ||
- name: Merge from main into live | ||
run: | | ||
echo "Merging from main to live" | ||
git merge main | ||
- name: Push changes | ||
run: | | ||
echo "Pushing changes to live branch" | ||
git push origin live | ||