This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /usr/bin/env python | |
"""From http://stackoverflow.com/a/20844506/1951857 | |
To use:: | |
# Add the script to your path | |
chmod +x path/to/this/ipynb_output_filter.py | |
echo "*.ipynb filter=dropoutput_ipynb" >> ~/.gitattributes | |
git config --global core.attributesfile ~/.gitattributes | |
git config --global filter.dropoutput_ipynb.clean ipynb_output_filter.py |