TARGETDIR=~/.scripts/ SCRIPT=ipynb_drop_output.py mkdir $TARGETDIR cp ./${SCRIPT} $TARGETDIR chmod +x $TARGETDIR$SCRIPT touch ~/.gitattributes echo "*.ipynb filter=clean_ipynb" > ~/.gitattributes git config --global core.attributesfile ~/.gitattributes git config --global filter.clean_ipynb.clean $TARGETDIR$SCRIPT git config --global filter.clean_ipynb.smudge cat echo "installed the ipynb filter"