This project is archived and is in readonly mode.
Use rbconfig's Config::CONFIG['host_os'] instead of RUBY_PLATFORM
Reported by Anil Wadghule | April 26th, 2010 @ 10:48 AM
With reference to ticket & patch #3999. And
as per suggested here
proper-way-to-detect-windows-platform-in-ruby/. I have replaced
other occurrences of RUBY_PLATFORM with
Config::CONFIG['host_os'].
See the pastie http://pastie.org/935086 for values of both.
I haven't changed the file which #3999 patch fixes, so #3999 can be applied too.
This patch is against 3.0 master branch.
Do inform me, if there are further changes needed in patch. I will update the patch.
Comments and changes to this ticket
-
Anil Wadghule April 26th, 2010 @ 11:07 AM
- Assigned user set to Jeremy Kemper
Patch file is here use_rbconfig_host_os.diff as getting some problems while uploading patch via LH.
-
Repository April 26th, 2010 @ 07:13 PM
- State changed from new to resolved
(from [53c13f1acaa2eb05e7f418b53f6156a4f5a773e0]) Use Config::CONFIG['host_os'] instead of RUBY_PLATFORM [#4477 state:resolved]
Signed-off-by: Jeremy Kemper jeremy@bitsweat.net
http://github.com/rails/rails/commit/53c13f1acaa2eb05e7f418b53f6156... -
Loren Segal May 18th, 2010 @ 08:56 AM
This patch isn't 100% correct (though it's due to the initial implementation also being wrong).
Config::CONFIG['host_os']
can also return"cygwin"
under a cygwin build of Ruby. The regex does not take this into account.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>
People watching this ticket
Attachments
Referenced by
- 4479 [Rails 2-3 Stable] - Update RUBY_PLATFORM to Config::CONFIG['host_os'] With reference to #4477, I have updated RUBY_PLATFORM to ...
- 4477 Use rbconfig's Config::CONFIG['host_os'] instead of RUBY_PLATFORM (from [53c13f1acaa2eb05e7f418b53f6156a4f5a773e0]) Use Con...
- 4479 [Rails 2-3 Stable] - Update RUBY_PLATFORM to Config::CONFIG['host_os'] Duplicates #4477