-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Build fails with checkout v2 #113
Comments
Need more info. Is something different between the layout when using v2 vs v1, that is causing your build step to fail? Otherwise does your build require additional git history? V2 was optimized for the mainline and only fetches a single commit rather than all history. Note, the error sounds related to reading an xml file. |
@ericsciple sorry about that; more info revealed after enabling Cake diagnostic verbosity. I'm using GitVersion and it clearly doesn't like "shallow" checkout v2:
Full error in log here. I'm not sure if GitVersion can do anything about this, so is there something that could be made configurable to help in checkout v2? |
@gitfool oh gotcha. V2 was optimized to fetch a single commit. If you need more history for the branch being fetched, then increase the Otherwise if you need all history, i think I'll update the docs to include an example to fetch all history for all branches and tags. |
Updated the docs: #115 |
@ericsciple note that As I just mentioned here, it would be much nicer to have a |
@ericsciple Can you please add a parameter to |
@AArnott the |
Oh sheesh. I don't know how I missed that in the README. Thanks, @ericsciple. |
@ericsciple the |
i have some changes in mind, collecting some feedback from my immediate team and will publish a proposal soon |
@ericsciple gentle nudge; have you made any progress on the above? 🙏 |
@ericsciple no worries. My use case is that I currently need to follow checkout with: - name: Fetch unshallow
run: git fetch --prune --tags --unshallow in order to get full history as needed by GitVersion. Needless to say, I'd love to get rid of this extra step. |
Using v2 is very clunky right now when your build steps require the output of |
@bastimeyer i agree. You should +1 this proposal #155 :) |
That fixes my problem, thanks @gitfool |
@GiorgioBertolotti that hack is no longer needed. See gitfool/Cake.Dungeon@9713d4f. |
Add `fetch-depth: 0` to the dotnet pipeline as indicated [here](actions/checkout#113 (comment)).
See gitfool/Cake.Dungeon workflow builds for commit 7963aee:
Failing in with an obscure error:
If I revert to checkout v1 it builds successfully again.
The text was updated successfully, but these errors were encountered: