shell - Create a command line script -


i'm using web tool has inbound webhooks. provide me url, can post string , logs system.

i create script me , team can use terminal this:

~: appname  ~: webhook url?  

here can copy , paste url gives me, , stores it. can this:

~: appname message want send... 

and sends post webhook string. ideally can share non-techies , that's easy set up. , have no idea how start this.

i assuming want strictly shell.

in end want use curl (bash)

curl --data "msg=$2" $url 

the $url variable come flat file(app.txt) key value key=appname

you first script need append file(app.txt)

echo $1 $2 >> app.txt 

Comments

Popular posts from this blog

tcpdump - How to check if server received packet (acknowledged) -