Closed ccarpo closed 5 years ago
This is outside the scope of the plugin. The plugin is using the Keypirinha API to parse the settings.
I would suggest reading Keypirinha's documentation for the INI format used in configuration files. This will tell you how to properly escape things.
@ccarpo the $
character must be escaped by doubling it. The aforementioned error message gives you the workaround to be applied: '$' must be followed by '$' or '{'
.
This should do (untested):
[snippet/OhMyZshInstall]
string = sh -c "$$(curl -fsSL 'https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh')"
Notice the $$
sequence. I also quoted the URL.
Hello, I would like to summarize some extra info about this for fellow users.
Looks like Keypirinha uses configparser.ExtendedInterpolation. That means u need to escape the $
, as mentioned by the others, and as explained in the documentation linked below.
$ is the only character that needs to be escaped
For extra info: https://docs.python.org/3/library/configparser.html#configparser.ExtendedInterpolation
[Escape]
cost: $$80 # use a $$ to escape the $ sign ($ is the only character that needs to be escaped)
Hello there,
Setup
I try to create a snippet with the following String:
Problem
Keypirinha try to parse this and produces the following error:
What I tried
I tried to set single quotes or double quotes (replacing the existing double quotes with single quotes) around the whole string and to escape the $ with \ Non of that worked.
Expected Behaviour
Description how to deal with such issues or a fix to ignore this issue.