zsh-users
 help / color / mirror / code / Atom feed
* rake completion
@ 2006-03-09 23:57 Dominic Mitchell
  2006-03-10 15:13 ` Clint Adams
  0 siblings, 1 reply; 2+ messages in thread
From: Dominic Mitchell @ 2006-03-09 23:57 UTC (permalink / raw)
  To: Zsh User

If you're using Rails, this completion for the rake command might come
in handy:

  http://weblog.rubyonrails.com/articles/2006/03/09/fast-rake-task-completion-for-zsh

-Dom


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: rake completion
  2006-03-09 23:57 rake completion Dominic Mitchell
@ 2006-03-10 15:13 ` Clint Adams
  0 siblings, 0 replies; 2+ messages in thread
From: Clint Adams @ 2006-03-10 15:13 UTC (permalink / raw)
  To: Dominic Mitchell; +Cc: Zsh User

> If you're using Rails, this completion for the rake command might come
> in handy:
> 
>   http://weblog.rubyonrails.com/articles/2006/03/09/fast-rake-task-completion-for-zsh

That could be rewritten to something like the following, but we already
distribute a rake completion function.  It would probably be better to
modify that to add caching-layer support and address any other
deficiencies rake users might point out.

#compdef rake

if [[ -f Rakefile ]]; then
  if [[ ! -f .rake_tasks ]] || [[ .rake_tasks -ot Rakefile ]]; then
    print ${${(f)"$(rake --silent --tasks)"}#* } > .rake_tasks
  fi
  compadd $(cat .rake_tasks)
fi


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2006-03-11  7:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-03-09 23:57 rake completion Dominic Mitchell
2006-03-10 15:13 ` Clint Adams

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).