<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
 
 <title>Alejandro Riera Mainar</title>
 <link href="http://ariera.github.com/atom.xml" rel="self"/>
 <link href="http://ariera.github.com/"/>
 <updated>2012-01-10T10:02:52-08:00</updated>
 <id>http://ariera.github.com/</id>
 <author>
   <name>Alejandro Riera Mainar</name>
   <email>info@ariera.net</email>
 </author>

 
 <entry>
   <title>MBP Trackpad, right click (two-finger tap) not working on Mac OS X Lion</title>
   <link href="http://ariera.github.com/2011/12/11/MBP-trackpad-right-click-not-working-on-Mac-OS-X-Lion.html"/>
   <updated>2011-12-11T00:00:00-08:00</updated>
   <id>http://ariera.github.com/2011/12/11/MBP-trackpad-right-click-not-working-on-Mac-OS-X-Lion</id>
   <content type="html">&lt;h1&gt;MBP Trackpad, right click (two-finger tap) not working on Mac OS X Lion&lt;/h1&gt;

&lt;p class=&quot;meta&quot;&gt;11 December 2011 - Madrid&lt;/p&gt;


&lt;p&gt;Don't know why but my MacBook Pro (early 2008 ~ MBP 4,1) won't enable the two-finger tap through the trackpad preferences panel o_O?&lt;/p&gt;

&lt;p&gt;Solution, from your console:&lt;/p&gt;

&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;bash&quot;&gt;defaults -currentHost write -g com.apple.trackpad.enableSecondaryClick -bool YES
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;


&lt;p&gt;Then log out and log in again.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;src: &lt;a href=&quot;https://discussions.apple.com/thread/3189975?start=0&amp;amp;tstart=0&quot;&gt;https://discussions.apple.com/thread/3189975?start=0&amp;amp;tstart=0&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Configuring Git after formatting</title>
   <link href="http://ariera.github.com/2011/12/11/Git-shortcuts.html"/>
   <updated>2011-12-11T00:00:00-08:00</updated>
   <id>http://ariera.github.com/2011/12/11/Git-shortcuts</id>
   <content type="html">&lt;h1&gt;Configuring Git after formatting&lt;/h1&gt;

&lt;p class=&quot;meta&quot;&gt;11 December 2011 - Madrid&lt;/p&gt;


&lt;p&gt;Simply copy&amp;amp;paste this in your console:&lt;/p&gt;

&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;bash&quot;&gt;&lt;span class=&quot;c&quot;&gt;#Author&lt;/span&gt;
git config --global user.name &lt;span class=&quot;s2&quot;&gt;&amp;quot;Alejandro Riera&amp;quot;&lt;/span&gt;
git config --global user.email ariera@whatever.com

&lt;span class=&quot;c&quot;&gt;# Abbreviations&lt;/span&gt;
git config --global alias.st status
git config --global alias.co checkout
git config --global alias.ci commit
git config --global alias.br branch

&lt;span class=&quot;c&quot;&gt;##&lt;/span&gt;
&lt;span class=&quot;c&quot;&gt;# Pimp-out log:&lt;/span&gt;
&lt;span class=&quot;c&quot;&gt;# From: http://www.jukie.net/bart/blog/pimping-out-git-log&lt;/span&gt;
git config --global alias.lg &lt;span class=&quot;s2&quot;&gt;&amp;quot;log --graph --pretty=format:&amp;#39;%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)&amp;lt;%an&amp;gt;%Creset&amp;#39; --abbrev-commit --date=relative&amp;quot;&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;


&lt;p&gt;&lt;em&gt;src: &lt;a href=&quot;http://superuser.com/questions/169695/what-are-your-favorite-git-aliases&quot;&gt;http://superuser.com/questions/169695/what-are-your-favorite-git-aliases&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>GET request with params in Titanium to a Rails backend</title>
   <link href="http://ariera.github.com/2011/08/30/get-request-with-params-in-titanium-to-a-rails-backend.html"/>
   <updated>2011-08-30T00:00:00-07:00</updated>
   <id>http://ariera.github.com/2011/08/30/get-request-with-params-in-titanium-to-a-rails-backend</id>
   <content type="html">&lt;h1&gt;GET request with params in Titanium to a Rails backend&lt;/h1&gt;

