From 231ee84ab9c4f3447c4190c4bbe9fa8a255276e6 Mon Sep 17 00:00:00 2001 From: Pierre Kancir Date: Fri, 6 Aug 2021 15:45:39 +0200 Subject: [PATCH] Tools: correct author name formatting MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit prevent error fatal: --author 'pierre.kancir.emn@gmail.com' n'est pas de la forme 'Nom ' ni ne correspond à aucun auteur existant --- Tools/gittools/git-subsystems-split | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Tools/gittools/git-subsystems-split b/Tools/gittools/git-subsystems-split index e1c9a45bb9..1810aea893 100755 --- a/Tools/gittools/git-subsystems-split +++ b/Tools/gittools/git-subsystems-split @@ -56,7 +56,9 @@ if $option_copy && $option_edit; then exit 1 fi -author=$(git log -n 1 --format=%ae) +author_name=$(git log -n 1 --format=%an) +author_email=$(git log -n 1 --format=%ae) +author="$author_name <$author_email>" git log -n 1 --format=%B > "$MSG_FILE" if $option_edit; then @@ -86,7 +88,7 @@ fi HEAD=$(git rev-parse HEAD) git reset HEAD~1 --soft -if ! "$SCRIPT_DIR/git-commit-subsystems" -F "$MSG_FILE" --author=$author; then +if ! "$SCRIPT_DIR/git-commit-subsystems" -F "$MSG_FILE" --author="$author"; then echo "Error on calling git-commit-subsystems." >&2 git reset $HEAD exit 1