diff --git a/autoload/vimwiki/base.vim b/autoload/vimwiki/base.vim index 2529071..60d8467 100644 --- a/autoload/vimwiki/base.vim +++ b/autoload/vimwiki/base.vim @@ -1091,16 +1091,8 @@ function! vimwiki#base#edit_file(command, filename, anchor, ...) abort echom 'Vimwiki: Vim couldn''t open the file, probably because a swapfile already exists. See :h E325.' return endtry - " If the opened file was not already loaded by Vim, an autocommand is " triggered at this point - - " Make sure no other plugin takes ownership over the new file. Vimwiki - " rules them all! Well, except for directories, which may be opened with - " Netrw - if !vimwiki#u#ft_is_vw() && fname !~? '\m/$' - call vimwiki#u#ft_set() - endif endif " Goto anchor diff --git a/doc/vimwiki.txt b/doc/vimwiki.txt index 7fe36d7..53b0291 100644 --- a/doc/vimwiki.txt +++ b/doc/vimwiki.txt @@ -3766,6 +3766,7 @@ Changed:~ Removed:~ Fixed:~ + * Issue #979: Fix: Accessing other filetypes within vimwiki * Issue #886: VimwikiGenerateLinks crash with single quote in filename * Issue #910: Fix: VimwikiTOC removes next non-empty line * Issue #182: VimwikiTOC support headers with link diff --git a/test/filesystem.vader b/test/filesystem.vader new file mode 100644 index 0000000..8bc4c5d --- /dev/null +++ b/test/filesystem.vader @@ -0,0 +1,33 @@ +# Travel thought files + +Execute (Copy Wiki's Resources): + Log "Start: Copy Resources" + call CopyResources() + + +Given (Void for Accessing other files within vimwiki #979 {{{1): + + +Do (At Index: Create and goto pythonfile): + :VimwikiIndex 2\ + Opyfile.py\\\ + :AssertEqual 'pyfile.py', expand('%:t')\ + :AssertEqual 'python', &ft\ + :Log "Clean pyfile"\ + dd + :VimwikiIndex 2\ + :call DeleteFile('pyfile.py')\ + + +Do (At Index: Create and goto markdownfile): + :VimwikiIndex 2\ + Omdfile.md\\\ + :AssertEqual 'mdfile.md', expand('%:t')\ + :AssertEqual 'vimwiki', &ft\ + :Log "Clean mdfile"\ + :VimwikiIndex 2\ + dd + :call DeleteFile('mdfile.md')\ + + +# vim: sw=2:foldmethod=marker:foldlevel=30:foldignore=: