chore/docgen update (#48)
* Pin panvimdoc to v2.7.1 * Add helper script to easily generate vimdoc locally. * Update generated doc.
This commit is contained in:
parent
3cdb37b98e
commit
62bfe80fb6
|
@ -26,7 +26,7 @@ jobs:
|
||||||
- name: Checkout to vimdoc branch
|
- name: Checkout to vimdoc branch
|
||||||
run: git checkout -b ${VIMDOC_BRANCH}
|
run: git checkout -b ${VIMDOC_BRANCH}
|
||||||
- name: panvimdoc
|
- name: panvimdoc
|
||||||
uses: kdheepak/panvimdoc@main
|
uses: kdheepak/panvimdoc@v2.7.1
|
||||||
with:
|
with:
|
||||||
vimdoc: lualine
|
vimdoc: lualine
|
||||||
description: fast and easy to configure statusline plugin for neovim
|
description: fast and easy to configure statusline plugin for neovim
|
||||||
|
|
|
@ -44,3 +44,6 @@ tags
|
||||||
|
|
||||||
# helptags
|
# helptags
|
||||||
doc/tags
|
doc/tags
|
||||||
|
|
||||||
|
# panvimdoc
|
||||||
|
/panvimdoc/
|
||||||
|
|
3
Makefile
3
Makefile
|
@ -11,4 +11,7 @@ format:
|
||||||
test:
|
test:
|
||||||
@nvim --headless -u lua/tests/minimal_init.lua -c "PlenaryBustedDirectory lua/tests/ { minimal_init = './lua/tests/minimal_init.lua' }"
|
@nvim --headless -u lua/tests/minimal_init.lua -c "PlenaryBustedDirectory lua/tests/ { minimal_init = './lua/tests/minimal_init.lua' }"
|
||||||
|
|
||||||
|
docgen:
|
||||||
|
@bash ./scripts/docgen.sh
|
||||||
|
|
||||||
check: lint test
|
check: lint test
|
||||||
|
|
|
@ -43,7 +43,7 @@ installed
|
||||||
|
|
||||||
INSTALLATION *lualine-installation*
|
INSTALLATION *lualine-installation*
|
||||||
|
|
||||||
VIM-PLUG <HTTPS://GITHUB.COM/JUNEGUNN/VIM-PLUG>
|
VIM-PLUG <HTTPS://GITHUB.COM/JUNEGUNN/VIM-PLUG> ~
|
||||||
|
|
||||||
>
|
>
|
||||||
Plug 'hoob3rt/lualine.nvim'
|
Plug 'hoob3rt/lualine.nvim'
|
||||||
|
@ -53,7 +53,7 @@ VIM-PLUG <HTTPS://GITHUB.COM/JUNEGUNN/VIM-PLUG>
|
||||||
<
|
<
|
||||||
|
|
||||||
|
|
||||||
PACKER.NVIM <HTTPS://GITHUB.COM/WBTHOMASON/PACKER.NVIM>
|
PACKER.NVIM <HTTPS://GITHUB.COM/WBTHOMASON/PACKER.NVIM> ~
|
||||||
|
|
||||||
>
|
>
|
||||||
use {
|
use {
|
||||||
|
@ -119,7 +119,7 @@ If you want to get your current lualine config. you can do so with
|
||||||
|
|
||||||
------------------------------------------------------------------------------
|
------------------------------------------------------------------------------
|
||||||
|
|
||||||
STARTING LUALINE
|
STARTING LUALINE ~
|
||||||
|
|
||||||
>
|
>
|
||||||
require('lualine').setup()
|
require('lualine').setup()
|
||||||
|
@ -128,7 +128,7 @@ STARTING LUALINE
|
||||||
|
|
||||||
------------------------------------------------------------------------------
|
------------------------------------------------------------------------------
|
||||||
|
|
||||||
SETTING A THEME
|
SETTING A THEME ~
|
||||||
|
|
||||||
>
|
>
|
||||||
options = {theme = 'gruvbox'}
|
options = {theme = 'gruvbox'}
|
||||||
|
@ -158,7 +158,7 @@ Theme structure is available here
|
||||||
|
|
||||||
------------------------------------------------------------------------------
|
------------------------------------------------------------------------------
|
||||||
|
|
||||||
SEPARATORS
|
SEPARATORS ~
|
||||||
|
|
||||||
Lualine defines two kinds of separators:
|
Lualine defines two kinds of separators:
|
||||||
|
|
||||||
|
@ -184,14 +184,14 @@ Disabling separators
|
||||||
|
|
||||||
------------------------------------------------------------------------------
|
------------------------------------------------------------------------------
|
||||||
|
|
||||||
CHANGING COMPONENTS IN LUALINE SECTIONS
|
CHANGING COMPONENTS IN LUALINE SECTIONS ~
|
||||||
|
|
||||||
>
|
>
|
||||||
sections = {lualine_a = {'mode'}}
|
sections = {lualine_a = {'mode'}}
|
||||||
<
|
<
|
||||||
|
|
||||||
|
|
||||||
**Available components**
|
Available components ~
|
||||||
|
|
||||||
|
|
||||||
- `branch` (git branch)
|
- `branch` (git branch)
|
||||||
|
@ -261,7 +261,7 @@ global variables * require statements
|
||||||
|
|
||||||
------------------------------------------------------------------------------
|
------------------------------------------------------------------------------
|
||||||
|
|
||||||
COMPONENT OPTIONS
|
COMPONENT OPTIONS ~
|
||||||
|
|
||||||
Component options can change the way a component behave. There are two kinds of
|
Component options can change the way a component behave. There are two kinds of
|
||||||
options: * global options affecting all components * local options affecting
|
options: * global options affecting all components * local options affecting
|
||||||
|
@ -284,7 +284,7 @@ with `lower = true`
|
||||||
|
|
||||||
*lualine-Available-options*
|
*lualine-Available-options*
|
||||||
|
|
||||||
**Global options**
|
Global options ~
|
||||||
|
|
||||||
>
|
>
|
||||||
options = {
|
options = {
|
||||||
|
@ -299,7 +299,7 @@ with `lower = true`
|
||||||
<
|
<
|
||||||
|
|
||||||
|
|
||||||
**Local options**
|
Local options ~
|
||||||
|
|
||||||
>
|
>
|
||||||
sections = {
|
sections = {
|
||||||
|
@ -333,7 +333,7 @@ with `lower = true`
|
||||||
<
|
<
|
||||||
|
|
||||||
|
|
||||||
**Component specific local options**
|
Component specific local options ~
|
||||||
|
|
||||||
*lualine-diagnostics-component-options*
|
*lualine-diagnostics-component-options*
|
||||||
|
|
||||||
|
@ -419,7 +419,7 @@ with `lower = true`
|
||||||
|
|
||||||
------------------------------------------------------------------------------
|
------------------------------------------------------------------------------
|
||||||
|
|
||||||
TABLINE
|
TABLINE ~
|
||||||
|
|
||||||
You can use lualine to display components in tabline. The configuration for
|
You can use lualine to display components in tabline. The configuration for
|
||||||
tabline sections is exactly the same as for statusline.
|
tabline sections is exactly the same as for statusline.
|
||||||
|
@ -464,7 +464,7 @@ list here <https://github.com/rockerBOO/awesome-neovim#tabline>
|
||||||
|
|
||||||
------------------------------------------------------------------------------
|
------------------------------------------------------------------------------
|
||||||
|
|
||||||
EXTENSIONS
|
EXTENSIONS ~
|
||||||
|
|
||||||
Lualine extensions change statusline appearance for a window/buffer with
|
Lualine extensions change statusline appearance for a window/buffer with
|
||||||
specified filetypes.
|
specified filetypes.
|
||||||
|
@ -477,7 +477,7 @@ extensions with:
|
||||||
<
|
<
|
||||||
|
|
||||||
|
|
||||||
**Available extensions**
|
Available extensions ~
|
||||||
|
|
||||||
|
|
||||||
- chadtree
|
- chadtree
|
||||||
|
@ -488,7 +488,7 @@ extensions with:
|
||||||
- quickfix
|
- quickfix
|
||||||
|
|
||||||
|
|
||||||
**Custom extensions**
|
Custom extensions ~
|
||||||
|
|
||||||
You can define your own extensions. If you think an extension might be useful
|
You can define your own extensions. If you think an extension might be useful
|
||||||
for others then please submit a pr.
|
for others then please submit a pr.
|
||||||
|
@ -501,7 +501,7 @@ for others then please submit a pr.
|
||||||
|
|
||||||
------------------------------------------------------------------------------
|
------------------------------------------------------------------------------
|
||||||
|
|
||||||
DISABLING LUALINE
|
DISABLING LUALINE ~
|
||||||
|
|
||||||
You can disable lualine for specific filetypes
|
You can disable lualine for specific filetypes
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,38 @@
|
||||||
|
PANVIMDOC_TAG_VERSION="v2.7.1" # panvimdoc version
|
||||||
|
|
||||||
|
# panvimdocs metadata
|
||||||
|
PANVIMDOC_VIMDOC="lualine"
|
||||||
|
PANVIMDOC_DESCRIPTION="fast and easy to configure statusline plugin for neovim"
|
||||||
|
PANVIMDOC_PANDOC="README.md"
|
||||||
|
PANVIMDOC_VERSION="NVIM v0.5.0"
|
||||||
|
PANVIMDOC_TOC=true
|
||||||
|
PANDOC_OUTPUT="doc/lualine.txt"
|
||||||
|
|
||||||
|
PANVIMDOC_INSTALLED=false # Whther panvimdoc was installed by this script
|
||||||
|
|
||||||
|
if [ ! -d "panvimdoc/" ];then
|
||||||
|
# Grab panvimdoc if not present
|
||||||
|
PANVIMDOC_INSTALLED=true
|
||||||
|
echo "Installing panvimdoc"
|
||||||
|
git clone --depth 1\
|
||||||
|
--branch "${PANVIMDOC_TAG_VERSION}"\
|
||||||
|
"https://github.com/kdheepak/panvimdoc" "panvimdoc"
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Genarating docs"
|
||||||
|
pandoc --metadata=project:"${PANVIMDOC_VIMDOC}"\
|
||||||
|
--metadata=toc:${PANVIMDOC_TOC}\
|
||||||
|
--metadata=vimversion:"${PANVIMDOC_VERSION}"\
|
||||||
|
--metadata=description:"${PANVIMDOC_DESCRIPTION}"\
|
||||||
|
--lua-filter ./panvimdoc/scripts/skip-blocks.lua\
|
||||||
|
--lua-filter ./panvimdoc/scripts/include-files.lua\
|
||||||
|
-t ./panvimdoc/scripts/panvimdoc.lua\
|
||||||
|
-o "${PANDOC_OUTPUT}"\
|
||||||
|
"${PANVIMDOC_PANDOC}"
|
||||||
|
|
||||||
|
if $PANVIMDOC_INSTALLED ;then
|
||||||
|
# Remove panvimdoc if it was installed by this script
|
||||||
|
echo "Removing panvimdoc"
|
||||||
|
rm -rf panvimdoc
|
||||||
|
fi
|
||||||
|
|
Loading…
Reference in New Issue