There's an easy way to do this so that the line doesn't get included on Windows:
ENV['INLINEDIR']="/tmp/ruby.#{ENV['USER']}" unless ENV['OS'] =~ /Windows/
The consequence is that Insoshi probably won't be deployable on
Windows out of the box, but I bet you can count on one hand the number
of production Windows Rails deployments in the world. :-)
Michael
On Fri, Apr 11, 2008 at 2:33 PM, Long Nguyen <[EMAIL PROTECTED]> wrote:
> FYI... your issue can up because I had added the line
>
> ENV['INLINEDIR']="/tmp/ruby.#{ENV['USER']}"
>
> at the end of config/environment.rb
>
> The default value of INLINEDIR is set to $HOME/.ruby_inline which normally
> runs without problem except if you've started your server via an su or sudo
> as would typically be the case if you've setup a mongrel cluster. In that
> case, $HOME may not be properly set and you may encounter a runtime error
> because the account for the server doesn't have permission to create/write
> to that directory. (And ruby_inline does check to see that directory is
> not world-writable.)
>
> Linux and OS X users probably won't encounter any issues because there's
> always a /tmp directory.
>
> Windows users should either create a C:\tmp (like you've done) or comment
> out that line.
>
> Long
>
>
>
> On Fri, Apr 11, 2008 at 12:48 PM, cw <[EMAIL PROTECTED]> wrote:
> >
> > I created a tmp directory under C:\ and that fixed the problem.
> >
> >
> >
> >
> >
> > On Apr 11, 2:11 pm, cw <[EMAIL PROTECTED]> wrote:
> > > Any help greatly appreciated.
> > >
> > > C:\insoshi\dev\insoshi>rake spec
> > > (in C:/insoshi/dev/insoshi)
> > >
> > > c:/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.6.7/lib/inline.rb:78:in
> > > `mkdir': No such file or directory - /tmp/ruby. (Errno:
> > > :ENOENT)
> > > from c:/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.6.7/lib/
> > > inline.rb:78:in `rootdir'
> > > from c:/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.6.7/lib/
> > > inline.rb:87:in `directory'
> > > from c:/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.6.7/lib/
> > > inline.rb:257:in `so_name'
> > > from c:/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.6.7/lib/
> > > inline.rb:297:in `load_cache'
> > > from c:/ruby/lib/ruby/gems/1.8/gems/RubyInline-3.6.7/lib/
> > > inline.rb:708:in `inline'
> > > from c:/ruby/lib/ruby/gems/1.8/gems/image_science-1.1.3-i386-
> > > mswin32/lib/image_science.rb:84
> > > from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:
> > > 32:in `gem_original_require'
> > > from c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:
> > > 32:in `require'
> > > ... 31 levels...
> > > from C:/insoshi/dev/insoshi/vendor/plugins/rspec/lib/spec/
> > > runner/example_group_runner.rb:13:in `load_files'
> > > from C:/insoshi/dev/insoshi/vendor/plugins/rspec/lib/spec/
> > > runner/options.rb:85:in `run_examples'
> > > from C:/insoshi/dev/insoshi/vendor/plugins/rspec/lib/spec/
> > > runner/command_line.rb:19:in `run'
> > > from C:/insoshi/dev/insoshi/vendor/plugins/rspec/bin/spec:4
> > > rake aborted!
> > > Command ruby -I"C:/insoshi/dev/insoshi/vendor/plugins/rspec/lib" "C:/
> > > insoshi/dev/insoshi/vendor/plugins/rspec/bin/spec" "sp
> > > ec/controllers/activities_controller_spec.rb" "spec/controllers/admin/
> > > forums_controller_spec.rb" "spec/controllers/admin/pe
> > > ople_controller_spec.rb" "spec/controllers/
> > > comments_controller_spec.rb" "spec/controllers/
> > > connections_controller_spec.rb" "
> > > spec/controllers/forums_controller_spec.rb" "spec/controllers/
> > > messages_controller_spec.rb" "spec/controllers/password_remin
> > > ders_controller_spec.rb" "spec/controllers/people_controller_spec.rb"
> > > "spec/controllers/photos_controller_spec.rb" "spec/co
> > > ntrollers/posts_controller_spec.rb" "spec/controllers/
> > > searches_controller_spec.rb" "spec/controllers/sessions_controller_sp
> > > ec.rb" "spec/controllers/topics_controller_spec.rb" "spec/helpers/
> > > activities_helper_spec.rb" "spec/helpers/comments_helper_
> > > spec.rb" "spec/helpers/communications_helper_spec.rb" "spec/helpers/
> > > connections_helper_spec.rb" "spec/helpers/display_helpe
> > > r_spec.rb" "spec/helpers/forums_helper_spec.rb" "spec/helpers/
> > > posts_helper_spec.rb" "spec/helpers/searches_helper_spec.rb"
> > > "spec/helpers/topics_helper_spec.rb" "spec/models/activity_spec.rb"
> > > "spec/models/blog_post_comment_spec.rb" "spec/models/bl
> > > og_post_spec.rb" "spec/models/blog_spec.rb" "spec/models/
> > > connection_spec.rb" "spec/models/feed_spec.rb" "spec/models/forum_
> > > post_spec.rb" "spec/models/forum_spec.rb" "spec/models/
> > > message_spec.rb" "spec/models/person_mailer_spec.rb" "spec/models/pe
> > > rson_spec.rb" "spec/models/photo_spec.rb" "spec/models/topic_spec.rb"
> > > "spec/models/wall_comment_spec.rb" "spec/views/layout
> > > s/application.html.erb_spec.rb" --options "C:/insoshi/dev/insoshi/spec/
> > > spec.opts" failed
> > >
> > > (See full trace by running task with --trace)
> > >
> > > C:\insoshi\dev\insoshi>
> >
> >
>
>
>
> --
> Long Nguyen
> [EMAIL PROTECTED]
>
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Insoshi" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/insoshi?hl=en
-~----------~----~----~----~------~----~------~--~---