Skip to content

fix: citations, dollar signs and lists in the output; version 0.5.0 - #4

Open
aeskildsen wants to merge 2 commits into
mainfrom
fix/citation-locators
Open

aeskildsen wants to merge 2 commits into
mainfrom
fix/citation-locators

Conversation

@aeskildsen

Copy link
Copy Markdown
Owner

Fix the TeX citations, two related TeX output bugs and a list bug, and set the version to 0.5.0.

  • Citations: no part of a citation is dropped. Before, locators such as p.106, p. 121-122, chap. 2 or a range with an en dash were lost without a message. In a citation of more than one source, each locator now goes with its source.
  • Badly formed citations such as [@a p. 3] or [@a; see @b] stop the conversion with ParsingException. Before, they gave wrong output or a TypeError.
  • Keys: _, & and $ in a citation key are not escaped, so biblatex finds the key.
  • Dollar signs: a $ that is not part of math gives \$. Before, it gave a line break and an &.
  • Lists: an unordered list at the end of a text needs no final newline (TeX and schelp).
  • Release: version 0.5.0 in pyproject.toml and CHANGELOG.md.

The TeX output now differs from md2tex in these cases. docs/design.md lists them.

Checked:

  • All tests pass with sclang; the new tests failed before the fixes. The test fixtures did not change.
  • LaTeX with biber compiles the new citation forms with no undefined citation.
  • Random texts with no citation and no $, with a final newline, give the same output as main.

- TeX: no part of a citation is dropped. Each locator goes with its source.
  A badly formed citation stops the conversion with a message.
- TeX: citation keys have no TeX escapes.
- TeX: a `$` that is not part of math is `\$`.
- An unordered list at the end of a text needs no final newline.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant