[Libguestfs] [PATCH] podwrapper.sh: Take date from ChangeLog or from the latest git commit.
Richard W.M. Jones
rjones at redhat.com
Tue Jul 10 08:25:48 UTC 2012
On Tue, Jul 10, 2012 at 10:15:57AM +0200, Hilko Bengen wrote:
> ---
> podwrapper.sh.in | 8 ++++++++
> 1 file changed, 8 insertions(+)
>
> diff --git a/podwrapper.sh.in b/podwrapper.sh.in
> index ec750f1..9198f63 100755
> --- a/podwrapper.sh.in
> +++ b/podwrapper.sh.in
> @@ -53,6 +53,13 @@ if [ -z "$abs_top_builddir" ]; then
> exit 1
> fi
>
> +if [ -e $abs_top_srcdir/ChangeLog ]; then
> + DATEPARAM=`awk '/^[0-9]+-[0-9]+-[0-9]+/ { print "--date=" $1; exit }' \
> + $abs_top_srcdir/ChangeLog`
> +else if [ -d $abs_top_srcdir/.git ]; then
> + DATEPARAM=`git show -s --format=%ci | awk '{print "--date=" $1}'`
> +else
> +
> declare -a inserts
> declare -a pattern
> declare -a indent
> @@ -167,6 +174,7 @@ fi
> # Now generate the final output format(s).
> if [ -n "$man_output" ]; then
> "$POD2MAN" "$POD2_STDERR_OPTION" "$POD2_UTF8_OPTION" \
> + $DATEPARAM \
> --section "$section" -c "Virtualization Support" --name "$name" \
> --release "$PACKAGE_NAME-$PACKAGE_VERSION" \
> < $tmpdir/full.pod > "$man_output".tmp
> --
> 1.7.10.4
ACK, please push this.
Rich.
--
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming blog: http://rwmj.wordpress.com
Fedora now supports 80 OCaml packages (the OPEN alternative to F#)
http://cocan.org/getting_started_with_ocaml_on_red_hat_and_fedora
More information about the Libguestfs
mailing list