Skip to content
Discussion options

You must be logged in to vote

@mcepl it's explained in the intro on the README: the $HOME variable is set to a temporary directory. Git expects the configuration in ~/.gitconfig, so you can create that file with a barebones config.

But what I do in my git tests is include a test-lib.sh file that contains the following:

[email protected]
GIT_AUTHOR_NAME='A U Thor'
[email protected]
GIT_COMMITTER_NAME='C O Mitter'
export GIT_AUTHOR_EMAIL GIT_AUTHOR_NAME
export GIT_COMMITTER_EMAIL GIT_COMMITTER_NAME

This is similar to what git.git does. That way there's no need to create a config file and git doesn't complain about not having an identity.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by felipec
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants