Commit 3679d577 authored by Ludovic Courtès's avatar Ludovic Courtès

Change home page, move blog to "/blog".

* getting-started.md: Add title, link to /blog.
* guix-hpc.scm (image-url, css-url): Add leading /.
(post-url): Add "/blog".
(base-layout): Add "Blog", change feed URL.
(about-page): Remove.
(static-pages)[markdown-page]: New procedure.
Use it.  Add "getting-started".
* nginx-locations.conf: Add redirects.
parent 11107d51
title: Reproducible software deployment for high-performance computing.
---
[GNU Guix](https://www.gnu.org/software/guix/) is a *transactional* [GNU Guix](https://www.gnu.org/software/guix/) is a *transactional*
package manager, with support for *per-user* package installations. package manager, with support for *per-user* package installations.
Users can install their own packages without interfering with each Users can install their own packages without interfering with each
...@@ -188,6 +191,8 @@ just ...@@ -188,6 +191,8 @@ just
# Joining # Joining
Learn more about on-going Guix-HPC developments [on our blog](/blog).
[Guix-HPC](/about.html) [Guix-HPC](/about.html)
and [GNU Guix](https://www.gnu.org/software/guix/) are collaborative and [GNU Guix](https://www.gnu.org/software/guix/) are collaborative
efforts. You are welcome to [join](/about.html)! efforts. You are welcome to [join](/about.html)!
...@@ -23,14 +23,14 @@ ...@@ -23,14 +23,14 @@
(string-concatenate (cons "" location))) (string-concatenate (cons "" location)))
(define (image-url location) (define (image-url location)
(base-url "static/images" location)) (base-url "/static/images" location))
(define (css-url location) (define (css-url location)
(base-url "static/css" location)) (base-url "/static/css" location))
(define (post-url post site) (define (post-url post site)
"Return the URL of POST, a Haunt blog post, for SITE." "Return the URL of POST, a Haunt blog post, for SITE."
(base-url (site-post-slug site post) ".html")) (base-url "/blog/" (site-post-slug site post) ".html"))
(define* (base-layout body #:key (title "Guix-HPC")) (define* (base-layout body #:key (title "Guix-HPC"))
...@@ -58,9 +58,11 @@ ...@@ -58,9 +58,11 @@
(div (@ (id "menubar") (div (@ (id "menubar")
(class "width-control")) (class "width-control"))
(ul (ul
(li (a (@ (href ,(base-url "about.html"))) (li (a (@ (href ,(base-url "/about.html")))
"About")) "About"))
(li (a (@ (href ,(base-url "/news/feed.xml"))) (li (a (@ (href ,(base-url "/blog")))
"Blog"))
(li (a (@ (href ,(base-url "/blog/feed.xml")))
(img (@ (alt "Atom feed") (img (@ (alt "Atom feed")
(src ,(image-url "/feed.png")))))))) (src ,(image-url "/feed.png"))))))))
...@@ -103,8 +105,10 @@ representation." ...@@ -103,8 +105,10 @@ representation."
#:title (string-append "Guix-HPC — " #:title (string-append "Guix-HPC — "
(assoc-ref meta 'title))))) (assoc-ref meta 'title)))))
(define (about-page)
(read-markdown-page "about.md"))
(define (static-pages) (define (static-pages)
(list (make-page "about.html" (about-page) sxml->html))) (define (markdown-page html md)
(make-page html (read-markdown-page md)
sxml->html))
(list (markdown-page "about.html" "about.md")
(markdown-page "index.html" "getting-started.md")))
...@@ -72,11 +72,12 @@ ...@@ -72,11 +72,12 @@
(email . "guix-devel@gnu.org")) (email . "guix-devel@gnu.org"))
#:readers (list commonmark-reader) #:readers (list commonmark-reader)
#:builders #:builders
(cons* (blog #:theme %hpc-haunt-theme) (cons* (blog #:theme %hpc-haunt-theme
#:prefix "blog")
;; Apparently the <link> tags of Atom entries must be absolute URLs, ;; Apparently the <link> tags of Atom entries must be absolute URLs,
;; hence this #:blog-prefix. ;; hence this #:blog-prefix.
(atom-feed #:file-name "news/feed.xml" (atom-feed #:file-name "blog/feed.xml"
#:blog-prefix "https://hpc.guixsd.org") #:blog-prefix "https://hpc.guixsd.org")
(static-directory "static") (static-directory "static")
......
...@@ -6,3 +6,11 @@ location / { ...@@ -6,3 +6,11 @@ location / {
location /.well-known { location /.well-known {
root /var/www; root /var/www;
} }
# Redirects for old URLs.
location = /guix-hpc-debut.html {
return 301 /blog/guix-hpc-debut.html;
}
location = /feed.xml {
return 301 /blog/feed.xml;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment