-
Notifications
You must be signed in to change notification settings - Fork 6
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
fix: ensure insteadOf gets picked up for submodules #200
base: master
Are you sure you want to change the base?
Conversation
Hi! I'm a bit confused by this @jhosteny:
I thought the current configuration for On that subject, shouldn't Have you tried doing something similar to the comment below this Stackoverflow response? i.e. |
I'm sorry, that wasn't very clear of me. I mean that our default configuration of the subrepo should use
Yes, you are correct - we use
Hmm - I thought I pretty exhaustively tried all other options, but I don't recall now if I tried this. I will check, and amend the PR if this works.
|
@itsdalmo actually, I recall now why the |
@itsdalmo the method you referenced appears to be working properly (though it is a bit more complicated). I am going to soak this in our environment for awhile with a local version of the resource. Is it possible that the subrepo in your e2e test can be made private to ensure this works correctly? |
Great to hear @jhosteny!
Would that not make it hard for others to run the E2E tests? 🤔
Roger that, let me know when you feel ready for a review! |
Yeah - I'm not sure how to handle this case. Is it worth having an extra tagged case that is not run normally, but can run against a private repo? Or just skip it? I suppose if the git config were wrong, git operations would fail on submodules, so there is value as-is. |
@itsdalmo this has been running successfully for us over the last month or so, if you would like to review. I am not sure how to add tests unless there is tagged set that only get run manually against private sub repos. |
@jhosteny I'll have look this week, thank you for contribution, I'll investigate making selective test-case for E2E targeting a private repo, which can be optionally overridden locally. |
a5e0310
to
573e2ba
Compare
Note that the latest change also fixes the issue observed in #234 |
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.
This certainly looks like it would fix the issue I had, but I've not had a chance to test it yet I'm afraid.
Update: I've tested this, and it does fix the issue I had.
I got the same issue being unable to fetch a repository with submodules (I got an authentication error), I tried this pr and it fixes my issue too. |
yes, please! 😄 |
Is there any chance we can get this merged? |
Is this still going in at some point? |
@itsdalmo gentle ping on this! |
Hi @itsdalmo. I know you just changed this for the
e2e
test, but I'm opening it back up for feedback.We have some private repos that must use git instead of https. Unless the
git config
is applied globally, I have found that I am unable to get theinsteadOf
directive to work on the submodules. I've tried a number of variations on it, including settingGIT_CONFIG
and supplying a file identical to the global config. Unfortunately, that doesn't supplement the.git/config
, but rather simply overrides it.I'm wondering if you or anyone else may have suggestions on how to fix? Do the e2e tests break, or does it just leave your local test environment in a bad state?