Les billets libellés: git. Afficher tous les billets.

Create New Git Repo From Shallow Clone

mercredi 27 janvier 2021

How to create a new git repo from a shallow clone to not keep the history.

git clone [old repo] --depth 1

git remote add new_source [new repo]

git remote remove origin

git rev-parse --verify master >> .git/info/grafts

git filter-branch -- --all git push new_source master

Libellés: git
Aucun commentaire

Git Through Proxy Server

lundi 11 mai 2020

As of a few days ago they must have changed something in the corporate proxy server at work because all of a sudden no one could push or pull to git remotes. I was getting error "fatal: unable to access [proxy server address]: Timed out"

After much frustration, it turns out there was a fairly simple solution. I had http_proxy and https_proxy environment variables set to the proxy server. If I set an environment variable "no_proxy" with the values of the domains I need to connect to with git everything works fine.

Libellés: git
6 commentaires

Archives du Blogue