Skip to content

Pre-commit hook to check order of Jupyter notebook cells

License

Notifications You must be signed in to change notification settings

stefsmeets/nbcheckorder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

nbcheckorder

Pre-commit hook to check the order of Jupyter notebook cells.

Prevents notebooks from being commited if the cell order is not sequential. This can avoid hidden state, or make sure that WIP notebooks are not commited by accident.

Try it out by running:

pre-commit try-repo https://github.com/stefsmeets/nbcheckorder/ --all-files

Installing it as a pre-commit hook

See pre-commit for instructions.

Sample .pre-commit-config.yaml:

  - repo: https://github.com/stefsmeets/nbcheckorder/
    rev: v0.2.0
    hooks:
      - id: nbcheckorder

About

Pre-commit hook to check order of Jupyter notebook cells

Resources

License

Stars

Watchers

Forks

Packages

No packages published