Chameleon

Chameleon Svn Source Tree

Root/branches/blackosx/package/Scripts/Install/InstallLog.sh

  • Property svn:executable set to *
1#!/bin/bash
2
3echo "==============================================="
4echo "InstallLog: Create/Append installation log"
5echo "**********************************************"
6
7# Creates text file named 'Chameleon_Installer_Fail_Log.txt'
8# at the root of the target volume. This is to help show the
9# user why the installation process failed (even though the
10# package installer ends reading 'Installation Successful'.
11
12# Receives two parameters
13# $1 = selected volume for location of the install log
14# $2 = text to write to the installer log
15
16if [ "$#" -eq 2 ]; then
17logLocation="$1"
18verboseText="$2"
19#echo "DEBUG: passed argument = $logLocation"
20#echo "DEBUG: passed argument = $verboseText"
21else
22echo "Error - wrong number of values passed"
23exit 9
24fi
25
26
27logfile="${logLocation}"/Chameleon_Installer_Fail_Log.txt
28
29if [ -f "${logfile}" ]; then
30echo "${verboseText}" >> "${logLocation}"/Chameleon_Installer_Fail_Log.txt
31else
32echo "${verboseText}" > "${logLocation}"/Chameleon_Installer_Fail_Log.txt
33fi
34
35exit 0

Archive Download this file

Revision: 1543