&lt;p class=&quot;meta&quot;&gt;30 Agaust 2011 - Madrid&lt;/p&gt;


&lt;p&gt;I'm currently developing an iPhone app with &lt;a href=&quot;http://www.appcelerator.com/&quot;&gt;Appcelerator's Titanium&lt;/a&gt; that communicates with a Rails backend. Doing so I found a few problems and here is how I solved them. This is the first time I work with Titanium, so don't expect something fancy ; )&lt;/p&gt;

&lt;h2&gt;Ajax GET request with params:&lt;/h2&gt;

&lt;p&gt;We'll use &lt;code&gt;Titanium.Network.HTTPClient&lt;/code&gt;, if you have never used it I suggest that you take a look a this &lt;a href=&quot;http://wiki.appcelerator.org/display/guides/Handling+Remote+Data+with+HTTPClient+and+JSON&quot;&gt;awesome example in the Titanium wiki&lt;/a&gt; that perfectly covers the basics.&lt;/p&gt;

&lt;p&gt;Say our rails app is a blog at the domain: &lt;em&gt;http://www.railsblog.com&lt;/em&gt;, and we want to get the all posts that are written in &lt;em&gt;Spanish&lt;/em&gt; by the author &lt;em&gt;ariera&lt;/em&gt;. My first attempt to do so looked like this:&lt;/p&gt;

&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;javascript&quot;&gt;    &lt;span class=&quot;kd&quot;&gt;var&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;postsReq&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;Titanium&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;Network&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;createHTTPClient&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;();&lt;/span&gt;
    &lt;span class=&quot;nx&quot;&gt;postsReq&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;open&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&amp;quot;GET&amp;quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&amp;quot;http://www.railsblog.com/posts&amp;quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;);&lt;/span&gt;
    &lt;span class=&quot;kd&quot;&gt;var&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;params&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;{&lt;/span&gt;
        &lt;span class=&quot;nx&quot;&gt;language&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&amp;quot;spanish&amp;quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt;
        &lt;span class=&quot;nx&quot;&gt;author&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;:&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&amp;quot;ariera&amp;quot;&lt;/span&gt;
    &lt;span class=&quot;p&quot;&gt;};&lt;/span&gt;
    &lt;span class=&quot;nx&quot;&gt;postsReq&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;send&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;params&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;);&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;


&lt;p&gt;It took me some time to understand why, but &lt;strong&gt;that code doesn't work as you would expect&lt;/strong&gt; it to work. Although we clearly specified that we wanted to do a &lt;code&gt;GET&lt;/code&gt; request it will do it as a &lt;code&gt;POST&lt;/code&gt;. The reason why this happens is that &lt;strong&gt;when you pass any parameter to the &lt;em&gt;send&lt;/em&gt; method it automatically converts the request into &lt;code&gt;POST&lt;/code&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;My solution was to manually construct the url with parameters using &lt;code&gt;encondeURI&lt;/code&gt;:&lt;/p&gt;

&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;javascript&quot;&gt;    &lt;span class=&quot;kd&quot;&gt;var&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;url&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&amp;quot;http://www.railsblog.com/posts&amp;quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt;
    &lt;span class=&quot;kd&quot;&gt;var&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;params&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&amp;quot;?language=spanish&amp;amp;author=ariera&amp;quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;;&lt;/span&gt;
    &lt;span class=&quot;kd&quot;&gt;var&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;encodedURI&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;nb&quot;&gt;encodeURI&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;url&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;+&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;params&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;);&lt;/span&gt;
    
    &lt;span class=&quot;kd&quot;&gt;var&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;postsReq&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;Titanium&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;Network&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;createHTTPClient&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;();&lt;/span&gt;
    &lt;span class=&quot;nx&quot;&gt;postsReq&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;open&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;(&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&amp;quot;GET&amp;quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;nx&quot;&gt;encodedURI&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;);&lt;/span&gt;
    &lt;span class=&quot;nx&quot;&gt;postsReq&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;nx&quot;&gt;send&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;();&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;


