chiark
/
gitweb
/
~mdw
/
odin-cgi
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
93ec1b8
)
bin/pastebin.userv: Correct usage and parsing for the `update' command.
author
Mark Wooding
<mdw@distorted.org.uk>
Thu, 26 Nov 2015 15:25:58 +0000
(15:25 +0000)
committer
Mark Wooding
<mdw@distorted.org.uk>
Thu, 26 Nov 2015 18:50:29 +0000
(18:50 +0000)
bin/pastebin.userv
patch
|
blob
|
blame
|
history
diff --git
a/bin/pastebin.userv
b/bin/pastebin.userv
index c45d4e669ff2cdf4a7f9695ac02b118158bba85c..fd263bd089bceccf9e043464ca48734ad38240d0 100755
(executable)
--- a/
bin/pastebin.userv
+++ b/
bin/pastebin.userv
@@
-97,8
+97,9
@@
EOF
else { $op->unk; }
}
@ARGV = $op->rest;
- $op->bad if @ARGV;
- $op->ok or Odin::fail "usage: new [-l LANG] [-t TITLE]";
+ $op->bad if @ARGV != 1;
+ $op->ok or Odin::fail "usage: update [-c] [-l LANG] [-t TITLE] TAG";
+ my $tag = shift @ARGV;
$p{content} = read_content if $contentp;
Odin::update_pastebin $tag, undef, %p or Odin::fail "nothing changed";
} else {