9
0
Fork 0
This repository has been archived on 2022-06-17. You can view files and clone it, but cannot push or open issues or pull requests.
openggsn/version

25 lines
466 B
Bash
Executable File

#!/bin/sh
#
# Little shell script to grab current version number from configure.in
#
# $Id: version,v 1.1.1.1 2002/12/16 13:33:52 jjako Exp $
VER=`grep AM_INIT_AUTOMAKE configure.in | awk -F'[(),]' '{print $3}'`
if [ "$1" == "-VERSION" ]
then
echo $VER | awk -F'.' '{print $1}'
exit
fi
if [ "$1" == "-PATCHLEVEL" ]
then
echo $VER | awk -F'.' '{print $2}'
exit
fi
if [ "$1" == "-SUBLEVEL" ]
then
echo $VER | awk -F'.' '{print $3}'
exit
fi
echo $VER
exit