masukomi / masukomi/vim-markdown-folding
markdown folding not working if I open a non-markdown file first
Nobody has claimed this yet.
- Dominant language
- Vim Script
- Stars
- 257
- Forks
- 44
- PR merge metrics
- No merged PRs in 30d
Description
I'm using MacVim 8.2.261. I have installed folding.vim so that it is found by vim. (vim 8 packages) I have verified that it is found by running :scriptnames. I have verified that foldmethod=expr.
If I choose to edit a markdown file first thing on opening vim, it folds properly - it opens in a completely folded state and I can open and close the folds as expected using the vim keys.
However, if I open .vimrc first (for instance) and then open a markdown file, it opens completely unfolded and fold command are ignored.
I have discovered, though, that if I source folding.vim after that, then folding works again.
I'm reasonably certain I have set everything up as stated in the GitHub site. Do you have any idea what might be going on?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the behavior by opening .vimrc before a Markdown file, then compare it with opening the Markdown file first. Inspect folding.vim and the Vim settings shown in the report, especially foldmethod, and confirm that Markdown folding is initialized automatically after the filetype change without manually sourcing folding.vim.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- vim
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100