annotate bin/paste @ 485:38fa3e355258

<nortti> run echo "? welcome | python -c \"print (lambda s: ''.join([ (s[i].upper() if i%2==0 else s[i].lower()) for i in range(len(s)) ]))(raw_input())\"" > /hackenv/bin/WeLcOmE
author HackBot
date Sun, 03 Jun 2012 15:40:28 +0000
parents e037173e0012
children fa63d5796937
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
e037173e0012 Initial import.
HackBot
parents:
diff changeset
1 #!/bin/bash
e037173e0012 Initial import.
HackBot
parents:
diff changeset
2 if [ ! "$1" ]
e037173e0012 Initial import.
HackBot
parents:
diff changeset
3 then
e037173e0012 Initial import.
HackBot
parents:
diff changeset
4 PASTE=-
e037173e0012 Initial import.
HackBot
parents:
diff changeset
5 else
e037173e0012 Initial import.
HackBot
parents:
diff changeset
6 PASTE="$1"
e037173e0012 Initial import.
HackBot
parents:
diff changeset
7 fi
e037173e0012 Initial import.
HackBot
parents:
diff changeset
8
e037173e0012 Initial import.
HackBot
parents:
diff changeset
9 PASTENUM="$RANDOM"
e037173e0012 Initial import.
HackBot
parents:
diff changeset
10
e037173e0012 Initial import.
HackBot
parents:
diff changeset
11 mkdir -p $HACKENV/paste
e037173e0012 Initial import.
HackBot
parents:
diff changeset
12
e037173e0012 Initial import.
HackBot
parents:
diff changeset
13 echo 'http://codu.org/projects/hackbot/fshg/index.cgi/raw-file/tip/paste/paste.'"$PASTENUM"
e037173e0012 Initial import.
HackBot
parents:
diff changeset
14 cat "$PASTE" > $HACKENV/paste/paste."$PASTENUM"