title: How would I insert a line in a file after after a pattern that is across many lines
body: <p>I would like to insert a line right after the first time this pattern appears with bash. How would I go about doing it? I want to try to use the pattern to match location/ {*}</p>
  
  <pre><code>    location / {
              # First attempt to serve request as file, then
              # as directory, then fall back to displaying a 404.
              try_files $uri $uri/ =404;
              # Uncomment to enable naxsi on this location
              # include /etc/nginx/naxsi.rules
      }
  </code></pre>
  
  <p>and I want it to become</p>
  
  <pre><code>    location / {
              # First attempt to serve request as file, then
              # as directory, then fall back to displaying a 404.
              try_files $uri $uri/ =404;
              # Uncomment to enable naxsi on this location
              # include /etc/nginx/naxsi.rules
      }
      location /hbnb_static
  </code></pre>
  
  <p>Thanks I'd appreciate the help.</p>