- Install the nbconvert package, though you probably already have it if you are using jupyter.
- Put the
nb2mdscript below in your path and make executable - Add the following to your
.gitattributesfile, which can be in your home directory (usenb2mdfor all projects) or in the root of your project:
*.ipynb diff=nb2md
- Run
git config --global diff.nb2md.textconv nb2md
to use nb2md for all projects, or add the following to your project's .git/config
[diff "nb2md"]
textconv = nb2md
- 😊
this seems to fail with spaces in filenames, right?