From 9fd714eef33f14e5bde503cc00d710a6ff08549e Mon Sep 17 00:00:00 2001 From: tiyn Date: Mon, 22 Apr 2024 06:14:32 +0200 Subject: [PATCH] added robots --- src/app.py | 4 ++++ src/templates/robots.txt | 2 ++ 2 files changed, 6 insertions(+) create mode 100644 src/templates/robots.txt diff --git a/src/app.py b/src/app.py index 60c1495..9e1baf6 100644 --- a/src/app.py +++ b/src/app.py @@ -121,6 +121,10 @@ def entry(path): def feed_re(): return redirect(url_for("feed")) +@app.route("/robots.txt") +def robots(): + return render_template("robots.txt") + @app.route("/feed") def feed(): diff --git a/src/templates/robots.txt b/src/templates/robots.txt new file mode 100644 index 0000000..aaf93aa --- /dev/null +++ b/src/templates/robots.txt @@ -0,0 +1,2 @@ +User-agent: * +Disallow: /static/