Commit eaf04fb7 authored by bgm's avatar bgm
Browse files

commit-to-git.sh: use awk instead of gawk (good enough in most places), and minor code cleanup.

parent 90b51892
......@@ -38,14 +38,11 @@
# GNU General Public License for more details.
#
# PO_NEW=$(git ls-files -o | gawk '/po\/[[:alpha:]_\-]*\.po/ { sub("po/", ""); print $0; }' | sort)
# PO_MOD=$(git ls-files -m | gawk '/po\/[[:alpha:]_\-]*\.po/ { sub("po/", ""); print $0; }' | sort)
PO_NEW=$(git ls-files -o | grep -v '\.mo' | sort)
PO_MOD=$(git ls-files -m | grep -v '\.mo' | sort)
function get_author {
echo $(gawk 'BEGIN { FS=": " } /Last-Translator/ { sub("\\\\n\"", ""); print $2 }' "$1")
echo $(awk 'BEGIN { FS=": " } /Last-Translator/ { sub("\\\\n\"", ""); print $2 }' "$1")
}
function do_commit {
......@@ -64,4 +61,3 @@ for f in $PO_NEW; do
git add "$f"
do_commit "$f" "po: add $f (pulled from Transifex.net by CiviCRM l10n maintainer)"
done
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment