adding action to a resource

Dusty Doris
2008-02-19T18:11:24Z

This question is for merb-core 0.9

What is the best way to add an action to a single resource?

Suppose I have an account resource for the current_user and I wanted
to add an activate method to it.  Would it require something like
this?

  r.resource :account do |a|
    a.match(''/activate'').to(:action =>
''activate'')
  end

Or, is there a quicker way to do it?

Also, is there any way to get a named_route out of that?  So, I could
have something like :activate_account?

Or, should I be pulling that out into its own resource?  Any suggestions?

Thanks
Dusty Doris