-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Ampersands and equal signs break parsing #8
Comments
I am not set up to be able to easily test this at the moment. I suspect that your solution of double-encoding the characters is not correct, however. I'm actually uncertain if If you feel up to giving that a try, I'd be very grateful. |
Took a second look and things work with no url = sys.argv[1]
config = read_config()
cmd = emacs_client_command(config)
cmd.append(url)
subprocess.check_output(cmd) appears to work. You don't happen to remember why If we don't think there's a reason |
I can confirm that the unquote in main isn't required and the original URL needs to be passed on to Emacs. With the unquote present YouTube URLs are truncated, amongst other problems. |
First off, thanks for this util! ❤️
I've noticed that titles with ampersands are breaking the parser, e.g.
python parse.py 'org-protocol://capture?template=w&url=https%3A%2F%2Fexample.com&title=foo%20%26%20bar'
should send the title "foo & bar" through, but only characters up to the ampersand are sent ("foo " with a trailing space). This is also the case with equal signs (
=
).I've worked around this by modifying
parse.py
but I'm not sure this is correct. Also not sure if there are other characters that cause parsing to break.Thanks!
The text was updated successfully, but these errors were encountered: