mirror of
https://github.com/NixOS/nix.dev.git
synced 2024-10-18 00:06:26 -04:00
fix mutable shortlinks (#903)
they were missing a response status code. use 302 since the target URL is decidedly not permanent: https://datatracker.ietf.org/doc/html/rfc9110#name-302-found
This commit is contained in:
parent
e0e2f95866
commit
2720a4121e
|
@ -46,7 +46,7 @@ let
|
|||
sed '/^#/d;/^$/d;s#^\(.*\) \(.*\) #/manual/nix/${version}\1 /manual/nix/${version}\2 #g' ${src version}/doc/manual/_redirects >> $out/_redirects
|
||||
'';
|
||||
shortlink = release: version: ''
|
||||
echo /nix/manual/${release} /nix/manual/${version} >> $out/_redirects
|
||||
echo /nix/manual/${release} /nix/manual/${version} 302 >> $out/_redirects
|
||||
'';
|
||||
versions = with pkgs.lib; lists.unique (attrsets.attrValues releases);
|
||||
in
|
||||
|
|
Loading…
Reference in a new issue