> On the Win2K box the following line works fine (and echoes the name of
> the host)
>
> puts `hostname`
>
> But other commands like "dir", "cd" and the like don't work... What I
> get is, eg.:
>
> C:\script.rb:1: command not found: dir
>
> with "script.rb" containing the line:
>
> puts `dir

On Win32 platforms, commands like dir, cd etc are commands that are part of
the command shell(cmd.exe on NT, and command.com on 98).  In order to
execute one of these commands through ruby, you have to invoke the shell
with the /C option.

Example for NT/2000:
`cmd /C dir`

Hope that helps,
aaron