summaryrefslogtreecommitdiff
path: root/net-p2p/linux-agsatellite/files/wrapper.sh
diff options
context:
space:
mode:
authorMario Sergio Fujikawa Ferreira <lioux@FreeBSD.org>2001-09-07 14:34:21 +0000
committerMario Sergio Fujikawa Ferreira <lioux@FreeBSD.org>2001-09-07 14:34:21 +0000
commit59393b6e61564d8228d7c16c7743931ab110d3bb (patch)
tree258a7e73247c0affe99d580b988028fa22a8da03 /net-p2p/linux-agsatellite/files/wrapper.sh
parentUpdate to 0.93. (diff)
New port agsatellite version 0.520: Client that allows you to share
your music on Audiogalaxy(TM)
Notes
Notes: svn path=/head/; revision=47497
Diffstat (limited to 'net-p2p/linux-agsatellite/files/wrapper.sh')
-rw-r--r--net-p2p/linux-agsatellite/files/wrapper.sh26
1 files changed, 26 insertions, 0 deletions
diff --git a/net-p2p/linux-agsatellite/files/wrapper.sh b/net-p2p/linux-agsatellite/files/wrapper.sh
new file mode 100644
index 000000000000..fb7fdbd6f492
--- /dev/null
+++ b/net-p2p/linux-agsatellite/files/wrapper.sh
@@ -0,0 +1,26 @@
+#!/bin/sh
+
+PREFIX="%%PREFIX%%"
+PROGRAM="${0}"
+
+if [ ${#} -gt 1 ]
+then
+ shift
+fi
+
+if [ ! -d ${HOME}/.agsatellite ]
+then
+ mkdir -p ${HOME}/.agsatellite
+fi
+
+if [ ! -h ${HOME}/.agsatellite/${PROGRAM##*/} ]
+then
+ ln -sf ${PREFIX}/bin/${PROGRAM##*/}-real ${HOME}/.agsatellite/${PROGRAM##*/}
+fi
+
+echo " ${*} " | grep " \-createdironly " ||
+ cd ${HOME}/.agsatellite &&
+ echo Running Audio Galaxy Satellite under ${HOME}/.agsatellite &&
+ echo Create both account.txt and shares.txt files under ${HOME}/.agsatellite &&
+ exec ./${PROGRAM##*/} ${*} ||
+ echo PROBLEM. Cannot create directory ${HOME}/.agsatellite, make sure you have the proper permissions to create itnd try again