Files
pandoc/test/command/7678.md
T
John MacFarlane c0ff59c272 BibTeX parser: fix handling of % in url field.
`%` does not function as a comment character inside `url`
(where URL-encoding is common).

Commit 6fb2973a58 mistakenly
took this reassignment of `%` to be a general feature of
braced (but not quoted) BibTeX fields.

This commit restores the correct behavior of `%` in braced fields
other than `url`, and corrects the behavior of `%` in `url`
when the value is quoted.

Closes #7678 (again).
2022-09-18 19:17:48 -07:00

397 B

% pandoc -f bibtex -t csljson
@misc{doe,
  author = "Jane Doe",
  title = "Work",
  year = "2021",
  url = "%20and%20"
}
^D
[
  {
    "URL": "%20and%20",
    "author": [
      {
        "family": "Doe",
        "given": "Jane"
      }
    ],
    "id": "doe",
    "issued": {
      "date-parts": [
        [
          2021
        ]
      ]
    },
    "title": "Work",
    "type": ""
  }
]