summaryrefslogtreecommitdiffstats
path: root/modules/retiolum/scripts/tinc_setup/write_channel.py
diff options
context:
space:
mode:
authorFelix Richter <Felix.Richter@syntax-fehler.de>2011-05-27 15:36:20 +0200
committerFelix Richter <Felix.Richter@syntax-fehler.de>2011-05-27 15:44:43 +0200
commit402a70a9c1df350cf6911ec5b1372d7c1efdc6b4 (patch)
treedc4a28484e973190839c5ad58a9b5bbda4059c92 /modules/retiolum/scripts/tinc_setup/write_channel.py
parent58695662f2d4bebe53b2b3dd9974bac44b4b9ead (diff)
parent77355d28e804ace544f78674866f894bf96a7f89 (diff)
fixed penisland
Diffstat (limited to 'modules/retiolum/scripts/tinc_setup/write_channel.py')
-rw-r--r--modules/retiolum/scripts/tinc_setup/write_channel.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/modules/retiolum/scripts/tinc_setup/write_channel.py b/modules/retiolum/scripts/tinc_setup/write_channel.py
index 71866a8d..a11d4605 100644
--- a/modules/retiolum/scripts/tinc_setup/write_channel.py
+++ b/modules/retiolum/scripts/tinc_setup/write_channel.py
@@ -1,11 +1,16 @@
#!/usr/bin/python
import random, sys, time, socket
+try:
+ myname=sys.argv[1]
+except:
+ print "you are made of stupid"
+ exit (23)
CHANNEL = '#tincspasm'
HOST='irc.freenode.net'
-FILE="/etc/tinc/retiolum/hosts/$myname"
+FILE="/etc/tinc/retiolum/hosts/"+myname
PORT=6667
-NICK= "${myname}_"+str(random.randint(23,666))
+NICK= myname+"_"+str(random.randint(23,666))
sock = socket.socket(socket.AF_INET,socket.SOCK_STREAM)
sock.connect((HOST,PORT))