summaryrefslogtreecommitdiff
path: root/manpages/bin/update-version.sh
diff options
context:
space:
mode:
Diffstat (limited to 'manpages/bin/update-version.sh')
-rwxr-xr-xmanpages/bin/update-version.sh36
1 files changed, 35 insertions, 1 deletions
diff --git a/manpages/bin/update-version.sh b/manpages/bin/update-version.sh
index d01949b1a..4b0820e20 100755
--- a/manpages/bin/update-version.sh
+++ b/manpages/bin/update-version.sh
@@ -1,11 +1,24 @@
#!/bin/sh
+## live-build(7) - System Build Scripts
+## Copyright (C) 2006-2012 Daniel Baumann <daniel@debian.org>
+##
+## live-build comes with ABSOLUTELY NO WARRANTY; for details see COPYING.
+## This is free software, and you are welcome to redistribute it
+## under certain conditions; see COPYING for details.
+
+
set -e
-DATE="$(LC_ALL=C date +%Y\\\\-%m\\\\-%d)"
PROGRAM="LIVE\\\-BUILD"
VERSION="$(cat ../VERSION)"
+DATE="$(LC_ALL=C date +%Y\\\\-%m\\\\-%d)"
+
+DAY="$(LC_ALL=C date +%d)"
+MONTH="$(LC_ALL=C date +%m)"
+YEAR="$(LC_ALL=C date +%Y)"
+
echo "Updating version headers..."
for MANPAGE in en/*
@@ -14,3 +27,24 @@ do
sed -i -e "s|^.TH.*$|.TH ${PROGRAM} ${SECTION} ${DATE} ${VERSION} \"Debian Live Project\"|" ${MANPAGE}
done
+
+# European date format
+for _LANGUAGE in de es fr it
+do
+ if ls po/${_LANGUAGE}/*.po > /dev/null 2>&1
+ then
+ for _FILE in po/${_LANGUAGE}/*.po
+ do
+ sed -i -e "s|^msgstr .*.2012\"$|msgstr \"${DAY}.${MONTH}.${YEAR}\"|g" "${_FILE}"
+ done
+ fi
+done
+
+# Brazilian date format
+if ls po/pt_BR/*.po > /dev/null 2>&1
+then
+ for _FILE in po/pt_BR/*.po
+ do
+ sed -i -e "s|^msgstr .*-2012\"$|msgstr \"${DAY}-${MONTH}-${YEAR}\"|g" "${_FILE}"
+ done
+fi