<div dir="ltr"><div class="gmail_quote"><div dir="ltr">OK, but redirecting all URLs containing files which can be formatted by the about filter & located below /tree to /about is not effective:<br></div><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr"><div><div>        location ~ \.(md|MD|rst|RST|[1-9]|html|HTML|txt|TXT)$ </div><div>        {</div><div>                rewrite ^(/.*)/tree/(.*)$ $1/about/$2 permanent;</div><div>        }</div></div><div>leads to a "404 Not Found".</div><div><br></div><div>For instance, <a href="https://git.sdxlive.com/PPA/tree/Wireshark/README.md" target="_blank">https://git.sdxlive.com/PPA/tree/Wireshark/README.md</a>, I get the error log:</div><div>2018/12/27 12:52:49 [error] 20915#20915: *1 open() "/usr/share/nginx/html/PPA/about/Wireshark/README.md" failed (2: No such file or directory), client: 2a01:cb00:745:c100:26d7:494a:7c78:c99a, server: <a href="http://git.sdxlive.com" target="_blank">git.sdxlive.com</a>, request: "GET /PPA/about/Wireshark/README.md HTTP/2.0", host: "<a href="http://git.sdxlive.com" target="_blank">git.sdxlive.com</a>", referrer: "<a href="https://git.sdxlive.com/PPA/tree/Wireshark" target="_blank">https://git.sdxlive.com/PPA/tree/Wireshark</a>"<br></div><div><br></div><div>If I remove the location/rewrite directives and restart nginx, the same URL <a href="https://git.sdxlive.com/PPA/tree/Wireshark/README.md" target="_blank">https://git.sdxlive.com/PPA/tree/Wireshark/README.md</a> is correctly displayed & formatted with the about filter.</div><div><br></div><div>What am I missing?</div><div>-- <br></div></div></div></div></div></div></div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature">Jean-Christophe</div></div>