Forum: Ruby on Rails freeze_gems on windows

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
F48118fe74b0c7f6fd82a0ee422fa34e?d=identicon&s=25 snacktime (Guest)
on 2005-11-26 01:28
(Received via mailing list)
When running 'rake freeze_gems' on windows XP I get the following
errors.  Is freeze_gems supported on windows or is something else
going on?  I get the same results on XP professional and home edition.
 Ruby and rubygems was installed from the latest windows installer at
ruby-lang.org.

C:\test>rake freeze_gems
(in C:/test)
rm -rf vendor/rails
mkdir -p vendor/rails
Freezing to your latest Rails gems
The system cannot find the path specified.
rake aborted!
undefined method `to_str' for nil:NilClass
A539f55ee4798b0736e616e942e412ca?d=identicon&s=25 paul.abraham (Guest)
on 2005-11-26 20:24
(Received via mailing list)
snacktime wrote:

> Freezing to your latest Rails gems
> The system cannot find the path specified.
> rake aborted!
> undefined method `to_str' for nil:NilClass

Assuming you're using rails-0.14.2, the only way that I have been
able to use freeze_gems on XP is to edit framework.rake[1] and
change as follows:

Line 7: Change "cd vendor/rails; gem unpack #{gem}" to "cd
vendor/rails && gem unpack #{gem}"

Line 11: Change "cd vendor/rails; gem unpack rails" to "cd
vendor/rails && gem unpack rails"

See also Zachary Pinter's blog about the same problem[2].

If you have already run freeze_gems unsuccessfully, you will need
to remove the vendor directory, otherwise you'll get an error
about ./config/../vendor/rails/railties/lib/initializer.

Paul.


[1] C:\ruby\lib\ruby\gems\1.8\gems\rails-0.14.2\lib\tasks

[2]
http://blog.zacharypinter.com/articles/2005/10/26/...
This topic is locked and can not be replied to.