npm-bump
npm-bump copied to clipboard
allow ignoring unknown files + tests
allow ignoring unknown files...
a project may contain files that are not ready to be committed (unknown; not yet git added).. this lets you npm-bump even if your project contains unknown files...
Current logic was to break on any output from git status -s .. This change allows execution when the files start with ?? (unknown files; not yet added)..
I had to change some stuff to be able to create tests... As there are not any tests I did not want to refactor the module for easier/normal test support. I have only done the bare minimum to create tests that support the change...
A possible todo is to add a prompt confirming you want to ignore these files.. or just mention the unknown files...
This seems like it could be done if a file is truly untracked (I don't think we could do it for tracked changed files because of all git resets that are invoked etc.). This seems to introduce some risk, though so I'd like to first setup some test infrastructure for this project (a hard requirement before bumping the version to 0.1.0). This is tracked in #9.