Last active
December 6, 2024 17:48
-
-
Save eggplants/25dfaa4a6d8198944e2a45984fe9e618 to your computer and use it in GitHub Desktop.
Force git client to select ssh protocol instead of http protocol to connect to Codeberg
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
cb_prefix="[email protected]:" | |
git config --global --remove-section "$gb_prefix" || : | |
git config --global "$cb_prefix".pushInsteadOf "git://codeberg.org/" | |
git config --global --add "$cb_prefix".pushInsteadOf "https://codeberg.org/" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment