* src/scribo-cli.in: Move the shebang to the first line.
(version): Do not hard-code the version number
in scribo-cli.
Rephrase the copyright owner for uniformity reasons.
* src/Makefile.am (do_subst): Also substitute PACKAGE_VERSION.
---
scribo/ChangeLog | 10 ++++++++++
scribo/src/Makefile.am | 3 ++-
scribo/src/scribo-cli.in | 11 ++++++-----
3 files changed, 18 insertions(+), 6 deletions(-)
diff --git a/scribo/ChangeLog b/scribo/ChangeLog
index 2fa24c1..419cc9a 100644
--- a/scribo/ChangeLog
+++ b/scribo/ChangeLog
@@ -1,3 +1,13 @@
+2014-03-31 Roland Levillain <roland(a)lrde.epita.fr>
+
+ Scribo: Improve scribo-cli's `--version' option.
+
+ * src/scribo-cli.in: Move the shebang to the first line.
+ (version): Do not hard-code the version number
+ in scribo-cli.
+ Rephrase the copyright owner for uniformity reasons.
+ * src/Makefile.am (do_subst): Also substitute PACKAGE_VERSION.
+
2013-09-13 Roland Levillain <roland(a)lrde.epita.fr>
Scribo: Define flags in proper Makefile helpers.
diff --git a/scribo/src/Makefile.am b/scribo/src/Makefile.am
index 827771c..47d9960 100644
--- a/scribo/src/Makefile.am
+++ b/scribo/src/Makefile.am
@@ -155,7 +155,8 @@ endif HAVE_MAGICKXX
# Generated by configure from scribo-cli.in.
dist_bin_SCRIPTS = scribo-cli
-do_subst = sed -e 's|@utilexecdir[@]|$(utilexecdir)|g'
+do_subst = sed -e 's|@utilexecdir[@]|$(utilexecdir)|g' \
+ -e 's|@PACKAGE_VERSION[@]|$(PACKAGE_VERSION)|g'
scribo-cli: $(srcdir)/scribo-cli.in Makefile
rm -f $@ $@.tmp
diff --git a/scribo/src/scribo-cli.in b/scribo/src/scribo-cli.in
index 7cc4864..6cfc9d0 100755
--- a/scribo/src/scribo-cli.in
+++ b/scribo/src/scribo-cli.in
@@ -1,4 +1,6 @@
-# Copyright (C) 2010 EPITA Research and Development Laboratory (LRDE).
+#! /bin/sh
+
+# Copyright (C) 2010, 2014 EPITA Research and Development Laboratory (LRDE).
#
# This file is part of Olena.
#
@@ -13,17 +15,16 @@
#
# You should have received a copy of the GNU General Public License
# along with Olena. If not, see <http://www.gnu.org/licenses/>.
-#
-#!/bin/sh
bdir="@utilexecdir@"
bin=`basename $0`
+version="@PACKAGE_VERSION@"
version()
{
cat <<EOF
-SCRIBO Command LIne tool, version 1.0
-Copyright (C) 2010 LRDE/EPITA
+Olena Scribo Module Command-Line Interface (CLI) tool, version $version
+Copyright (C) 2010, 2014 EPITA Research and Development Laboratory (LRDE)
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
EOF
--
1.7.10.4
Show replies by date