New answers tagged


Anoter useful option is the git-identity package. From its README: This Emacs package lets you manage local Git identities, i.e. and options in .git/config, inside Emacs. It can be useful if you satisfy all of the following conditions: - You have multiple Git identities on the same machine(s). - You use Emacs. - You (almost ...


you can do this with one-time git configuration. you can use it for email and so on, but also for using a different ssh key: in ~/.gitconfig: [includeIf "gitdir:~/work/"] path = .gitconfig_work in ~/.gitconfig_work: [user] email = … [core] sshCommand = ssh -i ~/.ssh/id_…_work -o 'IdentitiesOnly yes' explanation: this makes git use another configuration,...


C-x v v will take you to commit. Write the commit, save the commit and the file will be added automatically.


To merge only a particular file I can [use git checkout] from command line: This does not perform a merge. This does not only apply the changes from the other branch, it also discards changes that have been made on your branch since the other branch diverged. I want to merge only specific changes from the log Show the diff appropriate changes. For each ...


Use x or X s to do so. Using the X prefix has the benefit that it shows you all the available git reset variants. This is also documented in the Resetting section of the manual.

Top 50 recent answers are included