OblikStudio / kirby-git

Kirby plugin for updating content in the panel via Git
MIT License
84 stars 6 forks source link

Kirby user with no name -> commit author #32

Open movingwater opened 1 year ago

movingwater commented 1 year ago

Hi, just realised if no name is definied for a kirby user the commit's author is "oblikweare". I would prefer to just use the email addresse. Or is there a way to define the other?

JonasLeonhard commented 1 year ago

Hey @movingwater, i just had the same problem and fixed it by changing the commit function in site/plugins/git/lib/Git.php . There you can ajust the $name and $email to your preferences. Hope that helps you.

hdodov commented 1 year ago

@movingwater @JonasLeonhard you should be able to change the author name and email by running the following commands on the production server:

git config --global user.name "John Doe"
git config --global user.email "john@example.com"

It's better to do it this way, because commits made outside the plugin (e.g. manually from SSH) will also have a proper author.