Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
!
site
Commits
2554cf7b
Commit
2554cf7b
authored
May 22, 2022
by
!
Browse files
Allow index page in robots.txt
parent
0037f5f2
Changes
1
Hide whitespace changes
Inline
Side-by-side
mainsite/views.py
View file @
2554cf7b
...
...
@@ -7,7 +7,7 @@ from mainsite.models import Publication, PublicationYear, SiteConfiguration
def
robots_view
(
request
):
""" Robots.txt view """
body
=
"User-Agent: *
\n
Disallow: /
\n
"
body
=
"User-Agent: *
\n
Disallow: /
\
n
Allow: /$
\
n
"
return
HttpResponse
(
body
,
content_type
=
"text/plain"
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment