> Quoting it as "#" or '#' does not seem to help (it is still > replaced by the file name), and \# (backslash pound) results > in a shell syntax error. > > I want to re-format block comments in shell scripts using the > 'fmt' command. The "#" at the start of each line means that > the command should be > > <first>,<last>! fmt -p #
I think it requires double-escaping: the first to escape the "#" so the bash command is "fmt -p \#", and then a second escaping to prevent Vim from swallowing the backslash: <first>,<last>! fmt -p \\# which worked(*) for me. -tim (*) worked = "didn't give me an error, but I don't have any good test-data to see if fmt actually did what was expected" --~--~---------~--~----~------------~-------~--~----~ You received this message from the "vim_use" maillist. For more information, visit http://www.vim.org/maillist.php -~----------~----~----~----~------~----~------~--~---
