mirror of
https://github.com/oh-my-fish/oh-my-fish.git
synced 2024-11-29 20:13:43 +08:00
[dpaste] Fix hour, week, month expired snippets
This commit is contained in:
parent
668849a9c3
commit
e5b7c01934
|
@ -35,8 +35,9 @@ end
|
|||
|
||||
function __dpaste_parse_expires
|
||||
set expires_spec "-t $__dpaste_expires_choises"
|
||||
set expires (echo $argv | __sed "s/.*$expires_spec.*/\1/" | sed 's/hour/3600/' | sed 's/week/604800/' | sed 's/month/2592000/')
|
||||
set expires (echo $argv | __sed "s/.*$expires_spec.*/\1/")
|
||||
if [ -z (echo $expires | __sed "s/$__dpaste_expires_choises//") ]
|
||||
set expires (echo $expires | sed 's/hour/3600/' | sed 's/week/604800/' | sed 's/month/2592000/')
|
||||
set __dpaste_send_url "$__dpaste_send_url&expires=$expires"
|
||||
end
|
||||
echo $argv | __sed "s/$expires_spec//" | xargs
|
||||
|
|
Loading…
Reference in New Issue
Block a user