ajoberstar / reckon

Infer a project's version from your Git repository.
Apache License 2.0
187 stars 28 forks source link

Better error message when repo is not clean #91

Closed ajoberstar closed 1 year ago

ajoberstar commented 6 years ago

When trying to release a significant version and have a dirty repo, you get an exception, which explains this, but doesn't say what files are in an unclean state. Should include a formatted version of the status output to make this easier to use.

ajoberstar commented 6 years ago

Not entirely clear where to put this code-wise. We don't want to do that formatting when its not needed, and we don't know we need it until long after the inventory was calculated.

Dropping this idea for now.

ajoberstar commented 6 years ago

As evidenced by #95, there would be benefit in improving the message.

sschuberth commented 5 years ago

Improving the message to actually state what is considered "unclean" would be very welcomed. In my case it was git-submodules for which I had configured ignore = untracked which apparently is not honored by JGit. Not very obvious.

ewallerman commented 3 years ago

Running CI in Jenkins that cleans the workspace when syncing from the git repo, try to build a final release but got "Caused by: java.lang.IllegalStateException: Cannot release a final or significant stage without a clean repo. at org.ajoberstar.reckon.core.Reckoner.reckon(Reckoner.java:54)" git status on commandline "working tree clean" Could not find the reason for the exception. Improving the message to actually state what is considered "unclean" would be very welcomed.