From 62ca4bb577abb4534dbf57cba5532a421b79b2bc Mon Sep 17 00:00:00 2001 From: James Turner Date: Fri, 30 Oct 2020 12:00:38 +0000 Subject: [PATCH] Helper script to reset author --- release_builder/reset-git-author.sh | 34 +++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100755 release_builder/reset-git-author.sh diff --git a/release_builder/reset-git-author.sh b/release_builder/reset-git-author.sh new file mode 100755 index 0000000..435383c --- /dev/null +++ b/release_builder/reset-git-author.sh @@ -0,0 +1,34 @@ +#!/bin/bash +#This file is part of FlightGear +# +#FlightGear is free software: you can redistribute it and/or modify +#it under the terms of the GNU General Public License as published by +#the Free Software Foundation, either version 2 of the License, or +#(at your option) any later version. +# +#FlightGear is distributed in the hope that it will be useful, +#but WITHOUT ANY WARRANTY; without even the implied warranty of +#MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +#GNU General Public License for more details. +# +#You should have received a copy of the GNU General Public License +#along with FlightGear If not, see . + +if [ -z "$1" -o -z "$2" ]; then + echo "usage: author email" + exit +fi + +resetAuthor() { + pushd $3 > /dev/null + git config user.name "$1" + git config user.email $2 + popd > /dev/null +} + +resetAuthor "$1" $2 flightgear +resetAuthor "$1" $2 simgear +resetAuthor "$1" $2 fgdata +resetAuthor "$1" $2 getstart +resetAuthor "$1" $2 . +