On 2023-06-27 00:35, Dennis Nezic wrote:
On 26 Jun 19:53, Kim Woelders wrote:
On 2023-06-25 19:22, Dennis Nezic wrote:
Currently comments in bindings.cfg are parsed dumbly (but efficiently)
as the first occurrence of '#', even if it occurs in a pair of quotes.
Attached is a more intelligent way that handles such quotes.

"eesh exec" in a terminal, and the exec commands in the .menu files are
both able to handle this, I guess because the shell is doing that
parsing.

Eg.
        eesh exec logger http://hello#world
        eesh exec logger 'http://hello #world'

Hi Dennis,

Thanks for your input. I ended up doing this a bit differently and more
along the lines of what was done in similar situations elsewhere.
The primary difference is probably that the whitespace before a comment
should also be stripped.
Also, escapes(\) are not handled specially as they are not either in
similar cases elsewhere.

Cool! This does what I need (html #links), although it doesn't
properly handle nested quotes? - not sure if they should.

Eg.  command "argument with 'nested quote'" # a comment

Right, fixed now, I think.

Thanks :)

/Kim




_______________________________________________
enlightenment-users mailing list
enlightenment-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/enlightenment-users

Reply via email to