add ability to parse atom.txt with bound values
This commit is contained in:
parent
92f20f47a0
commit
d02be1f2a4
4 changed files with 53 additions and 51 deletions
|
@ -13,6 +13,9 @@
|
||||||
web-server/dispatchers/filesystem-map
|
web-server/dispatchers/filesystem-map
|
||||||
web-server/http)
|
web-server/http)
|
||||||
|
|
||||||
|
(define-namespace-anchor anc)
|
||||||
|
(define ns (namespace-anchor->namespace anc))
|
||||||
|
|
||||||
|
|
||||||
(define (html-response content)
|
(define (html-response content)
|
||||||
(response/full
|
(response/full
|
||||||
|
@ -116,15 +119,8 @@
|
||||||
[homepage "https://sorrel.dev"])
|
[homepage "https://sorrel.dev"])
|
||||||
;; hard coding for now because reader can't be escaped
|
;; hard coding for now because reader can't be escaped
|
||||||
(define content
|
(define content
|
||||||
`(feed
|
((eval (read (open-input-file "source/atom.txt")) ns)
|
||||||
((xmlns "http://www.w3.org/2005/Atom"))
|
feed-ref update-time homepage))
|
||||||
(title "λ.sorrel.dev")
|
|
||||||
(link ((rel "self")
|
|
||||||
(href ,feed-ref)))
|
|
||||||
(updated ,update-time)
|
|
||||||
(author
|
|
||||||
(name "sorrel"))
|
|
||||||
(id ,homepage)))
|
|
||||||
(xml-response
|
(xml-response
|
||||||
(string->bytes/utf-8 (string-append "<?xml version=\"1.0\" encoding=\"utf-8\"?>"
|
(string->bytes/utf-8 (string-append "<?xml version=\"1.0\" encoding=\"utf-8\"?>"
|
||||||
(xexpr->string content))))))
|
(xexpr->string content))))))
|
||||||
|
|
|
@ -1,26 +1,11 @@
|
||||||
(main
|
(main
|
||||||
(p "what do you want to know?")
|
(p "what do you want to know?")
|
||||||
(h1 "about sorrel")
|
(section
|
||||||
(p "i'm a gay lil nerd who's learning everyday about community, and ecology,
|
(h1 "about sorrel")
|
||||||
|
(p "i'm a gay lil nerd who's learning everyday about community, and ecology,
|
||||||
and computer; and trying hard to be good for the world with my gay lil
|
and computer; and trying hard to be good for the world with my gay lil
|
||||||
friends.")
|
friends.")
|
||||||
(section
|
(p "i was named after "
|
||||||
(h2 "contact")
|
|
||||||
(p "- e - m- "
|
|
||||||
(span " a - i ")
|
|
||||||
(span " -l [ at ")
|
|
||||||
(span "] s - o- ")
|
|
||||||
(span "r - r- e - l [ d o")
|
|
||||||
(span "t ] d -e")
|
|
||||||
(span "-v is a good place to do the email"))
|
|
||||||
(p
|
|
||||||
"i have avoided 'online' for a long time, but i'm getting hip to it. i'll
|
|
||||||
add some more socials here for to socially network in the future,
|
|
||||||
promise."))
|
|
||||||
(section
|
|
||||||
(h2 "a bio or smth")
|
|
||||||
(p
|
|
||||||
"i am a little bug that was named after "
|
|
||||||
(a ((href "https://plants.usda.gov/home/plantProfile?symbol=OXOR"))
|
(a ((href "https://plants.usda.gov/home/plantProfile?symbol=OXOR"))
|
||||||
"a plant called sorrel")
|
"a plant called sorrel")
|
||||||
" and i live in the mountains of southern appalachia on "
|
" and i live in the mountains of southern appalachia on "
|
||||||
|
@ -60,6 +45,7 @@
|
||||||
;; mmt bullet
|
;; mmt bullet
|
||||||
(li (p "mmt, but make it anarchist "
|
(li (p "mmt, but make it anarchist "
|
||||||
(small "and get rid of all that \"sovereignty\" stuff, ew")))
|
(small "and get rid of all that \"sovereignty\" stuff, ew")))
|
||||||
|
;; nd bullet
|
||||||
(li (p "the autistic-contiguous position: object-relations theory or gay
|
(li (p "the autistic-contiguous position: object-relations theory or gay
|
||||||
sex act? "
|
sex act? "
|
||||||
(span
|
(span
|
||||||
|
@ -70,20 +56,41 @@
|
||||||
(hx-target "closest span.hx-target")
|
(hx-target "closest span.hx-target")
|
||||||
(hx-swap "innerHTML"))
|
(hx-swap "innerHTML"))
|
||||||
"a ~type~ of experience")))))
|
"a ~type~ of experience")))))
|
||||||
(li (p "being trans and gay"))
|
;; queer bullet
|
||||||
(li (p "א ⃝"))))
|
(li (p "she's a gay trans lady, harold"))
|
||||||
|
;; art bullet
|
||||||
|
(li (p "i used to make a lot more visual art than i do these days. some
|
||||||
|
sort of smth'll wind up here at some point."))))
|
||||||
|
;; contact section
|
||||||
|
(section
|
||||||
|
(h2 "contact")
|
||||||
|
(p "- e - m- "
|
||||||
|
(span " a - i ")
|
||||||
|
(span " -l [ at ")
|
||||||
|
(span "] s - o- ")
|
||||||
|
(span "r - r- e - l [ d o")
|
||||||
|
(span "t ] d -e")
|
||||||
|
(span "-v is a good place to do the email"))
|
||||||
|
(p
|
||||||
|
"i have avoided 'online' for a long time, but i'm getting hip to it. i'll
|
||||||
|
add some more socials here for to socially network in the future,
|
||||||
|
promise."))
|
||||||
|
;; getting earnest section
|
||||||
(section
|
(section
|
||||||
(h2 "a very earnest disclaimer")
|
(h2 "a very earnest disclaimer")
|
||||||
(p
|
(p
|
||||||
"i like to talk about computation with ppl! but it is important for me that
|
"i like to talk about computation with ppl! but it is important for me that
|
||||||
you know: i am new to all this! i did not think software was ^for me^ and
|
you know: i am new to all this! i did not think computers or software were
|
||||||
then i learned some webdev and now i am down the rabbit hole.")
|
^for me^ and then i had to get good at spreadsheets at my first email-factory
|
||||||
|
job and then i got curious about webdev and now i have reached terminal
|
||||||
|
velocity down a very λ.particular.rabbit[hole]")
|
||||||
(p
|
(p
|
||||||
"i'm not very good at many things. i don't even have a math education or.
|
"i'm not very good at many things. i don't even have a math education or a
|
||||||
have you ever met someone who *is* good at all this stuff?")
|
degree in anything. have you ever met someone who *is* good at _all_ ^this^
|
||||||
|
~stuff~ ???")
|
||||||
(p
|
(p
|
||||||
"please be patient! with me and with everyone else you talk about things
|
"i like thinking in public, but please be patient! with me and with
|
||||||
you care about with.")
|
everyone else you talk about things you care about with.")
|
||||||
(p "let's hold our strong opinions loosely!")
|
(p "let's hold our strong opinions loosely!")
|
||||||
(p "and first assume good faith from each other!")
|
(p "and first assume good faith from each other!")
|
||||||
(br)
|
(br)
|
||||||
|
|
|
@ -1,16 +1,13 @@
|
||||||
;; required on update
|
(lambda (feed-ref update-time homepage)
|
||||||
;; -- (let (feed-ref "https://URI/atom")
|
`(feed
|
||||||
;; (update-time
|
((xmlns "http://www.w3.org/2005/Atom"))
|
||||||
|
(title "λ.sorrel.dev")
|
||||||
(feed
|
(link ((rel "self")
|
||||||
((xmlns "http://www.w3.org/2005/Atom"))
|
(href ,feed-ref)))
|
||||||
(title "λ.sorrel.dev")
|
(updated ,update-time)
|
||||||
(link ((rel "self")
|
(author
|
||||||
(href ,feed-ref)))
|
(name "sorrel"))
|
||||||
(updated ,update-time)
|
(id ,homepage)
|
||||||
(author
|
|
||||||
(name "sorrel"))
|
|
||||||
(id ,homepage)
|
|
||||||
|
|
||||||
; ,(map
|
; ,(map
|
||||||
; (lambda (item)
|
; (lambda (item)
|
||||||
|
@ -25,4 +22,4 @@
|
||||||
; (categories item))
|
; (categories item))
|
||||||
; (updated ,(updated item)))
|
; (updated ,(updated item)))
|
||||||
; items))
|
; items))
|
||||||
)
|
))
|
|
@ -64,4 +64,6 @@
|
||||||
(hx-get "/hx/settleds")
|
(hx-get "/hx/settleds")
|
||||||
(hx-target "main")
|
(hx-target "main")
|
||||||
(hx-swap "innerHTML"))
|
(hx-swap "innerHTML"))
|
||||||
"\"settled\" thoughts (projects built/in progress)")))
|
"\"settled\" thoughts (projects built/in progress)")
|
||||||
|
(a ((href "/feed.atom"))
|
||||||
|
"þͤ olde rss")))
|
||||||
|
|
Loading…
Reference in a new issue