#!/bin/sh
if test "$1" = "-d"; then
  if test -d .git; then
    git log HEAD^..HEAD --format=%cd --date=short
  else
    date -r VERSION +%F
  fi
else
  if test -d .git; then
    s=`git describe --match "dosemu-[0-9]*" HEAD | sed -e 's/^dosemu-//'`
  else
    s=`cat VERSION`
  fi
  echo $s
fi
