run this with nix-shell --pure ruby --version will give you 1.8.7, as expected gem --version will give you 2.4.x, not 1.8.30