Closed zaki closed 13 years ago
On the first time, the generate
command takes a some while to show the options. This delay occurs because the completion script inspect your rails application looking for generators which are cached into .rails_generators
file.
No, it wasn't generating the cache file, but I think I figured out what the problem was for me. Completion works if I change the sed command in __railscmd()
to look like this:
any_command=$(echo $2 | sed -e 's/[[:space:]]/|/g')
For some reason it looks like sed does not understand the whitespace marker \s
although I'm not really sure yet why that is.
Completion works for "first level" commands (console, generate, server etc). However for further parameters, it stops working.
Environment: Mac OSX 10.6.7, bash, rails 3.0.6, ruby 1.9.2-p180 through RVM, gem 1.5.0