Ruby上的Vista [英] Ruby on Vista

查看:115
本文介绍了Ruby上的Vista的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我昨天在Vista 32bit上安装了Ruby和Ruby on Rails,并使用本站的指示: http://rubyonrails.org /下载



所以我下载了安装程序,然后是Gems,然后我下载了Gems的rails。



<现在我不能在命令行中使用Gem或Ruby命令......所以我认为环境变量有问题,但我想知道如何在Vista中设置它们或放置什么。任何人都可以帮我解决这个问题吗?

解决方案

要设置环境变量,请执行此操作


  1. 点击计算机上的开始菜单
  2. 右键点击 c $ c>选择属性

  3. 单击高级系统设置左边的栏,并确认UAC提示

  4. 选择高级标签(它是第三个)

  5. 点击环境变量... (位于底部)

  6. 在顶部框( User XXX 的变量)找到 PATH 的条目,或者单击new创建条目。

    如果已经存在 PATH 使用分号分隔列出的每个目录

  7. 放置 c:\ruby\\ \\ bin (如果您在其他地方安装了ruby,则更改)。

  8. 点击确定很多次,关闭我们打开的所有窗口。 b $ b
  9. 重新启动您的命令提示符。

gem ruby​​ irb 现在都应该可以工作。谁说GUI工具比命令行工具慢。 pshaw!


I installed Ruby and Ruby on Rails yesterday on Vista 32bit using the directions on this site: http://rubyonrails.org/down

so I downloaded the installer, then Gems, then I downloaded rails with Gems.

now I can't use the Gem or Ruby commands in the command line... so I assume there's something wrong with the environment variables, but I hav eno idea how to set them up in Vista or what to put. Can anyone help me with this?

解决方案

To set up the environment variables, do this

  1. Fire up the start menu
  2. Right-Click on Computer and select Properties
  3. Click Advanced system settings in the left-hand bar, and confirm the UAC prompt
  4. Select the Advanced tab (it's 3rd)
  5. Click Environment Variables... (at the bottom)
  6. In the top box (User variables for XXX) either find the entry for PATH, or click new to create the entry.
    If there is already a PATH use semi-colons to seperate each directory listed in it
  7. Put c:\ruby\bin (change if you installed ruby somewhere else) in.
  8. Click OK a lot of times to close all the windows we opened.
  9. Restart your command prompt.

gem and ruby and irb should now all work. Whoever said that GUI tools are slower than command line tools. pshaw!

这篇关于Ruby上的Vista的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