diff options
| author | John MacFarlane <jgm@berkeley.edu> | 2022-09-19 03:11:40 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-09-18 18:11:40 -0700 |
| commit | 311a3406878d4f02ffe4c087ece82f9d4156ff92 (patch) | |
| tree | d097d4b4900fec974d3884bd13cc777bc8ef4abe /test/command/file2.txt | |
| parent | d79f8386d4cf6925c46e66795baee945fea695c5 (diff) | |
Add prefixes to identifiers with `--file-scope`. (#8282)
This change only affects the case where `--file-scope` is used
and more than one file is specified on the command line.
In this case, identifiers will be prefixed with a string
derived from the file path, to disambiguate them. For example,
an identifier `foo` in `contents/file1.txt` will become
`contents__file1.txt__foo`. Links will be adjusted accordingly:
if `file2.txt` links to `file1.txt#foo`, then the link will
be changed to point to `#file1.txt__foo`. Similarly, a link
to `file1.txt` will point to `#file1.txt`. A Div with an
identifier derived from the file path will be added around
each file's content, so that links to files will still work.
Closes #6384.
[API change]: Text.Pandoc.Shared exports `textToIdentifier`.
Diffstat (limited to 'test/command/file2.txt')
| -rw-r--r-- | test/command/file2.txt | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/test/command/file2.txt b/test/command/file2.txt new file mode 100644 index 000000000..20ee06c8c --- /dev/null +++ b/test/command/file2.txt @@ -0,0 +1,5 @@ +## Zed + +[foo]: baz + +[foo] |
