As far as storing a human readable version for code reviews and diffs, we use nbautoexport for this - https://nbautoexport.drivendata.org/ - which automatically exports plain text source files.
(Disclaimer: this tool was written and maintained by colleagues of mine.)