I am used to doing Rails development work on a Mac. However, now other developers will be working with me and they use Windows, both XP and Vista. I am trying to figure out the Windows environment so I can help them.
我习惯在Mac上进行Rails开发工作。但是,现在其他开发人员将与我合作,他们使用Windows,包括XP和Vista。我试图找出Windows环境,以便我可以帮助他们。
In OS X and Linux you have this kind of thing...
在OS X和Linux中你有这种东西......
$ cd [Rails project root]
$ script/console
Tried it on Windows but all I got was "'script' is not recognized as an internal or external command...etc."
在Windows上尝试过,但我得到的只是“'脚本'不被认为是内部或外部命令......等等。”
What is the Windows equivalent?
什么是Windows等价物?
5 个解决方案
#1
Get into your rails directory, then type:
进入rails目录,然后键入:
ruby script/(your command)
Make sure that you have the path to ruby on your path - otherwise you need to do:
确保你的路径上有红宝石的路径 - 否则你需要这样做:
(path to ruby)/ruby script/(your command)
#2
ruby script/whatever
That should do it for you.
那应该为你做。
#3
Does:
c:\railsproject\> ruby script/console
work for you?
为你工作?
#4
Have you tried issuing ruby script\console ? (Windows uses backslashes as path delimeters instead of foreslashes and doesn't support shebang syntax.)
您是否尝试过发布ruby脚本\ console? (Windows使用反斜杠作为路径分隔符而不是预斜线,并且不支持shebang语法。)
#5
rails path/to/your/new/application
cd path/to/your/new/application
ruby script/server
Check this out: http://rubyonrails.org/download
看看这个:http://rubyonrails.org/download
#1
Get into your rails directory, then type:
进入rails目录,然后键入:
ruby script/(your command)
Make sure that you have the path to ruby on your path - otherwise you need to do:
确保你的路径上有红宝石的路径 - 否则你需要这样做:
(path to ruby)/ruby script/(your command)
#2
ruby script/whatever
That should do it for you.
那应该为你做。
#3
Does:
c:\railsproject\> ruby script/console
work for you?
为你工作?
#4
Have you tried issuing ruby script\console ? (Windows uses backslashes as path delimeters instead of foreslashes and doesn't support shebang syntax.)
您是否尝试过发布ruby脚本\ console? (Windows使用反斜杠作为路径分隔符而不是预斜线,并且不支持shebang语法。)
#5
rails path/to/your/new/application
cd path/to/your/new/application
ruby script/server
Check this out: http://rubyonrails.org/download
看看这个:http://rubyonrails.org/download