-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Upgrade go git #28628
Upgrade go git #28628
Conversation
Unfortunately, ref #28518 BUT |
CI fail seems related |
It seems to be the issue with go-git. I can get the commit using Maybe go-git is not reading
|
Can you send this issue to upstream? |
Done go-git/go-git#1002 |
Use alternate fs required by gogit v5.11.0
modules/git/repo_base_gogit.go
Outdated
for scanner.Scan() { | ||
// FIXME: we just use the first alternate because it seems go-git don't support multiple alternates yet | ||
altPath := scanner.Text() | ||
options.AlternatesFS = osfs.New(altPath) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If altPath
is relative to the host root dir, you probably want:
options.AlternatesFS = osfs.New("/")
I think this might work as well:
options.AlternatesFS = osfs.New(altPath, osfs.WithBoundOS())
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! Changed in 4f26e65, but it seems I'm still not lucky.
Does this work in Windows?
options.AlternatesFS = osfs.New("/")
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My understanding is that osfs.New("")
and osfs.New("/")
are equivalent. But looking across go-git
, we seem to only use the former - for example on the default loader.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FYI: osfs.New("")
is not the same as osfs.New("/")
And I think there are some other problems in go-git: go-git/go-git#1006
replaced by #28893 |
Upgrade github.com/go-git/go-git/v5 from v5.9.0 -> v5.11.0