Some shuffling of text, and a `-wiki' for all wiki links.

This commit is contained in:
Eli Barzilay 2013-02-12 06:45:30 -05:00
parent 4f13b3f1d5
commit 2f4183242e
3 changed files with 23 additions and 20 deletions

View File

@ -2,7 +2,10 @@
(require scribble/html) (require scribble/html)
(define-syntax-rule (define* id E) (begin (define id E) (provide id))) (define-syntax define*
(syntax-rules ()
[(_ (id . xs) E ...) (begin (define (id . xs) E ...) (provide id))]
[(_ id E) (begin (define id E) (provide id))]))
(define ((make-link url . text) . alternate) (define ((make-link url . text) . alternate)
(a href: url (if (null? alternate) text alternate))) (a href: url (if (null? alternate) text alternate)))
@ -47,15 +50,15 @@
(define* -bootstrap @make-link["http://www.bootstrapworld.org/"]{Bootstrap}) (define* -bootstrap @make-link["http://www.bootstrapworld.org/"]{Bootstrap})
(provide -rcon) (define* (-rcon [year #f] . text)
(define (-rcon #:year [year #f] (define years '(2012 2011))
[body (if year (a href: (list "http://con.racket-lang.org/"
(format "~a" year) (and year (not (eq? year (car years))) (list year "/")))
"RacketCon")]) (cond [(pair? text) text]
(make-link (string-append [(not year) "RacketCon"]
"http://con.racket-lang.org/" [else year])))
(case year
[(2011) "2011/"] (define* (-wiki [page #f] . text)
[(#f 2012) ""] (a href: (list "https://github.com/plt/racket/wiki"
[else (error 'rcon "unknown year: ~e" year)])) (and page (list "/" (regexp-replace #rx" " page "-"))))
body)) (if (null? text) (or page "Racket wiki") text)))

View File

@ -14,17 +14,17 @@
@mailing-lists-quick @mailing-lists-quick
@irc-quick @irc-quick
@parlist[@strong{RacketCon} @parlist[@strong{RacketCon}
@text{@-rcon{RacketCon} is our annual conference: @-rcon[#:year 2012] and @-rcon[#:year 2011].}] @text{@-rcon[] is our annual conference:
@parlist[@strong{Wiki} @-rcon[2012] and @-rcon[2011].}]
@text{@a[href: "https://github.com/plt/racket/wiki"]{Wiki Main Page}, including:}
@text{@a[href: "https://github.com/plt/racket/wiki/Intro-Projects"]{Introductory projects} Find projects to help contribute to Racket.}
@text{@a[href: "https://github.com/plt/racket/wiki/Videos"]{Videos} Watch tutorials, interviews, and more.}
]
@parlist[@strong{PLT Design Inc.} @parlist[@strong{PLT Design Inc.}
@text{@blog announcements, helpful hints, and thoughtful rants.} @text{@blog announcements, helpful hints, and thoughtful rants.}
@text{@a[href: "http://twitter.com/#!/racketlang"]{Twitter} @text{@a[href: "http://twitter.com/#!/racketlang"]{Twitter}
random Racket bits.} random Racket bits.}
@text{@people the people behind Racket.}] @text{@people the people behind Racket.}]
@parlist[@strong{Wiki}
@text{@-wiki[#f]{Wiki pages}, including:}
@text{@-wiki{Intro Projects} Find a project to contribute,}
@text{@-wiki{Videos} Watch tutorials, interviews, and more.}]
@parlist[@strong{Development} @parlist[@strong{Development}
@text{@git (also available on @text{@git (also available on
@a[href: "http://github.com/plt/racket/"]{GitHub}).} @a[href: "http://github.com/plt/racket/"]{GitHub}).}

View File

@ -16,7 +16,7 @@
programming.”} programming.”}
@text{@-plai a textbook on programming languages.}] @text{@-plai a textbook on programming languages.}]
@parlist[@strong{Videos} @parlist[@strong{Videos}
@text{See the @a[href: "https://github.com/plt/racket/wiki/Videos"]{videos page at the Racket wiki}.}] @text{See the @-wiki["Videos"] page at the @|-wiki|.}]
@parlist[ @parlist[
@strong{Outreach} @strong{Outreach}
@text{@-pbd a workshop to train teachers using @-htdp in the @text{@-pbd a workshop to train teachers using @-htdp in the