在 Mac OS 上 安装完 ruby 2.0.0 ,打开 irb 开始练习 Ruby ,但是发现没有Tab代码补全功能,google解决,方案如下
1、安装 bond 执行如下命令即可
sudo gem install bond2、在当前用户根目录创建 .irbrc
vi ~/.irbrc3、在文件中添加如下内容
require 'bond' Bond.start4、保存关闭文件即可
再次打开 irb 就可以使用 tab 补全代码了
This is what worked for me on Mac OS 10.11.5. using rvm. Do the following :
sudo gem install bond- Create the file
.irbrcin your home directory.vi ~/.irbrc -
Add the following lines in the
.irbrcfilerequire 'bond' Bond.start -
Save and close the file
- Open
irband usetabkey to autocomplete

441

被折叠的 条评论
为什么被折叠?



