Why isn't 'gets' working in my Ruby script when I run from TextMate?

前端 未结 2 1738
梦谈多话
梦谈多话 2021-01-15 10:21

When running the following ruby script:

puts gets.inspect

On the terminal I am prompted for input and then the inspect output is sh

2条回答
  •  南笙
    南笙 (楼主)
    2021-01-15 11:02

    See this blog entry; presumably you're on Snow Leopard?

    From the comments, some users say that this file has worked for them on Snow Leopard. Per @dmarkow's answer, copy this file to:
    /Applications/TextMate.app/Contents/SharedSupport/Support/lib/
    You may want to keep a copy of the file around as updates to TextMate may replace it.

提交回复
热议问题