[ditz-talk] Problems with environment "HOME" under Windows

Andreas Habel mail at exceptionfault.de
Wed Jun 18 09:31:10 EDT 2008


Hello William,

when I try to use ditz3.0 I receive the following error:

C:\>ditz --version
c:/ruby/lib/ruby/gems/1.8/gems/ditz-0.3/bin/ditz:34:in `join': can't  
convert nil into String (TypeError)
         from c:/ruby/lib/ruby/gems/1.8/gems/ditz-0.3/bin/ditz:34:in `cloaker_'
         from  
c:/ruby/lib/ruby/gems/1.8/gems/trollop-1.8/lib/trollop.rb:55:in `call'
         from  
c:/ruby/lib/ruby/gems/1.8/gems/trollop-1.8/lib/trollop.rb:55:in  
`initialize'
         from  
c:/ruby/lib/ruby/gems/1.8/gems/trollop-1.8/lib/trollop.rb:438:in `new'
         from  
c:/ruby/lib/ruby/gems/1.8/gems/trollop-1.8/lib/trollop.rb:438:in  
`options'
         from c:/ruby/lib/ruby/gems/1.8/gems/ditz-0.3/bin/ditz:31
         from c:/ruby/bin/ditz:16:in `load'
         from c:/ruby/bin/ditz:16

The mentioned line tries to get the value "HOME" from my environment,  
which is not set on my windows box.

>  opt :config_file, "Configuration file", :default =>  
> File.join(ENV["HOME"], CONFIG_FN)

Instead of "HOME" there are three other values defined:

HOMEDRIVE=H:
HOMEPATH=\
HOMESHARE=\\some-unc-path-to-my-home-share

If I do "C:\>set HOME=%HOMESHARE%", everything is fine...

C:\>ditz --version
ditz 0.3

I don't know, if HOMESHARE is the default for windows.

greetings
Andreas



More information about the ditz-talk mailing list