Mercurial > repo
comparison paste.1 @ 4592:2c4e7296fa00
<oerjan> fetch http://oerjan.nvg.org/paste
author | HackBot |
---|---|
date | Sun, 20 Apr 2014 00:44:36 +0000 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
4591:abd8e1d1ae63 | 4592:2c4e7296fa00 |
---|---|
1 #!/bin/bash | |
2 if [ "$1" ] && url "$1" 2>/dev/null # Save making a file when it already exists. | |
3 then | |
4 else | |
5 PASTENUM="$RANDOM" | |
6 | |
7 mkdir -p $HACKENV/paste | |
8 | |
9 url paste/paste."$PASTENUM" | |
10 cat -- "${1--}" > $HACKENV/paste/paste."$PASTENUM" | |
11 fi |