elvish_config/aliases/sendsms.elv

12 lines
306 B
Plaintext
Raw Normal View History

2021-08-24 18:45:25 +00:00
edit:add-var sendsms~ [@argv]{
use str
var api = https://smsapi.free-mobile.fr/sendmsg
var param = (cat $E:HOME/.config/elvish/private/freesms.json | from-json)
var msg = (str:join '%20' $argv)
2021-08-24 18:45:25 +00:00
var url = $api'?user='$param[user]'&pass='$param[password]'&msg='$msg
2021-08-24 18:45:25 +00:00
#put $url
curl $url
}