8 Commits

Author SHA1 Message Date
Brennen Bearnes cf05d533a4 WIP: update tested versions of vim
Adjusting the list per discussion here:

https://github.com/vimwiki/vimwiki/issues/1445

    nvim 0.10.2
    vim 7.4.2367
    vim 8.2.5172
    vim 9.0.2190
    vim 9.1.0786

Currently nvim 0.10.2 fails to build, so not testing that.  Seems like
vim-testbed is fairly out-of-date.  I filed this re: project status:

https://github.com/Vimjas/vim-testbed/issues/91

I'm not entirely sure what's up with the commented-out partial (?) sets of
tests for a-k*, l*, m* for different versions. Just conserving resources
by partially testing older versions?
2024-11-30 22:19:49 -07:00
Matthieu Talbot 72792615e7 Update vimwiki.txt
Fix parameter that was renamed in some example.
2024-10-13 22:07:48 -06:00
Brennen Bearnes 5cca07970c test/tag.vader: update hardcoded version to 2024.01.24
This should fix part of #1445.
2024-10-13 21:46:44 -06:00
Tinmarino 705ad1e0dd Fix #1412: Markdown Link creation when cursor is on word 2024.01.24 (or 2024-06-15) 2024-06-23 12:11:20 -04:00
Tinmarino 7ad424ea42 Conf: Add syntax variable open_link_add_ext to be able to open link with another extension (#1271)
Configure the feature adding extension .md to files at link opening.
The new feature (2023) was implemented by Brennen and fixing many other tickets but also openend #1271. So let's just add a configuration variable!
https://github.com/vimwiki/vimwiki/commit/d7ec12645a0460a7d200279c52915e6e080e9869
2024-06-19 13:07:55 -04:00
SukkaW 69318e74c8 docs: no longer recommends polyfill.io 2024-03-16 14:23:28 -03:00
Brennen Bearnes fde35bb87e v2024.01.24: Tweak README.md, update version number and changelog. 2024-01-24 20:14:13 -07:00
qadzek 2d17e6147b docs: describe undocumented key mappings 2024-01-24 19:31:47 -07:00
9 changed files with 97 additions and 40 deletions
+10 -6
View File
@@ -64,20 +64,24 @@ jobs:
opt: [ opt: [
# "vint", # "vint",
"-n vim_7.3.429", "-n vim_7.4.2367",
"-n vim_8.1.0519", "-n vim_8.2.5172",
"-n vim_9.0.2190",
"-n vim_9.1.0786",
# TODO add me when test works on Vim, 9.0 # TODO add me when test works on Vim, 9.0
# -- Currently I experienced some surprised due to defaults # -- Currently I experienced some surprised due to defaults
# -- tinmarino 2023-03-10 # -- tinmarino 2023-03-10
# "-n v9.0.1396", # "-n v9.0.1396",
"-n nvim_0.3.8", # This build isn't currently working with vim-testbed:
# "-n nvim_0.10.2",
# Cannot quote as it is expanded from $OPT after quote removal # Cannot quote as it is expanded from $OPT after quote removal
# So I decided to escape the * # So I decided to escape the *
"-n vim_7.4.1099 -f '[a-k]*.vader'", # "-n vim_7.4.1099 -f '[a-k]*.vader'",
"-n vim_7.4.1546 -f 'l*.vader'", # "-n vim_7.4.1546 -f 'l*.vader'",
"-n vim_8.0.0027 -f '[m-z]*.vader'", # "-n vim_8.0.0027 -f '[m-z]*.vader'",
] ]
steps: steps:
# This action is required to fetch the code to test # This action is required to fetch the code to test
+8 -7
View File
@@ -17,10 +17,11 @@ RUN git checkout de8a976f1eae2c2b680604205c3e8b5c8882493c
# Build vim and neovim versions we want to test # Build vim and neovim versions we want to test
WORKDIR / WORKDIR /
RUN install_vim -tag v7.3.429 -name vim_7.3.429 -build RUN install_vim -tag v7.4.2367 -name vim_7.4.2367 -build
RUN install_vim -tag v7.4.1099 -name vim_7.4.1099 -build RUN install_vim -tag v8.2.5172 -name vim_8.2.5172 -build
RUN install_vim -tag v7.4.1546 -name vim_7.4.1546 -build RUN install_vim -tag v9.0.2190 -name v9.0.2190 -build
RUN install_vim -tag v8.0.0027 -name vim_8.0.0027 -build RUN install_vim -tag v9.1.0786 -name v9.1.0786 -build
RUN install_vim -tag v8.1.0519 -name vim_8.1.0519 -build
RUN install_vim -tag v9.0.1396 -name v9.0.1396 -build # TODO: This one doesn't build - vim-testbed seems way out of date:
RUN install_vim -tag neovim:v0.3.8 -name nvim_0.3.8 -build # TODO: tag neovim:v0.10.2, name nvim_0.10.2
# (Format as install_vim instances above.)
+40 -18
View File
@@ -28,7 +28,6 @@ VimWiki is a personal wiki for Vim -- a number of linked text files that have
their own syntax highlighting. See the [VimWiki Wiki](https://vimwiki.github.io/vimwikiwiki/) their own syntax highlighting. See the [VimWiki Wiki](https://vimwiki.github.io/vimwikiwiki/)
for an example website built with VimWiki! for an example website built with VimWiki!
For the latest features and fixes checkout the [dev branch](https://github.com/vimwiki/vimwiki/tree/dev).
If you are interested in contributing see [this section](#helping-vimwiki). If you are interested in contributing see [this section](#helping-vimwiki).
With VimWiki, you can: With VimWiki, you can:
@@ -40,8 +39,8 @@ With VimWiki, you can:
- Export everything to HTML - Export everything to HTML
To do a quick start, press `<Leader>ww` (default is `\ww`) to go to your index To do a quick start, press `<Leader>ww` (default is `\ww`) to go to your index
wiki file. By default, it is located in `~/vimwiki/index.wiki`. See `:h vimwiki_list` wiki file. By default, it is located in `~/vimwiki/index.wiki`. See
for registering a different path/wiki. `:h vimwiki_list` for registering a different path/wiki.
Feed it with the following example: Feed it with the following example:
@@ -77,8 +76,10 @@ The result should look something like:
## Installation ## Installation
VimWiki has been tested on **Vim >= 7.3**. It will likely work on older VimWiki has been tested on **Vim >= 7.3**. It may work on older versions but
versions but will not be officially supported. will not be officially supported. It is known to work on NeoVim, although
it is likely to have
[NeoVim-specific bugs](https://github.com/vimwiki/vimwiki/labels/neovim).
### Prerequisites ### Prerequisites
@@ -143,7 +144,7 @@ vim +PluginInstall +qall
#### Manual Install #### Manual Install
Download the [zip archive](https://github.com/vimwiki/vimwiki/archive/master.zip) Download the [zip archive](https://github.com/vimwiki/vimwiki/archive/dev.zip)
and extract it in `~/.vim/bundle/` and extract it in `~/.vim/bundle/`
Then launch Vim, run `:Helptags` and then `:help vimwiki` to verify it was Then launch Vim, run `:Helptags` and then `:help vimwiki` to verify it was
@@ -185,6 +186,16 @@ _italic_ -- italic text
For other syntax elements, see `:h vimwiki-syntax` For other syntax elements, see `:h vimwiki-syntax`
### Todo lists
```text
- [.] Partially completed item with sub-tasks
- [X] Completed sub-task
- [ ] Incomplete sub-task
- [ ] Other incomplete sub-task
- [ ] Incomplete item
```
## Key bindings ## Key bindings
### Normal mode ### Normal mode
@@ -222,11 +233,13 @@ more bindings.
## Changing Wiki Syntax ## Changing Wiki Syntax
VimWiki currently ships with 3 syntaxes: VimWiki (default), Markdown VimWiki currently ships with 3 syntaxes: VimWiki (default), Markdown
(markdown), and MediaWiki (media). (markdown), and MediaWiki (media). Of these, the native VimWiki syntax is
best supported, followed by Markdown. No promises are made for MediaWiki.
**NOTE:** Only the default syntax ships with a built-in HTML converter. For **NOTE:** Only the default syntax ships with a built-in HTML converter. For
Markdown or MediaWiki see `:h vimwiki-option-custom_wiki2html`. Some examples Markdown or MediaWiki see `:h vimwiki-option-custom_wiki2html`. Some examples
and 3rd party tools are available [here](https://vimwiki.github.io/vimwikiwiki/Related%20Tools.html#Related%20Tools-External%20Tools). and 3rd party tools are available
[here](https://vimwiki.github.io/vimwikiwiki/Related%20Tools.html#Related%20Tools-External%20Tools).
If you would prefer to use either Markdown or MediaWiki syntaxes, set the If you would prefer to use either Markdown or MediaWiki syntaxes, set the
following option in your `.vimrc`: following option in your `.vimrc`:
@@ -238,20 +251,27 @@ let g:vimwiki_list = [{'path': '~/vimwiki/',
``` ```
This option will treat all markdown files in your system as part of vimwiki (check `set filetype?`). Add This option will treat all markdown files in your system as part of vimwiki
(check `set filetype?`). Add
```vim ```vim
let g:vimwiki_global_ext = 0 let g:vimwiki_global_ext = 0
``` ```
to your `.vimrc` to restrict Vimwiki's operation to only those paths listed in `g:vimwiki_list`.
Other markdown files wouldn't be treated as wiki pages. to your `.vimrc` to restrict Vimwiki's operation to only those paths listed in
`g:vimwiki_list`. Other markdown files wouldn't be treated as wiki pages.
See [g:vimwiki_global_ext](https://github.com/vimwiki/vimwiki/blob/619f04f89861c58e5a6415a4f83847752928252d/doc/vimwiki.txt#L2631). See [g:vimwiki_global_ext](https://github.com/vimwiki/vimwiki/blob/619f04f89861c58e5a6415a4f83847752928252d/doc/vimwiki.txt#L2631).
if you want to turn off support for other extension(for example, disabling accidently creating new wiki and link for normal markdown files), if you want to turn off support for other extension(for example, disabling
set the following option in your `.vimrc` before packadd vimwiki: accidently creating new wiki and link for normal markdown files), set the
following option in your `.vimrc` before packadd vimwiki:
```vim ```vim
let g:vimwiki_ext2syntax = {} let g:vimwiki_ext2syntax = {}
``` ```
See [g:vimiki_ext2syntax](https://github.com/vimwiki/vimwiki/blob/619f04f89861c58e5a6415a4f83847752928252d/doc/vimwiki.txt#L2652) See [g:vimiki_ext2syntax](https://github.com/vimwiki/vimwiki/blob/619f04f89861c58e5a6415a4f83847752928252d/doc/vimwiki.txt#L2652)
## Getting help ## Getting help
[GitHub issues](https://github.com/vimwiki/vimwiki/issues) are the primary [GitHub issues](https://github.com/vimwiki/vimwiki/issues) are the primary
@@ -259,18 +279,20 @@ method for raising bug reports or feature requests.
Additional resources: Additional resources:
- The IRC channel [#vimwiki](ircs://irc.libera.chat:6697/vimwiki) on irc.libera.chat - The IRC channel [#vimwiki](ircs://irc.libera.chat:6697/vimwiki) on
irc.libera.chat is the "official" discussion and support channel
- [Connect via webchat](https://web.libera.chat/?channels=#vimwiki) - [Connect via webchat](https://web.libera.chat/?channels=#vimwiki)
- Connect via Matrix/Element: [#vimwiki:libera.chat](https://matrix.to/#/#vimwiki:libera.chat) - [@vimwiki@wikis.world](https://wikis.world/@vimwiki) on the Fediverse
- Post to the [mailing list](https://groups.google.com/forum/#!forum/vimwiki).
## Helping VimWiki ## Helping VimWiki
VimWiki has a lot of users but only very few recurring developers or people VimWiki has a lot of users but only very few recurring developers or people
helping the community. Your help is therefore appreciated. Everyone can help! helping the community. Your help is therefore appreciated. Everyone can help!
See [#625](https://github.com/vimwiki/vimwiki/issues/625) for information on how you can help. See [#625](https://github.com/vimwiki/vimwiki/issues/625) for information on how
you can help.
Also, take a look at [CONTRIBUTING.md](https://github.com/vimwiki/vimwiki/blob/master/CONTRIBUTING.md) and [design_notes.md](doc/design_notes.md) Also, take a look at [CONTRIBUTING.md](https://github.com/vimwiki/vimwiki/blob/master/CONTRIBUTING.md)
and [design_notes.md](doc/design_notes.md)
---- ----
+11 -2
View File
@@ -262,11 +262,20 @@ function! vimwiki#base#resolve_link(link_text, ...) abort
\ vimwiki#vars#get_wikilocal('ext', link_infos.index) \ vimwiki#vars#get_wikilocal('ext', link_infos.index)
endif endif
else else
" append extension iff one not already present or it's not the targeted " append extension if one not already present or it's not the targeted
" wiki extension - https://github.com/vimwiki/vimwiki/issues/950 " wiki extension - https://github.com/vimwiki/vimwiki/issues/950
let ext = fnamemodify(link_text, ':e') let ext = fnamemodify(link_text, ':e')
let ext_with_dot = '.' . ext let ext_with_dot = '.' . ext
if ext ==? '' || ext_with_dot !=? vimwiki#vars#get_wikilocal('ext', link_infos.index)
" Check if a .md must be added
" See #1271 to modify files with a "."
let do_add_ext = ext ==? ''
if vimwiki#vars#get_syntaxlocal('open_link_add_ext')
let do_add_ext = do_add_ext || ext_with_dot !=? vimwiki#vars#get_wikilocal('ext', link_infos.index)
endif
" Add the dot
if do_add_ext
let link_infos.filename .= vimwiki#vars#get_wikilocal('ext', link_infos.index) let link_infos.filename .= vimwiki#vars#get_wikilocal('ext', link_infos.index)
endif endif
endif endif
+2 -1
View File
@@ -100,7 +100,8 @@ function! s:normalize_link_syntax_n() abort
let sub = vimwiki#base#normalize_link_in_diary(lnk) let sub = vimwiki#base#normalize_link_in_diary(lnk)
else else
let sub = vimwiki#base#normalize_link_helper(lnk, let sub = vimwiki#base#normalize_link_helper(lnk,
\ vimwiki#vars#get_global('rxWord'), '', \ vimwiki#vars#get_global('rxWord'),
\ vimwiki#vars#get_global('rxWord'),
\ vimwiki#vars#get_syntaxlocal('Link1')) \ vimwiki#vars#get_syntaxlocal('Link1'))
endif endif
call vimwiki#base#replacestr_at_cursor('\V'.lnk, sub) call vimwiki#base#replacestr_at_cursor('\V'.lnk, sub)
+4
View File
@@ -851,6 +851,10 @@ function! s:get_common_syntaxlocal() abort
" HTML comment " HTML comment
let res.comment_regex = {'type': type(''), 'default': '\%(^\s*%%.*$\|<!--\%([^>]\|\n\)*-->\)'} let res.comment_regex = {'type': type(''), 'default': '\%(^\s*%%.*$\|<!--\%([^>]\|\n\)*-->\)'}
" Opening link with dot in the ref, see #1271 and ref and Brennen comment:
" -- https://github.com/vimwiki/vimwiki/issues/1271#issuecomment-1482207680
let res.open_link_add_ext = {'type': type(1), 'default': 1}
return res return res
endfunction endfunction
+20 -4
View File
@@ -479,13 +479,13 @@ glp Decrease the "done" status.
gll n Increase the level of a list item. gll n Increase the level of a list item.
Remap command: `<Plug>VimwikiIncreaseLvlSingleItem` Remap command: `<Plug>VimwikiIncreaseLvlSingleItem`
gLl Increase the level of a list item and all child items. gLl Increase the level of a list item and all child items.
Remap command: `<Plug>VimwikiIncreaseLvlWholeItem` or gLL Remap command: `<Plug>VimwikiIncreaseLvlWholeItem`
*vimwiki_glh* *vimwiki_gLh* *vimwiki_glh* *vimwiki_gLh*
glh n Decrease the level of a list item. glh n Decrease the level of a list item.
Remap command: `<Plug>VimwikiDecreaseLvlSingleItem` Remap command: `<Plug>VimwikiDecreaseLvlSingleItem`
gLh Decrease the level of a list item and all child items. gLh Decrease the level of a list item and all child items.
Remap command: `<Plug>VimwikiDecreaseLvlWholeItem` or gLH Remap command: `<Plug>VimwikiDecreaseLvlWholeItem`
*vimwiki_glr* *vimwiki_gLr* *vimwiki_glr* *vimwiki_gLr*
glr n Renumber list items if the cursor is on a numbered glr n Renumber list items if the cursor is on a numbered
@@ -516,6 +516,13 @@ gl- n Make a list item out of a normal line or change the
gL- Change the symbol of the current list to -. gL- Change the symbol of the current list to -.
Remap command: `:VimwikiChangeSymbolInListTo -<CR>` Remap command: `:VimwikiChangeSymbolInListTo -<CR>`
*vimwiki_gl+* *vimwiki_gL+*
gl+ n Make a list item out of a normal line or change the
symbol of the current item to +.
Remap command: `:VimwikiChangeSymbolTo +<CR>`
gL+ Change the symbol of the current list to +.
Remap command: `:VimwikiChangeSymbolInListTo +<CR>`
*vimwiki_gl1* *vimwiki_gL1* *vimwiki_gl1* *vimwiki_gL1*
gl1 n Make a list item out of a normal line or change the gl1 n Make a list item out of a normal line or change the
symbol of the current item to 1., the numbering is symbol of the current item to 1., the numbering is
@@ -1514,7 +1521,7 @@ In this case, <mathjax_folder> would be "../mathjax" (without quotes).
2. Loading MathJax from a CDN-server (needs internet connection). 2. Loading MathJax from a CDN-server (needs internet connection).
Add to your HTML template the following lines: Add to your HTML template the following lines:
<script src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script> <script src="https://cdnjs.cloudflare.com/polyfill/v3/polyfill.min.js?features=es6"></script>
<script id="MathJax-script" async src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script> <script id="MathJax-script" async src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
@@ -3275,7 +3282,7 @@ cannot otherwise convert the link. A customized handler might look like this: >
let str = a:value let str = a:value
" complete URL " complete URL
let url_0 = matchstr(str, g:vimwiki_rxWikiInclMatchUrl) let url_0 = matchstr(str, g:vimwiki_global_vars.rxWikiInclMatchUrl)
" URL parts " URL parts
let link_infos = vimwiki#base#resolve_link(url_0) let link_infos = vimwiki#base#resolve_link(url_0)
let arg1 = matchstr(str, VimwikiWikiInclMatchArg(1)) let arg1 = matchstr(str, VimwikiWikiInclMatchArg(1))
@@ -4011,6 +4018,7 @@ Contributors and their Github usernames in roughly chronological order:
- Aarón Fas (@aaronfc) - Aarón Fas (@aaronfc)
- @jiamingc - @jiamingc
- Alex Claman (@claman) - Alex Claman (@claman)
- @qadzek
============================================================================== ==============================================================================
@@ -4030,6 +4038,14 @@ master is retained as a legacy mirror of the dev branch.
This is somewhat experimental, and will probably be refined over time. This is somewhat experimental, and will probably be refined over time.
2024.01.24~
New:~
* PR #1389: Document gLH, gl+, and gL+ mappings
* Tidy some aspects of README.md, remove pointers to defunct Matrix
channel and Google Group, add wikis.world Mastodon account.
2024.01.22~ 2024.01.22~
New:~ New:~
+1 -1
View File
@@ -11,7 +11,7 @@ endif
let g:loaded_vimwiki = 1 let g:loaded_vimwiki = 1
" Set to version number for release: " Set to version number for release:
let g:vimwiki_version = '2024.01.22' let g:vimwiki_version = '2024.01.24'
" Get the directory the script is installed in " Get the directory the script is installed in
let s:plugin_dir = expand('<sfile>:p:h:h') let s:plugin_dir = expand('<sfile>:p:h:h')
+1 -1
View File
@@ -257,7 +257,7 @@ Expect (Correctly formatted tags file):
!_TAG_PROGRAM_AUTHOR Vimwiki !_TAG_PROGRAM_AUTHOR Vimwiki
!_TAG_PROGRAM_NAME Vimwiki Tags !_TAG_PROGRAM_NAME Vimwiki Tags
!_TAG_PROGRAM_URL https://github.com/vimwiki/vimwiki !_TAG_PROGRAM_URL https://github.com/vimwiki/vimwiki
!_TAG_PROGRAM_VERSION 2023.05.12 !_TAG_PROGRAM_VERSION 2024.01.24
second-tag Test-Tag.md 13;" vimwiki:Test-Tag\tTest-Tag#second-tag\tTest-Tag#second-tag second-tag Test-Tag.md 13;" vimwiki:Test-Tag\tTest-Tag#second-tag\tTest-Tag#second-tag
test-tag Test-Tag.md 5;" vimwiki:Test-Tag\tTest-Tag#a-header\tA header test-tag Test-Tag.md 5;" vimwiki:Test-Tag\tTest-Tag#a-header\tA header
top-tag Test-Tag.md 1;" vimwiki:Test-Tag\tTest-Tag\tTest-Tag top-tag Test-Tag.md 1;" vimwiki:Test-Tag\tTest-Tag\tTest-Tag