Summary: | app-editors/vim - incorrect syntax highlighting with odd quotations | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Andrew <gentoo-bugs.10.drkshadow> |
Component: | Current packages | Assignee: | Vim Maintainers <vim> |
Status: | RESOLVED UPSTREAM | ||
Severity: | minor | ||
Priority: | High | ||
Version: | 2006.0 | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- |
Description
Andrew
2007-05-08 06:16:42 UTC
Well, changing to this line makes highlighting work properly, and works almost exactly the same as your code (only that statement is now run in a subshell): outputFile="--output-document=$(echo "${output:9}" | sed "s/['\\"]//g")" Also, for that simple of a sed, why not just use the string manipulation powers of bash? output=${output:9} # get all but the first 9 chars of the name output=${output//\'/} # remove all single quotes output=${output//\"/} # remove all double quotes I'm sure there're a few other ways bash would let you do this as well. Also, your current code would call: wget --output-document=--output-document=cleanfilename.txt Which probably doesn't make wget happy. That'll avoid the ugly echo|sed stuff altogether (and make running this faster, since you aren't forking any other processes). But bash scripting issues aside, this is the sorta bug that would be better reported to vim upstream, since it's a bug in the sh.vim script they distribute. Here's their instructions for submitting a bug report (taken from their FAQ): 2.6. Where can I report bugs? First collect the required information using the following command: :source $VIMRUNTIME/bugreport.vim Now send the resulting text from the above command to the bugs@vim.org e-mail address. The Vim Development mailing list (see above) is a good place to discuss general bugs. If the bug you find is with syntax highlighting or some other "added feature" (i.e. not directly programmed into vim), attempt to inform the maintainer of that feature. For more information, read :help bug-reports I'm going to close this as UPSTREAM for now. When a patch is made to fix this, I'll make a new gentoo release of vim. |