I have installed Ruby through the RubyInstaller, which didn't include the ri documentation. Then I rebuilt it through rdoc --all --ri. But when I try to use it, I get weird chars like:

C:\Ruby>ri Array
←[0m←[1;32mArray < Object←[m

(from ~/.ri)
------------------------------------------------------------------------------
←[1;32mInstance methods:←[m

  abbrev, dclone, pretty_print, pretty_print_cycle, shelljoin, to_csv,
  to_yaml, yaml_initialize


C:\Ruby>
有帮助吗?

解决方案

Try ri -f plain Array. The arrows are escape sequences used to display colors.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top