When I do this:
cd /home/erelsgl/git/erel-sites; git commit -m "test"
I get correctly:
On branch master Your branch is up-to-date with 'origin/master'. nothing to commit, working directory clean
But, when I put the same line in the crontab of my account, I see in the logfile:
*** Please tell me who you are. Run git config --global user.email "firstname.lastname@example.org" git config --global user.name "Your Name" to set your account's default identity. Omit --global to set the identity only in this repository. fatal: unable to auto-detect email address (got 'erelsgl@erelsgl-computer')
I put "whoami" in the crontab and got the same answer as outside ("erelsgl").
I also tried to put the recommended "git config --global" commands inside the crontab (I already ran them successfully outside the crontab) but this did not help.
What should I do to commit from crontab?