lib/scripts/fileident
author wenzelm
Sat, 10 Jan 2009 13:10:07 +0100
changeset 29427 7ba952481e29
parent 29145 b1c6f4563df7
permissions -rwxr-xr-x
excursion: commit_exit internally -- checkpoints are fully persistent now; excursion: do not force intermediate result states yet -- great performance improvement;

#!/usr/bin/env bash
#
# fileident --- produce file identification based

FILE="$1"

if [ -n "$ISABELLE_FILE_IDENT" -a -f "$FILE" -a -r "$FILE" ]
then
  ID=$(cat "$FILE" | $ISABELLE_FILE_IDENT | cut -d " " -f 1) && echo -n "$ID"
fi