‘which ruby’ returns me the latest ruby version installed which is 2.2.3.
‘which -a ruby’ returns 2 paths. one is 1.9
But the latest one is set as the default ruby for executing my chef recipe. But still when I execute a gem install using chef it takes the older version of ruby (1.9) and gives an error
‘rake requires Ruby version >= 2.0.0.’
Any idea why is this ?