title: How to factor `paths:` in common for push: and pull_request: in github actions?
body: <p>I’d like to factor the common paths in this:</p>
  
  <pre><code>on:
    push:
      # Run only on changes on these files
      paths:
        - 'lib/**.nim'
        - 'doc/**.rst'
        - 'doc/nimdoc.css'
        - '.github/workflows/ci_docs.yml'
  
    pull_request:
      # Run only on changes on these files
      paths:
        - 'lib/**.nim'
        - 'doc/**.rst'
        - '.github/workflows/ci_docs.yml'
  </code></pre>
  
  <p>documentation on github mentions <code>[push, pull_request]</code> but it doesn’t work if we have paths node. What is the syntax to avoid code duplication?</p>
  
  <p>(apologies in advance for cross posting with <a href="https://github.community/t/how-to-factor-paths-in-common-for-push-and-pull-request/115967" rel="nofollow noreferrer">https://github.community/t/how-to-factor-paths-in-common-for-push-and-pull-request/115967</a>, if I get any answer I'll update on the other end)</p>