diff --git a/hc/front/views.py b/hc/front/views.py index a41af575..ca7bc55c 100644 --- a/hc/front/views.py +++ b/hc/front/views.py @@ -283,6 +283,7 @@ def serve_doc(request, doc="introduction"): "section": "home", "section": doc, "content": content, + "first_line": content.split("\n")[0], } return render(request, "front/docs_single.html", ctx) diff --git a/templates/docs/http_api.html b/templates/docs/http_api.html index ab537cea..40625c65 100644 --- a/templates/docs/http_api.html +++ b/templates/docs/http_api.html @@ -53,15 +53,15 @@ minimizes the delay from your monitored service failing to you receiving an aler -
HTTP/1.1 200 OK
-Server: nginx
-Date: Wed, 29 Jan 2020 09:58:23 GMT
-Content-Type: text/plain; charset=utf-8
-Content-Length: 2
-Connection: close
-Access-Control-Allow-Origin: *
-
-OK
+
HTTP/1.1 200 OK
+Server: nginx
+Date: Wed, 29 Jan 2020 09:58:23 GMT
+Content-Type: text/plain; charset=utf-8
+Content-Length: 2
+Connection: close
+Access-Control-Allow-Origin: *
+
+OK
 
@@ -82,13 +82,13 @@ optional but enables a few extra features:

-
HTTP/1.1 200 OK
-Server: nginx
-Date: Wed, 29 Jan 2020 09:58:23 GMT
-Content-Type: text/plain; charset=utf-8
-Content-Length: 2
-Connection: close
-Access-Control-Allow-Origin: *
+
HTTP/1.1 200 OK
+Server: nginx
+Date: Wed, 29 Jan 2020 09:58:23 GMT
+Content-Type: text/plain; charset=utf-8
+Content-Length: 2
+Connection: close
+Access-Control-Allow-Origin: *
 
-OK
+OK
 
\ No newline at end of file diff --git a/templates/docs/http_api.md b/templates/docs/http_api.md index 015b90c5..9bb86695 100644 --- a/templates/docs/http_api.md +++ b/templates/docs/http_api.md @@ -63,7 +63,7 @@ GET /5bf66975-d4c7-4bf5-bcc8-b8d8a82ea278/fail HTTP/1.0 Host: hc-ping.com ``` -``` +```http HTTP/1.1 200 OK Server: nginx Date: Wed, 29 Jan 2020 09:58:23 GMT @@ -94,7 +94,7 @@ GET /5bf66975-d4c7-4bf5-bcc8-b8d8a82ea278/start HTTP/1.0 Host: hc-ping.com ``` -``` +```http HTTP/1.1 200 OK Server: nginx Date: Wed, 29 Jan 2020 09:58:23 GMT diff --git a/templates/docs/introduction.html b/templates/docs/introduction.html index 22cbb40b..cb6bb06c 100644 --- a/templates/docs/introduction.html +++ b/templates/docs/introduction.html @@ -1,4 +1,4 @@ -

SITE_NAME

+

SITE_NAME Documentation

SITE_NAME is a service for monitoring cron jobs and similar periodic processes: