Outils pour utilisateurs

Outils du site


git

Ceci est une ancienne révision du document !


Git

Commandes utiles

$ git remote -v
origin  n3i@gitlab.paris.exalead.com:consulting/customers/edf/edf-hpc.git (fetch)
origin  n3i@gitlab.paris.exalead.com:consulting/customers/edf/edf-hpc.git (push)

Clone/Push avec erreur de ‘self signed certificate’

La commande de clone peut être la suivante :

git clone https://gitlab.paris.exalead.com/consulting/customers/bmw_plm.git

Mais, on peut avoir le message suivant :

fatal: unable to access 'https://gitlab.paris.exalead.com/consulting/customers/bmw_plm.git/': SSL
certificate problem: self signed certificate in certificate chain

Pour y remédier, il faut utiliser le paramètre -c http.sslVerify=false

git config http.sslVerify false

Modification du mat de passe Git sous Windows

  1. Ouvrir 'Control Panel\User Accounts\Credential Manager'
  2. Choisir 'Windows Credentials'
  3. Dans la section 'Generic Credentials', modifier les mots de passe des utilisateurs 'git'

Pour plus d'infos

Utilisation de SSH-Agent pour rentrer le mot de passe une seule fois

Dans ~/.profile, mettre

env=~/.ssh/agent.env

agent_load_env () { test -f "$env" && . "$env" >| /dev/null ; }

agent_start () {
    (umask 077; ssh-agent >| "$env")
    . "$env" >| /dev/null ; }

agent_load_env

# agent_run_state: 0=agent running w/ key; 1=agent w/o key; 2= agent not running
agent_run_state=$(ssh-add -l >| /dev/null 2>&1; echo $?)

if [ ! "$SSH_AUTH_SOCK" ] || [ $agent_run_state = 2 ]; then
    agent_start
    ssh-add
elif [ "$SSH_AUTH_SOCK" ] && [ $agent_run_state = 1 ]; then
    ssh-add
fi

unset env

Au premier démarrage de la journée, le système demande ma paraphrase.

Pour tester

ssh -T git@gitlab.paris.exalead.com

Working with SSH key passphrases

git.1592407716.txt.gz · Dernière modification : (modification externe)

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki