Compare commits

...

9 Commits

Author SHA1 Message Date
Case Duckworth b9fa8a92e1 Change style : center content 2021-02-06 16:58:26 -06:00
Case Duckworth 0c96e954cc Move dogs' paragraphs to before pictures 2021-02-06 16:58:15 -06:00
Case Duckworth 665efb7acd Fix links 2021-02-06 16:57:58 -06:00
Case Duckworth 5a0dc9a4f7 Move tests to their own folder 2021-02-06 16:57:12 -06:00
Case Duckworth 1d2622ec41 Add `shatom' to submodules 2021-02-06 16:56:44 -06:00
Case Duckworth f4a8a99aa7 Merge branch 'main' of https://tildegit.org/acdw/acdw.net 2021-02-06 16:45:14 -06:00
Case Duckworth 289018f481 Add @@ markup for arbitrary command 2021-02-06 16:44:05 -06:00
Case Duckworth 18cbf10cbf Remove comment 2021-02-06 16:43:49 -06:00
Case Duckworth be601268d4 Move T to functions 2021-02-06 16:43:43 -06:00
8 changed files with 85 additions and 62 deletions

3
.gitmodules vendored
View File

@ -4,3 +4,6 @@
[submodule "hell"]
path = hell
url = https://git.sr.ht/~acdw/hell
[submodule "shatom"]
path = shatom
url = sr:~acdw/shatom

5
G
View File

@ -6,9 +6,9 @@
# symbols (?)
PHI="<span class=phi>&#x2C77;</span>"
# functions
T()(sed q "$1")
# functions
Nav() { # Nav <INDEX> <files...>
idx="$1";shift
if [ "x$idx" != "x-" ]; then
@ -26,8 +26,7 @@ Nav() { # Nav <INDEX> <files...>
done
}
# redefine X for better logging
X()(eval "$(echo "cat<<.";cat;echo;echo .)")
X()(eval "$(P "cat<<.";cat;P;P .)")
. hell/hell

View File

@ -41,6 +41,16 @@ dogs
<li>Ms. Geddum (if you're nasty)</li>
</ul>
</header>
Stormy is our original good girl, our O.G.G.
She is eight years old and still as regal as ever.
She loves car rides, snuggles on the couch, licking faces,
and barking. A lot. She also loves pets from anyone and everyone!
She dislikes people walking near the house (though
if they came inside she'd immediately be their best friend),
thunderstorms, fireworks, and dogs playing in a way
she does not approve of.
<figure>
<img src="https://dogs.acdw.net/stormy-car.jpeg" >
<figcaption>Her Highness in her favorite place to go for rides.</figcaption>
@ -54,29 +64,18 @@ dogs
<figcaption>Sometimes she thinks she is a panda. She is not.</figcaption>
</figure>
<p>
Stormy is our original good girl, our O.G.G.
She is eight years old and still as regal as ever.
She loves car rides, snuggles on the couch, licking faces,
and barking. A lot. She also loves pets from anyone and everyone!
She dislikes people walking near the house (though
if they came inside she'd immediately be their best friend),
thunderstorms, fireworks, and dogs playing in a way
she does not approve of.
</p>
<figure>
<img alt="Stormy on the couch making a dumb face."
src="stormy-couch-derp.jpg"/>
src="https://dogs.acdw.net/stormy-couch-derp.jpg"/>
<img alt="Stormy smiling on the couch."
src="stormy-couch-smile-alone.jpg" />
src="https://dogs.acdw.net/stormy-couch-smile-alone.jpg" />
<figcaption>
Stormy makes a dumb face most of the time.</figcaption>
</figure>
<figure>
<img alt="Stormy clipping her nails with her teeth."
src="stormy-toenail-cronch.jpg"/>
src="https://dogs.acdw.net/stormy-toenail-cronch.jpg"/>
<figcaption>She also clips her own nails.</figcaption>
</figure>
@ -91,6 +90,17 @@ dogs
<li>Stelth Fightor</li>
</ul>
</header>
Stella is our foster-fail.
We got her about three years ago and she is three and a half.
She really likes to run and jump and run some more.
She also likes playing, trying to eat the water hose,
being kind of a jerk to her big sister,
lots and lots of pets, and she gives the sweetest little kisses
ever. She dislikes strangers (though she's getting better!),
the vacuum cleaner, weird balloons, people walking on the porch,
and squirrels -- or she wants to eat those. Could be either one.
<figure>
<img src="https://dogs.acdw.net/stella-bed.jpeg" >
<figcaption>Stella loves to lounge and relax.</figcaption>
@ -100,45 +110,33 @@ dogs
<figcaption>But she also loves a good strenuous run.</figcaption>
</figure>
<p>
Stella is our foster-fail.
We got her about three years ago and she is three and a half.
She really likes to run and jump and run some more.
She also likes playing, trying to eat the water hose,
being kind of a jerk to her big sister,
lots and lots of pets, and she gives the sweetest little kisses
ever. She dislikes strangers (though she's getting better!),
the vacuum cleaner, weird balloons, people walking on the porch,
and squirrels -- or she wants to eat those. Could be either one.
</p>
<figure>
<img alt="Stella looking up and to the left."
src="stella-attention.jpg"/>
src="https://dogs.acdw.net/stella-attention.jpg"/>
<figcaption>Stella pays attention</figcaption>
</figure>
<figure>
<img alt="Stella sleeping on a blue and yellow blanket."
src="stella-blanket-sleep.jpg"/>
src="https://dogs.acdw.net/stella-blanket-sleep.jpg"/>
<figcaption>Stella sleeps</figcaption>
</figure>
<figure>
<img alt="Stella sleeping, tongue out, on a couch."
src="stella-blep-out.jpg"/>
src="https://dogs.acdw.net/stella-blep-out.jpg"/>
<figcaption>Stella's tongue is too big for her mouth.</figcaption>
</figure>
<figure>
<img alt="Closeup of Stella under her jaw."
src="stella-closeup-neckfolds.jpg"/>
src="https://dogs.acdw.net/stella-closeup-neckfolds.jpg"/>
<figcaption>Stella has neck folds.</figcaption>
</figure>
<figure>
<img alt="Stella on the couch, feet out, asleep."
src="stella-couch-sleep-feet.jpg"/>
src="https://dogs.acdw.net/stella-couch-sleep-feet.jpg"/>
<figcaption>Stella sleeps like this.</figcaption>
</figure>

40
L
View File

@ -1,23 +1,27 @@
<!DOCTYPE html>
<head>
<meta charset=utf-8>
<title>$(T $F)</title>
<link rel=stylesheet type=text/css href=S/acdw.css>
<meta charset=utf-8>
<title>$(T $F)</title>
<link rel=stylesheet type=text/css href=S/acdw.css>
</head>
<body>
<header>
$(Nav I/index.html I/*)
</header>
<main>
<h1 class="pagetitle">$(T $F)</h1>
$(sed 1d $F|awk -vRS= -fR|X)
<div id=main-last-child>
<!--hi mom!-->
</div>
</main>
<footer>
<span class=phi>&copy; 2017&ndash;$(date +%Y) Case Duckworth</span>
$(Nav - I/.??*)
<a href="${ROOT}/.atom.xml">feed</a>
</footer>
<header>
<div class=mainwidth>
$(Nav I/index.html I/*)
</div>
</header>
<main class=mainwidth>
<h1 class="pagetitle">$(T $F)</h1>
$(sed 1d $F|awk -vRS= -fR|X)
<div id=main-last-child>
<!--hi mom!-->
</div>
</main>
<footer>
<div class=mainwidth>
<span class=phi>&copy; 2017&ndash;$(date +%Y) Case Duckworth</span>
$(Nav - I/.??*)
<a href="${ROOT}/.atom.xml">feed</a>
</div>
</footer>
</body>

27
R
View File

@ -7,37 +7,50 @@ BEGIN {
_el=" el "; _defel="p"
}
function start(el) {
function start(el, not_html) { # start an element
el = (el ? el : _defel)
pre_el = (not_html ? "" : _el)
split(el, el_a, " ")
lvl[++i] = el_a[1]
return "$(<<" _end i lvl[i] _el el "\n"
return "$(<<" _end i lvl[i] pre_el el "\n"
}
function end() {
function end() { # end an element
return "\n" _end i lvl[i--] "\n)"
}
function wrap(par) {
function wrap(par) { # wrap a non-delimited paragraph with <p>
if (par !~ /^<.*>$/)
return start() par end()
else
return par
}
/^@[^()]/ {
/^@[^@()]/ { # html element
$1 = start(substr($1, 2))
sub(/\n?$/, end())
print
next
}
/^@\(/ {
/^@@[^()]/ { # arbitrary command
$1 = start(substr($1, 3))
sub(/\n?$/, end())
print
next
}
/^@\(/ { # nested element begin
print start(substr($1, 3))
$1=""; $0=$0
}
/@\)$/ {
/^@@\(/ { # nested arbitrary command begin
print start(substr($1, 4))
$1=""; $0=$0
}
/@@?\)$/ { # nested element end
nf=$NF; NF--; $0=$0; print
if ($0) {
print wrap($0)

View File

@ -6,10 +6,15 @@ html,body{
margin:0;
}
.mainwidth {
max-width: 46rem;
margin: 0 auto;
}
main{
max-width:70ch;
margin: 2em 0;
padding:0 1ch;
/* max-width:70ch; */
/* margin: 0; */
padding:2em 1ch;
background: white;
}

1
shatom Submodule

@ -0,0 +1 @@
Subproject commit 49f6fc03a42e7b875f691f7476e956923f731a62

View File