开源软件名称(OpenSource Name):masukomi/vim-markdown-folding开源软件地址(OpenSource Url):https://github.com/masukomi/vim-markdown-folding开源编程语言(OpenSource Language):Vim Script 98.5%开源软件介绍(OpenSource Introduction):[ Looking for new maintainer see note at end. ] This plugin enables folding by section headings in markdown documents. FeaturesThis plugin adds the ability to fold the following markdown elements:
UsageBy default this plugin will use "Stacked" folding which looks like this when everything is folded.
You can use "Nested" folding, where folding the "Topmost heading" will also nest all the deeper sections under it.
To toggle between the two folding styles use If you'd like to have it default to "Nested" folding add this to your autocmd FileType markdown set foldexpr=NestedMarkdownFolds() InstallationAfter installing set nocompatible
if has("autocmd")
filetype plugin indent on
endif The TroubleshootingFirst, Vim must recognize the file you are in as a Markdown file. There are a variety of ways Vim can be instructed to "fold" things. When you add
a plugin to support a new language / format the plugin will tell Vim "Hey here's
the method to use for figuring out the start and end of a fold with this language".
This plugin uses a ContributingPRs are always a welcome thing, but it should be noted that the current intent is to keep this plugin pretty focused on folding Markdown. All new PRs should include tests. If you're fixing a bug please add a test to make sure it never comes back. If you're adding a new feature please add tests to make sure we never break it with future changes. The tests are currently all contained in Running TestsThe test setup requires Ruby. For those unfamiliar with Ruby development you'll want to cd into the Install bundler if you don't have it already.
Tell bundler to install the required dependencies
Tell bundler to run the tests
The end of the output should look something like this
LicenseCreated by Drew Neil. Copyright Drew Niel and all the contributors.
Distributed under the same terms as Vim itself. See With community improvements by: Maintained by masukomi Looking for New MaintainerThis works fine, but there are improvements that can be made, and PRs that need addressing. If you've familiar with vim-script and have some vim-script stuff you can point at, gimme a holler @masukomi@connectified.com on mastodon or @masukomi on twitter. I use Doom Emacs these days so vim-script isn't where my head is. |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论