view version.sh @ 18624:06c236dd604b

avoid usage of head -1/head -n 1 and use sed 1q instead
author ivo
date Wed, 07 Jun 2006 15:03:25 +0000
parents c55903d85291
children 04ed79acda15
line wrap: on
line source

#!/bin/sh

revision=r`grep committed-rev .svn/entries | sed 1q | cut -d '"' -f 2 2>/dev/null`

extra=""
if test "$1" ; then
  extra="-$1"
fi

echo "#define VERSION \"dev-SVN-${revision}${extra}\"" > version.h