aboutsummaryrefslogtreecommitdiff
path: root/test/command/3752.md
blob: 863e3f2d48239bd139510fa45d82cdbc78c4688d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
```
% pandoc command/chap1/text.md command/chap2/text.md -f markdown+rebase_relative_paths --verbose -t docx -o - | pandoc -f docx -t plain
^D
[INFO] Loaded command/chap1/spider.png from command/chap1/spider.png
[INFO] Loaded command/chap2/spider.png from command/chap2/spider.png
[INFO] Loaded command/chap1/../../lalune.jpg from command/chap1/../../lalune.jpg
Chapter one

A spider: [spider]

Another spider: [another spider]

The moon: [moon]

Link to spider picture.

URL left alone: manual.

Absolute path left alone: absolute.

Link to fragment: chapter two.

Empty path: empty.

Chapter two

A spider: [spider]
```

```
% pandoc command/chap1/text.md command/chap2/text.md -f markdown+rebase_relative_paths -t html
^D
<h1 id="chapter-one">Chapter one</h1>
<p>A spider: <img src="command/chap1/spider.png" alt="spider" /></p>
<p>Another spider: <img src="command/chap2/spider.png" alt="another spider" /></p>
<p>The moon: <img src="command/chap1/../../lalune.jpg" alt="moon" /></p>
<p>Link to <a href="command/chap1/spider.png">spider picture</a>.</p>
<p>URL left alone: <a href="https://pandoc.org/MANUAL.html">manual</a>.</p>
<p>Absolute path left alone: <a href="/foo/bar/baz.png">absolute</a>.</p>
<p>Link to fragment: <a href="#chapter-two">chapter two</a>.</p>
<p>Empty path: <a href="">empty</a>.</p>
<h1 id="chapter-two">Chapter two</h1>
<p>A spider: <img src="command/chap2/spider.png" alt="spider" /></p>
```

```
% pandoc command/chap1/text.md command/chap2/text.md -f commonmark+rebase_relative_paths -t html
^D
<h1>Chapter one</h1>
<p>A spider: <img src="command/chap1/spider.png" alt="spider" /></p>
<p>Another spider: <img src="command/chap2/spider.png" alt="another spider" /></p>
<p>The moon: <img src="command/chap1/../../lalune.jpg" alt="moon" /></p>
<p>Link to <a href="command/chap1/spider.png">spider picture</a>.</p>
<p>URL left alone: <a href="https://pandoc.org/MANUAL.html">manual</a>.</p>
<p>Absolute path left alone: <a href="/foo/bar/baz.png">absolute</a>.</p>
<p>Link to fragment: <a href="#chapter-two">chapter two</a>.</p>
<p>Empty path: <a href="">empty</a>.</p>
<h1>Chapter two</h1>
<p>A spider: <img src="command/chap2/spider.png" alt="spider" /></p>
```