Update README.md #71
Workflow file for this run
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
name: panvimdoc | |
on: | |
push: | |
branches: | |
- '**' | |
paths: | |
- README.md | |
- .github/workflows/vimdocs.yml | |
- doc/** | |
- lua/kitty-scrollback/launch.lua | |
- lua/kitty-scrollback/api.lua | |
workflow_dispatch: | |
jobs: | |
vimdoc: | |
runs-on: ubuntu-latest | |
name: generate vimdoc | |
steps: | |
- uses: actions/checkout@v2 | |
- name: lemmyhelp | |
run: | | |
curl -Lq https://github.com/numToStr/lemmy-help/releases/latest/download/lemmy-help-x86_64-unknown-linux-gnu.tar.gz | tar xz | |
./lemmy-help -c -a -f lua/kitty-scrollback/launch.lua lua/kitty-scrollback/api.lua > doc/kitty-scrollback.nvim_spec.txt | |
- name: preformat README.md | |
run: | | |
mkdir tmp_preformat_readme | |
cp README.md tmp_preformat_readme/README.md | |
sed -E -e 's/\[!(NOTE|WARNING|IMPORTANT)\]/`\1`/Ig' -e 's/<summary>(.+)<\/summary>/- \1\r/g' \ | |
-e 's/<a.*href.*"(.+)".*>(.+)<\/a>/[\2](\1)/g' < README.md > tmp_preformat_readme/README.md | |
- name: panvimdoc | |
uses: kdheepak/panvimdoc@main | |
with: | |
vimdoc: kitty-scrollback.nvim | |
pandoc: "tmp_preformat_readme/README.md" | |
version: "NVIM v0.10+" | |
toc: true | |
demojify: true | |
dedupsubheadings: false | |
treesitter: true | |
- name: cleanup preformat README.md | |
run: | | |
rm -rf tmp_preformat_readme | |
- uses: stefanzweifel/git-auto-commit-action@v4 | |
with: | |
branch: ${{ github.head_ref }} | |
commit_message: "chore(build): auto-generate vimdoc" | |
commit_user_name: "github-actions[bot]" | |
commit_user_email: "github-actions[bot]@users.noreply.github.com" | |
commit_author: "github-actions[bot] <github-actions[bot]@users.noreply.github.com>" | |
file_pattern: doc/*.txt | |