Skip to content

Instantly share code, notes, and snippets.

Last active March 8, 2023 14:35
What would you like to do?
git global url insteadOf setup
# one or the other, NOT both
[url "https://github"]
insteadOf = git://github
# or
[url ""]
insteadOf = git://github

Replace git:// with https://

Rewrite any git:// urls to be https:// but, it won't touch sshurls (

git config --global url."https://github".insteadOf git://github

or replace with ssh

Use ssh instead of https://

git config --global url."".insteadOf ""

sauce: & @hansdg1

Copy link


Copy link

Exactly what i was looking for thanks 👍

Copy link

tecnocat commented Jan 9, 2023

It is possible to remove entries with credentials from command line scripts?

[url ""]
        insteadOf =

I tried git config --global --unset name <pattern> with no luck :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment