You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
GitLab CI build fails with No ancestor could be found between any of HEAD and master, origin/master, upstream/master, main, origin/main, upstream/main
#200
Open
BryanHuntNV opened this issue
Oct 21, 2023
· 4 comments
When running under GitLab CI, the plugin executes yarn version and I get the error:
No ancestor could be found between any of HEAD and master, origin/master, upstream/master, main, origin/main, upstream/main
I can run yarn version in the project just fine locally, but if I add that command to the GitLab CI job (and not use the plugin), I can reproduce the error. I suspect the problem is related to GitLab CI checking out the project in a detached head state.
I haven't been able to find a solution, so I may just write my own plugin that uses jq to update the package version.
The text was updated successfully, but these errors were encountered:
It's not very clear from the yarn docs, but one of the advantages of using yarn version is that it updates workspace: references in monorepos. See https://yarnpkg.com/cli/version/apply for more information.
Depending on your use-case, manually updating the version in package.json through a plugin may work, I'm not sure how though...
If we can solve this for everyone on GitLab it would be good. Not running GitLab atm but if you have more details I can help investigate.
When running under GitLab CI, the plugin executes
yarn version
and I get the error:I can run
yarn version
in the project just fine locally, but if I add that command to the GitLab CI job (and not use the plugin), I can reproduce the error. I suspect the problem is related to GitLab CI checking out the project in a detached head state.I haven't been able to find a solution, so I may just write my own plugin that uses
jq
to update the package version.The text was updated successfully, but these errors were encountered: