From ff30f8878ee7e7a382eea23519783661b8fd0559 Mon Sep 17 00:00:00 2001 From: Quentin Aristote Date: Thu, 23 Feb 2023 19:24:01 +0100 Subject: add robots.txt --- default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/default.nix b/default.nix index 02a5455..4abdca3 100644 --- a/default.nix +++ b/default.nix @@ -28,6 +28,12 @@ let "grid" ])); + robotsTXT = builtins.toFile "robots.txt" '' + user-agent: * + disallow: /static/ + allow: /static/icon.png + ''; + in pkgs.callPackage ({ # Packages line-awesome, line-awesome-css, uncss, yuicompressor, imagemagick, @@ -50,6 +56,7 @@ in pkgs.callPackage ({ set -o xtrace mkdir $out && pushd "$_" ln -sT ${index-html} index.html + ln -sT ${robotsTXT} robots.txt popd mkdir $out/static && pushd "$_" -- cgit v1.2.3