Skip to content

Instantly share code, notes, and snippets.

View bgauduch's full-sized avatar
💻

Baptiste Gauduchon bgauduch

💻
View GitHub Profile
@bgauduch
bgauduch / dagger.cue
Created September 1, 2022 15:41
dagger test with Terraform
package terraform
import (
"dagger.io/dagger"
"dagger.io/dagger/core"
"universe.dagger.io/alpha/terraform"
)
dagger.#Plan & {
client: {
@bgauduch
bgauduch / multiple-repository-and-identities-git-configuration.md
Last active November 13, 2024 03:35
Git config with multiple identities and multiple repositories

Setup multiple git identities & git user informations

/!\ Be very carrefull in your setup : any misconfiguration make all the git config to fail silently ! Go trought this guide step by step and it should be fine 😉

Setup multiple git ssh identities for git

  • Generate your SSH keys as per your git provider documentation.
  • Add each public SSH keys to your git providers acounts.
  • In your ~/.ssh/config, set each ssh key for each repository as in this exemple:
git config --global alias.lg1 'log --graph --abbrev-commit --decorate --format=format:"%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)" --all'
git config --global alias.lg2 'log --graph --abbrev-commit --decorate --format=format:"%C(bold blue)%h%C(reset) - %C(bold cyan)%aD%C(reset) %C(bold green)(%ar)%C(reset)%C(bold yellow)%d%C(reset)%n'' %C(white)%s%C(reset) %C(dim white)- %an%C(reset)" --all'