Page MenuHomePhabricator

No OneTemporary

Size
1 KB
Referenced Files
None
Subscribers
None
diff --git a/trunk/compileinfo.sh b/trunk/compileinfo.sh
index d63ec14..54e37f5 100755
--- a/trunk/compileinfo.sh
+++ b/trunk/compileinfo.sh
@@ -1,39 +1,45 @@
#!/bin/bash
+PWD=""
+if [ $# -eq 1 ]; then
+ PWD="$1"
+ PWD="${PWD%/}/"
+fi
+
echo '// Automatically generated file. See project file and compileinfo.sh for further informations.'
#head -n 1 debian/changelog | awk '{
# Version = $2
# gsub ("\\(", "", Version)
# gsub ("\\)", "", Version)
# print "const char *pCompileInfoVersion = \"" Version "\";"}'
echo '#define APP_NAME "fred"'
echo '#define APP_TITLE "Forensic Registry EDitor (fred)"'
echo '#define APP_COPYRIGHT "Copyright (c) 2011 by Gillen Daniel"'
echo '#define APP_DEVELOPPER_EMAIL "gillen.dan@pinguin.lu"'
echo '#define APP_DESCRIPTION "Forensic Registry EDitor (fred) is a cross-platform M$ registry hive editor with special feautures useful during forensic analysis."'
date '+#define APP_COMPILETIME "%Y/%m/%d %H:%M:%S"'
GOT_VERSION=0
-if [[ $GOT_VERSION -eq 0 && -f debian/changelog ]]; then
+if [[ $GOT_VERSION -eq 0 && -f "$PWD"debian/changelog ]]; then
# Get version and release timestamp from debian/changelog file
CUR_LINE=0
while read LINE; do
CUR_LINE=$(($CUR_LINE+1))
if [ $CUR_LINE -eq 1 ]; then
# first line contains version
echo "$LINE" | awk '{ Version = $2
gsub ("\\(", "", Version)
gsub ("\\)", "", Version)
print "#define APP_VERSION \"" Version "\"" }'
break
fi
- done <debian/changelog
+ done <"$PWD"debian/changelog
GOT_VERSION=1
fi
if [ $GOT_VERSION -eq 0 ]; then
echo '#define APP_VERSION "0.0.0alpha0"'
fi

File Metadata

Mime Type
text/x-diff
Expires
Sun, May 11, 2:43 AM (1 d, 4 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
1247593
Default Alt Text
(1 KB)

Event Timeline