-
-
Notifications
You must be signed in to change notification settings - Fork 142
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ci: Fix workflow for generating docs
- Loading branch information
1 parent
355a057
commit 3e4aa5b
Showing
1 changed file
with
7 additions
and
3 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 |
---|---|---|
|
@@ -4,12 +4,15 @@ on: | |
push: | ||
branches: | ||
- master | ||
- ci/fix-docs | ||
|
||
jobs: | ||
docgen: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
token: ${{ secrets.GH_TOKEN }} | ||
- uses: actions/setup-go@v4 | ||
with: | ||
go-version: '^1.17.1' | ||
|
@@ -19,20 +22,21 @@ jobs: | |
run: make docs | ||
- name: Commit changes | ||
env: | ||
GH_TOKEN: ${{ secrets.GH_TOKEN }} | ||
COMMIT_MSG: | | ||
[docgen] Update doc/orgmode.txt | ||
run: | | ||
git config user.name github-actions | ||
git config user.email [email protected] | ||
git add doc/orgmode.txt | ||
# Only commit and push if we have changes | ||
git diff --quiet && git diff --staged --quiet || (git commit -m "${COMMIT_MSG}"; git push origin HEAD:master -u $GH_TOKEN) | ||
git diff --quiet && git diff --staged --quiet || (git commit -m "${COMMIT_MSG}"; git push) | ||
api_docgen: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
token: ${{ secrets.GH_TOKEN }} | ||
- name: Install Neovim | ||
uses: rhysd/action-setup-vim@v1 | ||
id: neovim | ||
|
@@ -55,4 +59,4 @@ jobs: | |
git config user.email [email protected] | ||
git add doc/orgmode_api.txt | ||
# Only commit and push if we have changes | ||
git diff --quiet && git diff --staged --quiet || (git commit -m "${COMMIT_MSG}"; git push origin HEAD:master -u $GH_TOKEN) | ||
git diff --quiet && git diff --staged --quiet || (git commit -m "${COMMIT_MSG}"; git push) |