&lt;p&gt;And that finally worked. But was that all? Of course not ;-P&lt;/p&gt;

&lt;h2&gt;Titanium enable your Rails app:&lt;/h2&gt;

&lt;p&gt;When testing the iPhone app with my local copy of this railsblog I got the most &lt;em&gt;weird succinct not-descriptive&lt;/em&gt; error Rails ever gave me:&lt;/p&gt;

&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;bash&quot;&gt;Started GET &lt;span class=&quot;s2&quot;&gt;&amp;quot;/posts?language=spanish&amp;amp;author=ariera&amp;quot;&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;for &lt;/span&gt;127.0.0.1
  Processing by PostController#index as 
Completed 500 Internal Server Error in 1ms

NoMethodError &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;undefined method &lt;span class=&quot;sb&quot;&gt;`&lt;/span&gt;ref&lt;span class=&quot;err&quot;&gt;&amp;#39;&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;for &lt;/span&gt;nil:NilClass&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;:
  

Rendered .../gems/actionpack-3.1.0.rc4/lib/action_dispatch/middleware/templates/
    rescues/_trace.erb &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;1.1ms&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
Rendered .../gems/actionpack-3.1.0.rc4/lib/action_dispatch/middleware/templates/
    rescues/_request_and_response.erb &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;0.9ms&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
Rendered .../gems/actionpack-3.1.0.rc4/lib/action_dispatch/middleware/templates/
    rescues/diagnostics.erb within rescues/layout &lt;span class=&quot;o&quot;&gt;(&lt;/span&gt;4.8ms&lt;span class=&quot;o&quot;&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;


&lt;p&gt;that &lt;code&gt;NoMethodError (undefined method 'ref' for nil:NilClass)&lt;/code&gt; error drove me crazy for a while. Apparently this is due to a mix of user agent and Mime Types handled incorrectly by Rails. Following &lt;a href=&quot;http://stackoverflow.com/questions/5126085/ruby-on-rails-mobile-application/5130756#5130756&quot;&gt;this stackoverflow answer&lt;/a&gt; I did this:&lt;/p&gt;

&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;ruby&quot;&gt;    &lt;span class=&quot;c1&quot;&gt;# config/initializers/mime_types.rb&lt;/span&gt;
    &lt;span class=&quot;no&quot;&gt;Mime&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;::&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;Type&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;register_alias&lt;/span&gt; &lt;span class=&quot;s2&quot;&gt;&amp;quot;text/html&amp;quot;&lt;/span&gt;&lt;span class=&quot;p&quot;&gt;,&lt;/span&gt; &lt;span class=&quot;ss&quot;&gt;:titanium&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;




&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;ruby&quot;&gt;    &lt;span class=&quot;c1&quot;&gt;# app/controllers/application_controller.rb&lt;/span&gt;
    &lt;span class=&quot;n&quot;&gt;before_filter&lt;/span&gt; &lt;span class=&quot;ss&quot;&gt;:handle_titanium&lt;/span&gt;
    
    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;titanium_user_agent?&lt;/span&gt;
      &lt;span class=&quot;vi&quot;&gt;@mobile_user_agent&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;||=&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;(&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;request&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;env&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&amp;quot;HTTP_USER_AGENT&amp;quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;]&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;&amp;amp;&amp;amp;&lt;/span&gt; 
        &lt;span class=&quot;n&quot;&gt;request&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;env&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;[&lt;/span&gt;&lt;span class=&quot;s2&quot;&gt;&amp;quot;HTTP_USER_AGENT&amp;quot;&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;][/&lt;/span&gt;&lt;span class=&quot;no&quot;&gt;Titanium&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;/]&lt;/span&gt; &lt;span class=&quot;p&quot;&gt;)&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
    
    &lt;span class=&quot;k&quot;&gt;def&lt;/span&gt; &lt;span class=&quot;nf&quot;&gt;handle_titanium&lt;/span&gt;
      &lt;span class=&quot;n&quot;&gt;request&lt;/span&gt;&lt;span class=&quot;o&quot;&gt;.&lt;/span&gt;&lt;span class=&quot;n&quot;&gt;format&lt;/span&gt; &lt;span class=&quot;o&quot;&gt;=&lt;/span&gt; &lt;span class=&quot;ss&quot;&gt;:titanium&lt;/span&gt; &lt;span class=&quot;k&quot;&gt;if&lt;/span&gt; &lt;span class=&quot;n&quot;&gt;titanium_user_agent?&lt;/span&gt;
    &lt;span class=&quot;k&quot;&gt;end&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;



</content>
 </entry>
 
 <entry>
   <title>A keyboard shortcut to run tests with watchr</title>
   <link href="http://ariera.github.com/2011/08/13/a-keyboard-shortcut-to-run-tests-with-watchr.html"/>
   <updated>2011-08-13T00:00:00-07:00</updated>
   <id>http://ariera.github.com/2011/08/13/a-keyboard-shortcut-to-run-tests-with-watchr</id>
   <content type="html">&lt;h1&gt;A keyboard shortcut to run tests with watchr&lt;/h1&gt;

&lt;p class=&quot;meta&quot;&gt;13 Agaust 2011 - Madrid&lt;/p&gt;


&lt;p&gt;When developing in rails I use &lt;a href=&quot;https://github.com/mynyml/watchr&quot;&gt;watchr&lt;/a&gt; to run the tests each time a file is saved, but lots of times I find my self adding a whitespace or a newline and saving just to trigger watchr and run the tests.&lt;/p&gt;

&lt;p&gt;I wanted to have is a simple keyboard shortcut (like &lt;code&gt;F15&lt;/code&gt;) to tell watchr to run the last spec, and &lt;a href=&quot;https://github.com/mpartel&quot;&gt;mpartel&lt;/a&gt; (thx! : ) gave me an idea on &lt;a href=&quot;https://github.com/mynyml/watchr/issues/31#issuecomment-1773937&quot;&gt;how to do it&lt;/a&gt;, so here it is.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The rest of the entry is in this gist: &lt;a href=&quot;https://gist.github.com/1139285&quot;&gt;https://gist.github.com/1139285&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Nestable, sortable and dragable categories for a Rails project</title>
   <link href="http://ariera.github.com/2011/08/07/nestable-sortable-and-dragable-categories.html"/>
   <updated>2011-08-07T00:00:00-07:00</updated>
   <id>http://ariera.github.com/2011/08/07/nestable-sortable-and-dragable-categories</id>
   <content type="html">&lt;h1&gt;Nestable, sortable and dragable categories for a Rails project&lt;/h1&gt;

&lt;p class=&quot;meta&quot;&gt;07 Agaust 2011 - Madrid&lt;/p&gt;


&lt;p&gt;In the project I'm working on we wanted to have a Category model which we wanted to be nestable. But we also liked the user to have a draggable interface to manage and rearrange the order of his categories. So we chose &lt;a href=&quot;https://github.com/collectiveidea/awesome_nested_set/&quot;&gt;awesome_nested_set&lt;/a&gt; for the model and &lt;a href=&quot;http://mjsarfatti.com/sandbox/nestedSortable/&quot;&gt;jQuery.nestedSortable&lt;/a&gt; for the UI.&lt;/p&gt;

&lt;p&gt;It took me some time to arrange things to work properly so I wanted to share my work in case it helps anybody.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The rest of the entry is in this gist: &lt;a href=&quot;https://gist.github.com/1130504&quot;&gt;https://gist.github.com/1130504&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>diMLOrb, my first gem</title>
   <link href="http://ariera.github.com/2011/07/17/dimlorb-my-first-gem.html"/>
   <updated>2011-07-17T00:00:00-07:00</updated>
   <id>http://ariera.github.com/2011/07/17/dimlorb-my-first-gem</id>
   <content type="html">&lt;h1&gt;diMLOrb, my first gem&lt;/h1&gt;

&lt;p class=&quot;meta&quot;&gt;17 July 2011 - Madrid&lt;/p&gt;


&lt;p&gt;Metro Ligero Oeste (MLO) is the tramway line I have to take every day. Knowing its timetables is extremely important, especially on weekends when you may have to wait 20 minutes if you miss one. They have recently made a &lt;a href=&quot;http://www.dimlo.es&quot;&gt;web page&lt;/a&gt; which is not awesome but does the job. Nevertheless I wanted more, I wanted a single-click web-app for my iphone that gives me only the information of the trams I take every day, the result: &lt;a href=&quot;http://dimloya.heroku.com/&quot;&gt;diMLOya&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;For that purpose I decided to create my first gem ever, you can check it out in its repo: &lt;a href=&quot;https://github.com/ariera/diMLOrb&quot;&gt;https://github.com/ariera/diMLOrb&lt;/a&gt;&lt;/p&gt;
</content>
 </entry>
 
 <entry>
   <title>Shortcuts (&#8984;&#8594; &amp; &#8984;&#8592;) with Textmate and Snow Leopard</title>
   <link href="http://ariera.github.com/2010/06/08/home-end-buttons-with-textmate-in-snow-leopard.html"/>
   <updated>2010-06-08T00:00:00-07:00</updated>
   <id>http://ariera.github.com/2010/06/08/home-end-buttons-with-textmate-in-snow-leopard</id>
   <content type="html">&lt;h1&gt;Shortcuts (&amp;#8984;&amp;#8594; &amp;amp; &amp;#8984;&amp;#8592;) with Textmate and Snow Leopard&lt;/h1&gt;

&lt;p class=&quot;meta&quot;&gt;08 June 2010 - Madrid&lt;/p&gt;


&lt;p&gt;Don’t know why these two shortcuts (aswell as home and end buttons) stoped working in textmate after I upgraded to SL.&lt;/p&gt;

&lt;p&gt;The solution (based on &lt;a href=&quot;http://blog.macromates.com/2005/key-bindings-for-switchers/&quot;&gt;this post&lt;/a&gt; of the textmate blog) is simple: create and edit the DefaultKeyBinding.dic file:&lt;/p&gt;

&lt;div class=&quot;highlight&quot;&gt;&lt;pre&gt;&lt;code class=&quot;bash&quot;&gt;    mkdir ~/Library/KeyBindings
    &lt;span class=&quot;nb&quot;&gt;cd&lt;/span&gt; ~/Library/KeyBindings
    touch DefaultKeyBinding.dict
    open -a TextMate DefaultKeyBinding.dict
&lt;/code&gt;&lt;/pre&gt;
&lt;/div&gt;


&lt;p&gt;Paste these bindings:&lt;/p&gt;

&lt;pre&gt;&lt;code&gt;{
    /* home */
    &quot;\UF729&quot;  = &quot;moveToBeginningOfLine:&quot;; /* home */
    &quot;@\UF702&quot;  = &quot;moveToBeginningOfLine:&quot;; /* command + left arrow*/
    &quot;$\UF729&quot; = &quot;moveToBeginningOfLineAndModifySelection:&quot;;
    &quot;$@\UF702&quot; = &quot;moveToBeginningOfLineAndModifySelection:&quot;;

    /* end */
    &quot;\UF72B&quot;  = &quot;moveToEndOfLine:&quot;;
    &quot;@\UF703&quot;  = &quot;moveToEndOfLine:&quot;;
    &quot;$\UF72B&quot; = &quot;moveToEndOfLineAndModifySelection:&quot;;
    &quot;$@\UF703&quot; = &quot;moveToEndOfLineAndModifySelection:&quot;;

    /* page up/down */
    &quot;\UF72C&quot;  = &quot;pageUp:&quot;;
    &quot;\UF72D&quot;  = &quot;pageDown:&quot;;
}
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Restart Textmate &amp;amp; enjoy : )&lt;/p&gt;
</content>
 </entry>
 
 
</feed>