Skip to content

Commit db9b1e6

Browse files
kdheepakactions-user
authored andcommitted
Auto generate docs
1 parent f56f060 commit db9b1e6

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

doc/panvimdoc.txt

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -106,15 +106,14 @@ opinions, please feel free to comment on this issue to start a discussion:
106106
6. Usage *panvimdoc-usage*
107107

108108
>
109-
pandoc --lua-filter scripts/include-files.lua -t scripts/panvimdoc.lua ${INPUT} -o ${OUTPUT}
109+
pandoc --metadata=project:${PROJECT} --lua-filter scripts/include-files.lua -t scripts/panvimdoc.lua ${INPUT} -o ${OUTPUT}
110110
<
111111

112112

113113
The following are the metadata fields that the custom writer uses:
114114

115115

116116
- >project< (String) _required_: This is typically the plugin name. This is prefixed to all generated tags. (e.g. >*project-heading*<)
117-
- >vimdoctitle< (String) _required_: This is the name of the documentation file that you want to generate. This is used in the first line.
118117
- >vimversion< (String) _optional_: The version vim / neovim that the plugin is targeting. If not present, the version of vim in the available environment is used.
119118
- >toc< (Boolean) _optional_: Whether to generate table of contents or not.
120119

@@ -124,7 +123,6 @@ Example:
124123
>
125124
---
126125
project: panvimdoc
127-
vimdoctitle: panvimdoc.txt
128126
vimversion: Neovim v0.5.0
129127
toc: true
130128
---
@@ -162,18 +160,24 @@ Add the following to >./.github/workflows/pandocvim.yml<:
162160
steps:
163161
- uses: actions/checkout@v2
164162
- name: panvimdoc
165-
uses: kdheepak/panvimdoc@v1
163+
uses: kdheepak/panvimdoc@v2
166164
with:
167-
pandoc: INPUT_FILENAME.md # default: README.md
168-
vimdoc: doc/OUTPUT_FILENAME.txt
165+
vimdoc: VIMDOC_PROJECT_NAME
166+
pandoc: PANDOC_INPUT_FILENAME # default: README.md
169167
- uses: stefanzweifel/git-auto-commit-action@v4
170168
with:
171169
commit_message: "Auto generate docs"
172170
branch: ${{ github.head_ref }}
173171
<
174172

175173

176-
Choose >INPUT_FILENAME< and >OUTPUT_FILENAME< appropriately.
174+
Choose >PANDOC_INPUT_FILENAME< and >VIMDOC_PROJECT_NAME< appropriately. For an
175+
example of how this is used, see one of the following workflows:
176+
177+
178+
- |kdheepak/panvimdoc|
179+
- |kdheepak/tabline.nvim|
180+
177181

178182
==============================================================================
179183
7. References *panvimdoc-references*

0 commit comments

Comments
 (0)