www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit 55fd8e7fe9a4e17d0458f6783620ab14bd06f23f
parent 5c2efaf5ba85362ea0f1ee8e968fc6d4551ff362
Author: Matthew Flatt <mflatt@racket-lang.org>
Date:   Sat,  6 Jul 2013 05:50:03 -0600

snapshot management: add "current" link

original commit: 888ec4dae874811ad0e35299177c659e2bb53e4d

Diffstat:
Mpkgs/distro-build/manage-snapshots.rkt | 9+++++++++
1 file changed, 9 insertions(+), 0 deletions(-)

diff --git a/pkgs/distro-build/manage-snapshots.rkt b/pkgs/distro-build/manage-snapshots.rkt @@ -26,6 +26,12 @@ (define snapshots-dir (build-path site-dir 'up)) +(define link-file (build-path snapshots-dir "current")) + +(when (link-exists? link-file) + (printf "Removing old \"current\" link\n") + (delete-file link-file)) + (define snapshots (for/list ([p (in-list (directory-list snapshots-dir))] #:when (directory-exists? (build-path snapshots-dir p))) (path-element->string p))) @@ -50,3 +56,6 @@ (a ((href ,(string-append current-snapshot "/index.html"))) ,current-snapshot)))) + +(printf "Creating \"current\" link\n") +(make-file-or-directory-link current-snapshot link-file)