Hacker GitHub

← All repos

kynan/nbstripout

View on GitHub ↗ ★ 1,494 Python

strip output from Jupyter and IPython notebooks

12 mentions on Hacker News by 11 people: 0 stories, 12 comments · first 2017-04-04 · latest 2023-07-07

Mentions per year 12 mentions · busiest year 2018 (5)
20082026
  1. nbstripout[0] does that and installs a pre-commit hook [0] -- https://github.com/kynan/nbstripout
    comment by andrecosta · 2023-07-07 · in Git and Jupyter Notebooks Guide
  2. …plots and other rendered content and only kept text and code in git index. I'm almost sure it was https://github.com/kynan/nbstripout but it's been a while and I could be wrong. Once the hook was in place git diff worked well enough to not…
  3. You can use it with source control, I do it for about 18 notebooks I use on a daily basis: https://github.com/kynan/nbstripout
    comment by throwaway10102 · 2021-01-31 · in NumPy 1.20
  4. …runs before any git operations, whether it's add, commit, diff or an interactive rebase. [0] https://github.com/kynan/nbstripout
  5. I recommend nbstripout https://github.com/kynan/nbstripout It eases most of the pain regarding version control. You can use it as a 'git filter', so only inputs would be shown in diffs and committed (and also works with interactive…
    comment by karlicoss · 2020-01-28 · in What’s wrong with computational notebooks?
  6. …jupytext[4] for converting notebooks to markdown and vice-a-versa [1] https://www.reviewnb.com/ [2] https://github.com/kynan/nbstripout [3] https://github.com/jupyter/nbdime [4] https://github.com/mwouts/jupytext
  7. …the index (without affecting your working copy). (Surprised it's not mentioned in the article.) [1] https://github.com/kynan/nbstripout
    comment by KerrickStaley · 2018-12-22 · in How to Version-Control Jupyter Notebooks
  8. I would encourage everyone to use https://github.com/kynan/nbstripout before commiting.
    comment by stadeschuldt · 2018-08-28 · in JupyterCon: I don't like Notebooks [slides]
  9. Not OP, but I can recommend the handy https://github.com/kynan/nbstripout which acts as a git filter which makes version control ignore cell outputs. With that approach, though notebooks are clean they're still fairly poor for easily…
  10. …such as rendered output and run counters, but that is a trade-off to be decided by your team: https://github.com/kynan/nbstripout
  11. Here is a pip package called "nbstripout" which tell git to ignore notebook output: https://github.com/kynan/nbstripout It can really help establish good practice in a project with little effort: pip install --upgrade nbstripout nbstripout…
    comment by Nic56 · 2018-02-20 · in JupyterLab is ready for users
  12. …notebooks. There's talk of automatically saving code only separate versions in future releases. [0] https://github.com/kynan/nbstripout
    comment by Y_Y · 2017-04-04 · in Jupyter Notebook 5.0