Skip to content

Commit 89582fd

Browse files
committed
Use only startFrom and endAt (pandoc documentation)
1 parent 0b98beb commit 89582fd

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

pandoc_codeblock_include.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,12 @@ def include(elem, doc):
1919
found = True
2020
except IOError:
2121
debug('[WARNING] pandoc-codeblock-include: ' + value + ' not found')
22-
elif name == 'start-from' or name == 'startFrom':
22+
elif name == 'startFrom':
2323
try:
2424
start_from = int(value) - 1
2525
except ValueError:
2626
debug('[WARNING] pandoc-codeblock-include: ' + value + ' is not a correct integer')
27-
elif name == 'end-at' or name == 'endAt':
27+
elif name == 'endAt':
2828
try:
2929
end_at = int(value)
3030
except ValueError:

tests/test_include.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,11 @@ def test_include():
2525
def test_include_start_from():
2626
verify_conversion(
2727
'''
28-
``` {include="tests/lorem" start-from="2"}
28+
``` {include="tests/lorem" startFrom="2"}
2929
```
3030
''',
3131
'''
32-
``` {include="tests/lorem" start-from="2"}
32+
``` {include="tests/lorem" startFrom="2"}
3333
Duis pretium rutrum dignissim.
3434
Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas.
3535
Interdum et malesuada fames ac ante ipsum primis in faucibus.
@@ -41,11 +41,11 @@ def test_include_start_from():
4141
def test_include_end_at():
4242
verify_conversion(
4343
'''
44-
``` {include="tests/lorem" end-at="2"}
44+
``` {include="tests/lorem" endAt="2"}
4545
```
4646
''',
4747
'''
48-
``` {include="tests/lorem" end-at="2"}
48+
``` {include="tests/lorem" endAt="2"}
4949
Lorem ipsum dolor sit amet, consectetur adipiscing elit.
5050
Duis pretium rutrum dignissim.
5151
```

0 commit comments

Comments
 (0)