title: Rails routing: resources with only custom actions
body: <p>I have a <code>NotificationsController</code>, in which I only have the action <code>clear</code>.</p>
  
  <p>I'd like to access this action by doing POST /notifications/clear</p>
  
  <p>So I wrote this in my router:</p>
  
  <pre><code>  resources :notifications, :only =&gt; [] do
      collection do
        post :clear
      end
    end
  </code></pre>
  
  <p>Is there a cleaner way to achieve this? I thought</p>
  
  <pre><code>  scope :notifications do
      post :clear
    end
  </code></pre>
  
  <p>would do it, but I have a <code>missing controller</code> error, because - I think - it looks for the <code>clear</code> controller.</p>