summaryrefslogtreecommitdiffstats
path: root/scripts/_https._tcp.sh
diff options
context:
space:
mode:
authorSebastien Estienne <sebastien.estienne@gmail.com>2005-09-06 17:41:26 +0000
committerSebastien Estienne <sebastien.estienne@gmail.com>2005-09-06 17:41:26 +0000
commitafda8873baf0ae1f7c90f8e8fea0c4dcaa836aeb (patch)
tree81d09ae6a048da3fbee1f8d417b8e3eba14781cb /scripts/_https._tcp.sh
parent619297646188564dbf2cf7925bd5cee4e946773d (diff)
* fix scripts
* don't prepend / if path already contains one * fix a bug that prevents executing scripts git-svn-id: file:///home/lennart/svn/public/service-discovery-applet/trunk@10 3be567f1-68ff-0310-b24a-ad7cc433fd2f
Diffstat (limited to 'scripts/_https._tcp.sh')
-rwxr-xr-xscripts/_https._tcp.sh21
1 files changed, 21 insertions, 0 deletions
diff --git a/scripts/_https._tcp.sh b/scripts/_https._tcp.sh
new file mode 100755
index 0000000..d196ea6
--- /dev/null
+++ b/scripts/_https._tcp.sh
@@ -0,0 +1,21 @@
+#!/bin/sh
+TYPE=`basename $0`
+NAME=$1
+HOSTNAME=$2
+ADDRESS=$3
+PORT=$4
+TXTS=$5
+
+for TXT in $TXTS
+do
+ eval TXT_$TXT
+done
+
+HANDLER=`echo $TYPE | cut -f 1 -d "." | cut -f 2 -d "_"`
+
+if [ ! -z "$TXT_path" ]
+then
+ path=`echo $TXT_path | sed -e 's/^\///g'`
+fi
+
+gnome-open "$HANDLER://$ADDRESS:$PORT/$path"