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
{{ message }}
This repository was archived by the owner on Aug 11, 2022. It is now read-only.
Git has a simple way to do this in the config file.
[url "https://"]
insteadOf = git://
However npm seems to throw out the environment in lib/cache.js
var gitEnv_
function gitEnv () {
// git responds to env vars in some weird ways in post-receive hooks
// so don't carry those along.
if (gitEnv_) return gitEnv_
gitEnv_ = {}
for (var k in process.env) {
if (!~['GIT_PROXY_COMMAND','GIT_SSH','GIT_SSL_NO_VERIFY'].indexOf(k) && k.match(/^GIT/)) continue
gitEnv_[k] = process.env[k]
}
return gitEnv_
}
So I can't inject a GIT_CONFIG or anything.
I've hand-hacked it into the addRemoteGit function in lib/cache.js with
u = u.replace(/^git:/, "https:")
but this variable should be pulled from a config somewhere
Git has a simple way to do this in the config file.
However npm seems to throw out the environment in lib/cache.js
So I can't inject a GIT_CONFIG or anything.
I've hand-hacked it into the
addRemoteGitfunction inlib/cache.jswithbut this variable should be pulled from a config somewhere