Closed tusj closed 9 years ago
I'm not seeing this. In fact, vim-fish doesn't even detect funced
functions, because it doesn't have a filename or shebang.
What I am seeing is if the first line of a function is a comment, then the comment gets erased, but fish appears to be doing that on its end, when the function is created (either on the commandline or as a file stored in ~/.config/fish/functions/
). Every comment after the very first line of the function is left intact, and survives being edited by vim.
Did you do something to make funced
functions actually enable the fish filetype?
I retested on my machine with setting the nano as EDITOR, and I can confirm that it is the same problem. So that excludes vim-fish as the source. So false alarm, sorry for that.
I had a look at the funced definition, and from what I can see it does not seem to do that much.
It's not funced
, the actual function definition loses the comment. I'll file an issue on the fish project to track it. In the meantime, you should probably close this vim-fish issue.
I've filed it as fish-shell/fish-shell#1710. Please comment there if I did not accurately capture what you're seeing.
Thanks. The report is what I experienced. Closing.
When editing a function with funced, the commented lines are replaced by empty lines.
This happens only if I use vim with this plugin and using the funced program. Removing this plugin, or not sourcing any files by setting the -u flag for vim, I don't have this problem. Simply calling vim test_function.fish will not trigger it either.
I don't see why it happens with funced, and maybe I did not properly probe the error. But it certainly is vim-fish which is causing the issue.