If I understand well, git plugin exposes committer and author names and emails to environmental variables GIT_AUTHOR_NAME, GIT_COMMITTER_NAME,
GIT_AUTHOR_NAME
GIT_COMMITTER_NAME
You can try for below command, it worked for me:
git log -n 1 --pretty=format:'%ae'