@@ -214,9 +214,10 @@ For example, create a file called `tricks.yaml` containing
214
214
from pathlib import Path
215
215
from nbconvert.exporters.python import PythonExporter
216
216
from importnb.compile import export
217
- for path in Path(' src/notebooks/' ).rglob(""" *.ipynb""" ):
217
+ root = ' src/importnb/notebooks/'
218
+ for path in Path(root).rglob(""" *.ipynb""" ):
218
219
if ' checkpoint' not in str (path):
219
- export(path, Path(' src/importnb' ) / path.with_suffix(' .py' ).relative_to(' src/notebooks ' ))
220
+ export(path, Path(' src/importnb' ) / path.with_suffix(' .py' ).relative_to(root ))
220
221
221
222
__import__ (' unittest' ).main(module = ' src.importnb.tests.test_unittests' , argv = " discover --verbose" .split(), exit = False )
222
223
@@ -231,7 +232,7 @@ For example, create a file called `tricks.yaml` containing
231
232
test_imports (src.importnb.tests.test_unittests.TestRemote) ... skipped 'requires IP'
232
233
233
234
----------------------------------------------------------------------
234
- Ran 7 tests in 2.022s
235
+ Ran 7 tests in 2.023s
235
236
236
237
OK (skipped=1, expected failures=1)
237
238
@@ -242,10 +243,6 @@ For example, create a file called `tricks.yaml` containing
242
243
! jupyter nbconvert -- to markdown readme.ipynb
243
244
```
244
245
245
- [NbConvertApp] Converting notebook readme.ipynb to markdown
246
- [NbConvertApp] Writing 7130 bytes to readme.md
247
-
248
-
249
246
if __name__ == '__main__':
250
247
from IPython.display import display, Image
251
248
!pyreverse importnb -opng -pimportnb
0 commit comments