<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DZone Snippets: gedit code</title>
    <link>http://snippets.dzone.com/posts</link>
    <pubDate>Sun, 18 May 2008 01:18:46 GMT</pubDate>
    <description>DZone Snippets: gedit code</description>
    <item>
      <title>Twitter and Jaiku from the command line</title>
      <link>http://snippets.dzone.com/posts/show/5265</link>
      <description>The following instructions make it easy to post to Twitter and Jaiku from the command line. The instructions were copied from the article &lt;a href="http://snipr.com/22b38"&gt;"Ubuntu Unleashed: Howto Twitter From the Command Line in Ubuntu!"&lt;/a&gt;  [ubuntu-unleashed.com] and modified to post via Rorbuilder's ProjectX API.&lt;br /&gt;&lt;br /&gt;&lt;code&gt;sudo apt-get install curl&lt;/code&gt;&lt;br /&gt;&lt;code&gt;sudo gedit /usr/bin/jaitwit&lt;/code&gt;&lt;br /&gt;Now Paste this in gEdit and simply replace "YourUsername" with your username and "YourPassword" with your twitter passwd, then replace the Jaiku variables (YourUsername, YourPassword, YourCity, YourAccessKey) and ctrl-s to save, then alt-F4 to exit!&lt;br /&gt;&lt;code&gt;&lt;br /&gt;curl http://rorbuilder.info/api/projectx.cgi?xml_project=%3Cproject%20name=%22micro_blog%22%3E%3Cmethods%3E%3Cmethod%20name=%22post2jaiku%22%3E%3Cparams%3E%3Cparam%20var=%22user%22%20val=%22YourUsername%22/%3E%3Cparam%20var=%22msg%22%20val=%22`echo $@|tr ' ' '+'`%22/%3E%3Cparam%20var=%22location%22%20val=%22YourCity%22/%3E%3Cparam%20var=%22apikey%22%20val=%22YourAccessKey%22/%3E%3C/params%3E%3C/method%3E%3Cmethod%20name=%22post2twitter%22%3E%3Cparams%3E%3Cparam%20var=%22user%22%20val=%22YourUsername%22/%3E%3Cparam%20var=%22msg%22%20val=%22`echo $@|tr ' ' '+'`%22/%3E%3Cparam%20var=%22password%22%20val=%22YourPassword%22/%3E%3C/params%3E%3C/method%3E%3C/methods%3E%3C/project%3E -o /dev/null&lt;br /&gt;echo Message Sent!&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Then chmod for exec privileges:&lt;br /&gt;&lt;code&gt;chmod +x /usr/bin/jaitwit&lt;/code&gt;&lt;br /&gt;Then from the CLI type jaitwit followed by your message.&lt;br /&gt;&lt;code&gt;jaitwit "message here without the quotes"&lt;/code&gt;</description>
      <pubDate>Fri, 21 Mar 2008 18:28:00 GMT</pubDate>
      <guid>http://snippets.dzone.com/posts/show/5265</guid>
      <author>jrobertson (James Robertson)</author>
    </item>
  </channel>
</rss>
