Improved blipsend


/ Published in: Bash
Save to your folder(s)

Improved blipsend miniapp
Requires curl, zenity and sed


Copy this code and paste it in your HTML
  1. #!/bin/bash
  2. # simpliest blip client zenity edition aka blipsendz
  3. # requires: zenity, curl, sed
  4. # put your blip login details (login:password) in ~/.blipdata file
  5. # TODO: support for char's like: ) / etc...
  6. if [ -a ~/.blipdata ]; then
  7.  
  8. curl -H'User-Agent: blipsend 0.1' -H'Accept: application/json' -H'X-Blip-api: 0.02' -u $(more ~/.blipdata) -F "update[body]=$(echo $(zenity --entry --text="New status") | sed 's/ /\ /g')" http://api.blip.pl/updates
  9. zenity --info --text="Your message was sent"
  10. else
  11. zenity --error --text="Missing login data\n Does ~/.blipdata exist?"
  12. fi

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.