سؤال

Trying to set up some aliases for git config, i know i can do it through terminal but I would like to setup a git config file as given here. http://gitimmersion.com/lab_11.html. But I dont understand exactly what i need to do, i have tried saving that exact text in a file ".gitconfig" through sublime 2 but it does not work. Where exactly is the home directory of git? I have used "which git" in terminal to get the path "/usr/local/git/bin/git". Placing the file in /usr/local/git/bin does nothing, ive tried several other directories to no avail.

هل كانت مفيدة؟

المحلول

That post makes it clear:

Add the following to the .gitconfig file in your $HOME directory.

That means $HOME/.gitconfig (e.g. /home/felipec/.gitconfig).

But precisely for this reason is why the --edit option was added:

git config --global --edit

Now you don't have to know or care where is the file, just edit it.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top