Use Native File::PATH_SEPARATOR and remove $ before gem env

Address @luislavena's comment: https://github.com/rubygems/rubygems/pull/913#discussion_r12563149