File: version.sh

package info (click to toggle)
libraw 0.21.4-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 3,496 kB
  • sloc: cpp: 53,067; ansic: 2,430; makefile: 133; sh: 82; perl: 58
file content (16 lines) | stat: -rwxr-xr-x 468 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#!/bin/sh

vfile=./libraw/libraw_version.h

major=`grep LIBRAW_MAJOR_VERSION $vfile |head -1 | awk '{print $3}'`
minor=`grep LIBRAW_MINOR_VERSION $vfile | head -1 | awk '{print $3}'`
patch=`grep LIBRAW_PATCH_VERSION $vfile | head -1 | awk '{print $3}'`
tail=`grep LIBRAW_VERSION_TAIL $vfile | head -1 | awk '{print $3}'`

if [ x$tail = xRelease ] ; then
 echo "$major.$minor.$patch" | awk '{printf $1}'
else
 echo "$major.$minor.$patch-$tail" | awk '{printf $1}'
fi