nbstripout
strip output from Jupyter and IPython notebooks
...Strip output from IPython / Jupyter / Zeppelin notebook (modifies the file in-place). Usually, nbstripout is installed per repository so you can choose where to use it or not. You can choose to set the attributes in .gitattributes and commit this file to your repository, however there is no way to have git set up the filters automatically when someone clones a repository.