-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error: .git directory not found. Betterer must be used within a git repository. #1129
Comments
This is by design, as git is useful for more than just diff checking, (e.g. for maintaining the cache), and most CI systems are have got available for cloning the project they are building. Not planning on changing this, but happy to look at a PR. |
I hope you might reconsider, if you are using a multi-stage Dockerfile for testing, requiring git to work properly means the entire layer is uncachable since you have to copy the |
Fair enough, I'll have a think |
I agree with @davidbarratt that multi-stage Dockerfile's are very common in CI. Requiring I haven't looked at this library close enough yet to understand how difficult it will be to remove the requirement but if you have any ideas I am happy to try and help contribute to a fix. |
This is an issue for us as well, our CI uses docker and doesn't copy over the |
Just ran into this issue as well, and git is just used to list files, so |
Almost done with v6 so thinking about the future of this, and I guess most of what Betterer uses git for could be replaced by traversing the file structure and then respecting a .gitignore file if it is present? |
Describe the bug
Betterer requires a
.git
directoryTo Reproduce
Run
betterer ci
without a.git
directory.Expected behavior
I expected betterer to create a new results file and use diff (or something like it) in order to check for differences.
Screenshots
N/A
Versions (please complete the following information):
Additional context
I don't really understand why it would need git in the CI
The text was updated successfully, but these errors were encountered: