*Install "curl" if you don't have already.
#yum install curl
*Copy the colored code and save as twit.sh
*Replace USER with your Twitter A/c's user name and PASSWORD with password.
*make twit.sh executable.
#chmod +x twit.sh
Your script is ready to post messages.Go to terminal. Use the following command.
$sh twit.sh "Your Message here."
------------------------script start here--------------------------------------
#!/bin/bash
curl -u USER:PASS -d status="$*" http://twitter.com/statuses/update.xml > /dev/null
echo "Message posted successfully."
----------------------------------------------------------------------------------------- curl -u USER:PASS -d status="$*" http://twitter.com/statuses/update.xml > /dev/null
echo "Message posted successfully."
Note- This tutorial is for Redhat and Fedora Linux, although you can use this script on any distro if you have "curl" installed on your machine. To install curl on your distro look their installation manual.
0 comments :
Post a Comment