Get the latest tech news

How I configure my Git identities


This may be overkill, but it works on my machine

A few years ago I learned about includeIf for including specific files if some condition was met for git. This makes it so that I can configure git conditionally if the given remote URL exists for that directory I'm currently working in. While that handles git identities, I still need to configure SSH keys separately to be able to pull and push to remotes.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of Git

Git

Photo of Git identities

Git identities

Related news:

News photo

Show HN: Fireproof – local-first database with Git-like encrypted sync

News photo

Git and Jujutsu: In Miniature

News photo

Mergiraf: a syntax-aware merge driver for Git