Compare commits

..

No commits in common. "b5a8bf3d6b0718c010912c62f7860acc701c74e2" and "017f26545f39e7f7a501e3c13ff513816ee06be8" have entirely different histories.

30 changed files with 413 additions and 239 deletions

1
.gitignore vendored
View File

@ -1 +0,0 @@
O

24
Dp
View File

@ -1,24 +0,0 @@
{
"name": "breadpunk.club",
"url": "https://breadpunk.club",
"signup_url": "https://breadpunk.club/join",
"user_count": "$(getent group|grep '^bakers:'|cut -d: -f4|tr , '\n'|wc -l)",
"want_users": true,
"admin_email": "breadpunk@acdw.net",
"description": "We are a shared Unix computer focused on bread: baking it, eating it, using it as fiat currency in the event of a cataclysm, that sort of thing.",
"users": [
$(lastuser="$(getent group|grep '^bakers:'|cut -d: -f4|tr , '\n'|tail -n1)"
for user in $(getent group|grep '^bakers:'|cut -d: -f4|tr , '\n'); do
cat <<-ENDUSER
{
"username": "$user",
"title": "$(awk '/<title>/{gsub("</?title>","");
sub(/^[ ]/,"");sub(/[ ]$/,"");
print;}' /home/$user/public_html/index.html)",
"mtime": "$(stat -c %Y /home/$user/public_html/index.html)"
}$( [ "$lastuser" = "$user" ] || printf ',' )
ENDUSER
done
)
]
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 2.1 KiB

View File

@ -1,54 +1,23 @@
* { position: relative; }
body,
html {
width: 100%;
min-height: 100vh;
margin: 0;
padding: 0;
font: 18px/1.3 CMUTypewriterTextRegular, monospace;
background-color: wheat;
background: url("/S/bread.png") repeat;
font: 18px/1.3 monospace;
background: url("/S/bread.png") repeat, wheat;
display: flex;
flex-flow: column nowrap;
align-items: center;
}
#main {
max-width: 40em;
padding: 1em;
main {
max-width: 70ch;
padding: 2ch;
margin: auto;
background: white;
}
#footer {
margin-top: 1em;
text-align: center;
}
#header,
#footer {
footer {
background: white;
width: 100%;
}
#header {
margin-bottom: 1em;
}
#header .nav {
z-index: 100;
background: white;
padding-right: 1em;
}
#header * {
margin: 0;
padding: 0;
display: inline;
}
.nav li:after {
content: " (#) ";
}
.subtitle {
font-style: italic;
}
pre,
code {
font: 14px/1.1 monospace;
background: #ddd;
}
#users {
text-align: right;
position: absolute;
right: 0;
text-align: right;
padding: 1ch;
}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 759 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 318 B

View File

@ -1,19 +0,0 @@
title docs
$([ -d "$BREADDOCS" ] &&
for F in $(find "$BREADDOCS" -path "$BREADDOCS/.git" -prune -o -type f -print); do
case "$F" in
*manifesto.md) ;;
*man*) continue;;
esac
l "doc: $F"
dir="$UNKO/docs/$(NN)"
rm -rf "$dir"
mkdir -p "$dir"
X "$UNKL" > "$dir/index.html"
cat <<ENDOFITEM
- [$(M title)](/docs/$(NN))
ENDOFITEM
done
)

View File

@ -1,25 +1,9 @@
title BREADPUNK
subtitle baking the net since 2020
Hello, and welcome to **breadpunk.club**.
Hello, and welcome to breadpunk.club.
We are a shared Unix computer focused on bread:
baking it,
eating it,
using it as fiat currency in the event of a cataclysm,
that sort of thing.
we're also dedicated to the ideas outlined
in our [manifesto](/docs/manifesto),
namely *anti-commoditization*,
*self-reliance*,
and *radical cooperation*.
$(for s in "$UNKI/index_sections"/*; do
cat <<-ENDSECTION
<div class="section" id="$(M id "$s")">
<div class="header">$(M title "$s" |wrapstr h1)$(M subtitle "$s" |wrapstr p class=subtitle)
</div>$(C "$s" | X | $DISCOUNT)
</div>
ENDSECTION
done
)

View File

@ -1,9 +0,0 @@
id joining
title join us!
we're still a pretty small server:
we only have $(ls /home|wc -l) bakers!
we're all pretty friendly and would love to have you along.
check out our [joining page](/join)
to apply for membership to breadpunk.club.

View File

@ -1,11 +0,0 @@
title news
id news
<ul>
$(for art in $(find "$BREADNEWS" -path "$BREADNEWS/.git" -prune -o -type f -print | sort -nr|head -n3); do
cat <<-ENDOFARTICLE
<li>$(M date "$art"|defstr $(NN "$art")|wrapstr span class="time")
<a href="/news#$(NN "$art")">$(M title "$art")</a></li>
ENDOFARTICLE
done)
</ul>

View File

@ -1,14 +0,0 @@
title bakers
subtitle in order of most recent bake
id bakers
<ul>
$(for u in $(
find /home/*/public_html -maxdepth 0 -printf '%T@\t%p\n'|
sort -nr |
cut -f2- |
sed 's,/home/\(.*\)/public_html,\1,')
do
p "<li><a href=\"/~$u\">~$u</a></li>"
done)
</ul>

View File

@ -1,7 +1,8 @@
title history
id history
breadpunk.club was envisioned by some folx over at
[tilde.town](https://tilde.town) as a new tilde server,
<tilde.town> as a new tilde server,
where we could talk about bread all day.
for more information, see our [manifesto](/manifesto/).

View File

@ -0,0 +1,11 @@
id joining
title how to join
to become a baker,
just send an email to [breadw](/~breadw/)
with your SSH key,
desired username (must be bread-oriented),
realname (can be your "normal" username),
and what shell you'd like to use (we have sh, bash, and zsh).
we'll see you around the bakery!

View File

@ -1,16 +0,0 @@
title joining
breadpunk.club is open to anyone. it's suggested that you look at our
[manifesto](/docs/manifesto) and make sure it's something you're interested in,
as well as our [code of conduct](/docs/code-of-conduct) to make sure you agree
with our terms.
to become a baker, just send an email to [breadw](/~breadw) with your SSH key (attached, please!),
desired username (must be bread-oriented), realname (can be your “normal”
username), and what shell youd like to use (we have
$(cat /etc/shells|
awk -F/ '/^#/{next}/tmux$/{next}/screen$/{next}
{if (!match(shs, $NF)) shs = (shs ? shs", " : shs) $NF}
END{sub(/[^,]+$/," and&",shs);print shs}')).
well see you around the bakery!

48
I/manifesto.md Normal file
View File

@ -0,0 +1,48 @@
title manifesto
>%epigraph%
>Man cannot live on bread alone.
>&mdash; Jesus of Nazareth
>%epigraph%
>They say bread is life.
>&mdash; Ronny Cammareri of Brooklyn
Bread was invented tens of thousands of years ago,
probably by someone drunk because they had the munchies.
It's been made continuously since then
by people of varying degrees of sobriety
and to varying degrees of success.
For nearly its entire history,
bread has been made using stale dough from earlier bread,
or from a fresh-made pool of fermented wheat and water.
It took time,
but it was good,
and we had time.
Of course,
the Market came along,
and with it hunger:
the hunger of the working-class,
who did not have time to
sit and wait for bread.
We invented instant yeast in a lab,
we invented styrofoam bread with no taste
but fast turnaround,
and we called it good.
But we knew not what we did &mdash;
or at least, many of us didn't.
The alphabet, they say, was invented only once.
Bread is invented every time, anew.
It's life itself.
And life is not for sale.
Breadpunk rejects the commoditization of life by market capitalism.
Breadpunk is an attitude that something our ancestors made largely for free
is not something we should be spending money on.
Breadpunk is the idea that we have time again,
that industrialism gives us time to bake bread.
Breadpunk is simple:
**MAKE YOUR OWN DAMN BREAD.**

View File

@ -1,12 +0,0 @@
title news
$(for art in $(find "$BREADNEWS" -path "$BREADNEWS/.git" -prune -o -type f -print | sort -nr); do
l "news: $art"
cat <<-ENDOFARTICLE
<div class="article" id="$(NN "$art")">
<div class="header">$(M title "$art"|wrapstr h1)
$(M date "$art"|wrapstr span class="time")
$(C "$art"|X|$DISCOUNT)
</div>
ENDOFARTICLE
done)

View File

@ -1,10 +0,0 @@
title recipes
$(mkdir "$UNKO/recipes")
<ul>
$(for r in /bread/cookbook/html/*; do
l "recipe: $r"
echo "<li><a href=\"/recipe/$(NN "$r")\">$(NN "$r")</a></li>"
done)
</ul>

68
L
View File

@ -1,40 +1,44 @@
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html lang="en">
<!-- updated $(date) -->
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="description" content="a collaborative bread-positive space">
<meta charset="utf-8" />
<title>$(M title|addstr ' | ')BREADPUNK</title>
<link rel="stylesheet" media="screen" type="text/css"
href="https://fontlibrary.org/face/cmu-typewriter" >
<link rel="stylesheet" type="text/css" href="/S/breadpunk.css" >
<link rel="icon" type="image/png" href="/S/breadpunk.png">
<link rel="stylesheet" type="text/css" href="/S/breadpunk.css" />
</head>
<body>
<div id="header">
<div class="nav">
$(cat header.txt)
$([ "$(N)" = index ] || {
cat <<-ENDHEADER
(#) <a href="/">home</a>
ENDHEADER
<main>
<section id=intro>
<header>
$(M title | wrapstr h1)
$(M subtitle | wrapstr h2)
</header>
$(C|$DISCOUNT)
</section>
$([ -d "$UNKI/$(N)_sections" ] &&
for s in "$UNKI/$(N)_sections"/*; do
cat <<-ENDSECTION
<section>
<header>
$(M title "$s" |wrapstr h1)
$(M subtitle "$s" |wrapstr h2)
</header>
$(C "$s" | $DISCOUNT)
</section>
ENDSECTION
done
)
</main>
<footer>
$([ "$(N)" = index ] && {
p "<marquee>"
sed 's/#.*//' /bread/index-footer.txt
p "</marquee>"
} || {
cat <<-ENDFOOTER
<a href=/>back</a>
ENDFOOTER
})
</div>
<marquee id="users">
$(./update-footer.awk footer.txt | sed 's/#.*//')
</marquee>
</div>
<div id="main">
<div class="header">
$(M title | wrapstr h1)
$(M subtitle | wrapstr p class=subtitle)
$(M author | wrapstr p class=author)
</div>
$(C|X|$DISCOUNT)
</div>
<div id="footer">
</div>
</footer>
</body>
</html>
<!-- vim: ft=unk

View File

@ -1,7 +1,5 @@
# breadpunk.club
DEBUG ?= false
BREADNEWS ?= /bread/news
BREADDOCS ?= /bread/docs
RSYNC_EXCLUDES := \
.well-known \
@ -20,8 +18,7 @@ RSYNC := rsync \
SERVE ?= php -S 127.0.0.1:2733 -t O/
WATCH := I/* I/*/* \
unk lib.sh L *.txt \
$(BREADNEWS)/* $(BREADDOCS)/*
unk lib.sh L
watch:
@echo entr -d -r $(MAKE) _serve
@ -35,7 +32,7 @@ _serve: build
$(SERVE)
publish: build
$(RSYNC) O/ /var/www/breadpunk.club/
$(RSYNC) O/ /var/www/breadpunk.club/
# push: publish
# @test -z "$$(git status --porcelain)" && \
@ -43,6 +40,6 @@ publish: build
# echo "Commit changes!"
build:
DEBUG=$(DEBUG) BREADNEWS=$(BREADNEWS) BREADDOCS=$(BREADDOCS) ./unk
DEBUG=$(DEBUG) ./unk
PHONY: build _serve publish watch

BIN
O/S/bread.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

23
O/S/breadpunk.css Normal file
View File

@ -0,0 +1,23 @@
body,
html {
min-height: 100vh;
margin: 0;
padding: 0;
font: 18px/1.3 monospace;
background: url("/S/bread.png") repeat, wheat;
display: flex;
flex-flow: column nowrap;
align-items: center;
}
main {
max-width: 70ch;
padding: 2ch;
margin: auto;
background: white;
}
footer {
background: white;
width: 100%;
text-align: right;
padding: 1ch;
}

56
O/index.html Normal file
View File

@ -0,0 +1,56 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>BREADPUNK | BREADPUNK</title>
<link rel="stylesheet" type="text/css" href="/S/breadpunk.css" />
</head>
<body>
<main>
<section id=intro>
<header>
<h1>BREADPUNK</h1>
<h2>baking the net since 2020</h2>
</header>
<p>Hello, and welcome to breadpunk.club.
We are a shared Unix computer focused on bread:
baking it,
eating it,
using it as fiat currency in the event of a cataclysm,
that sort of thing.</p>
</section>
<section>
<header>
<h1>history</h1>
</header>
<p>breadpunk.club was envisioned by some folx over at
&lt;tilde.town> as a new tilde server,
where we could talk about bread all day.</p>
<p>for more information, see our <a href="/manifesto/">manifesto</a>.</p>
</section>
<section>
<header>
<h1>how to join</h1>
</header>
<p>to become a baker,
just send an email to <a href="/~breadw/">breadw</a>
with your SSH key,
desired username (must be bread-oriented),
realname (can be your &ldquo;normal&rdquo; username),
and what shell you&rsquo;d like to use (we have sh, bash, and zsh).</p>
<p>we&rsquo;ll see you around the bakery!</p>
</section>
</main>
<footer>
4
bakers;
9
baking now
</footer>
</body>
</html>
<!-- vim: ft=unk
-->

69
O/manifesto/index.html Normal file
View File

@ -0,0 +1,69 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>manifesto | BREADPUNK</title>
<link rel="stylesheet" type="text/css" href="/S/breadpunk.css" />
</head>
<body>
<main>
<section id=intro>
<header>
<h1>manifesto</h1>
</header>
<div class="epigraph"><p>Man cannot live on bread alone.
&mdash; Jesus of Nazareth</p></div>
<div class="epigraph"><p>They say bread is life.
&mdash; Ronny Cammareri of Brooklyn</p></div>
<p>Bread was invented tens of thousands of years ago,
probably by someone drunk because they had the munchies.
It&rsquo;s been made continuously since then
by people of varying degrees of sobriety
and to varying degrees of success.
For nearly its entire history,
bread has been made using stale dough from earlier bread,
or from a fresh-made pool of fermented wheat and water.
It took time,
but it was good,
and we had time.</p>
<p>Of course,
the Market came along,
and with it hunger:
the hunger of the working-class,
who did not have time to
sit and wait for bread.
We invented instant yeast in a lab,
we invented styrofoam bread with no taste
but fast turnaround,
and we called it good.
But we knew not what we did &mdash;
or at least, many of us didn&rsquo;t.</p>
<p>The alphabet, they say, was invented only once.
Bread is invented every time, anew.
It&rsquo;s life itself.
And life is not for sale.</p>
<p>Breadpunk rejects the commoditization of life by market capitalism.
Breadpunk is an attitude that something our ancestors made largely for free
is not something we should be spending money on.
Breadpunk is the idea that we have time again,
that industrialism gives us time to bake bread.</p>
<p>Breadpunk is simple:
<strong>MAKE YOUR OWN DAMN BREAD.</strong></p>
</section>
</main>
<footer>
<a href=/>back</a>
</footer>
</body>
</html>
<!-- vim: ft=unk
-->

66
O_/index.html Normal file
View File

@ -0,0 +1,66 @@
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8>
<title>BREADPUNK</title>
<style>
body,html {
min-height: 100vh;
font: 18px/1.3 monospace;
margin: 0; padding: 0;
}
main {
max-width: 70ch;
padding: 2ch;
margin: auto;
}
</style>
</head>
<body>
<main>
<section id=intro>
<header>
<h1>BREADPUNK</h1>
<h2>baking the net since 2020</h2>
</header>
<p>
Hello, and welcome to breadpunk.club.
We are a shared Unix computer focused on bread:
baking it, eating it,
using it as fiat currency in the event of cataclysm,
that sort of thing.
</p>
</section>
<section id=history>
<h2>history</h2>
<p>breadpunk.club was envisioned by
some folx over at <a href="https://tilde.town">tilde.town</a>
as a new tilde server,
where we could talk about bread all day.
</p>
<p>
for more information, see our
<a href="/manifesto">manifesto</a>.
</p>
</section>
<section id=joining>
<h2>how to join</h2>
<p>to become a baker,
just send an email to <a href="http://breadpunk.club/~breadw">breadw</a>
with your SSH key,
desired username (must include a pun on bread),
realname (can be your "normal" username),
and what shell you'd like (we have sh, bash, zsh).
</p>
<p>we'll see you around the bakery!</p>
</section>
</main>
</body>
</html>

84
O_/manifesto/index.html Normal file
View File

@ -0,0 +1,84 @@
<!DOCTYPE html>
<html>
<head>
<meta charset=utf-8>
<title>BREADPUNK</title>
<style>
body,html {
min-height: 100vh;
font: 18px/1.3 monospace;
margin: 0; padding: 0;
}
main {
max-width: 70ch;
padding: 2ch;
margin: auto;
}
</style>
</head>
<body>
<main>
<h1>BREADPUNK</h1>
<h2>manifesto</h2>
<p class=epigraph>
Man cannot live on bread alone.
&mdash; Jesus of Nazareth
</p>
<p class=epigraph>
They say bread is life.
&mdash; Ronny Cammareri of Brooklyn
</p>
<p>
Bread was invented tens of thousands of years ago,
probably by someone drunk because they had the munchies.
It's been made continuously since then
by people of varying degrees of sobriety
and to varying degrees of success.
For nearly its entire history,
bread has been made using stale dough from earlier bread,
or from a fresh-made pool of fermented wheat and water.
It took time,
but it was good,
and we had time.
</p>
<p>
Of course,
the Market came along,
and with it hunger:
the hunger of the working-class,
who did not have time to
sit and wait for bread.
We invented instant yeast in a lab,
we invented styrofoam bread with no taste
but fast turnaround,
and we called it good.
But we knew not what we did &mdash;
or at least, many of us didn't.
</p>
<p>
The alphabet, they say, was invented only once.
Bread is invented every time, anew.
It's life itself.
And life is not for sale.
</p>
<p>
Breadpunk rejects the commoditization of life by market capitalism.
Breadpunk is an attitude that something our ancestors made largely for free
is not something we should be spending money on.
Breadpunk is the idea that we have time again,
that industrialism gives us time to bake bread.
</p>
<p>
Breadpunk is simple:
<strong>MAKE YOUR OWN DAMN BREAD.</strong>
</p>
</main>
</body>
</html>

View File

@ -1,5 +0,0 @@
4 # USERS_TOTAL
bakers
/
9 # USERS_CURRENT
baking now

View File

@ -1,5 +0,0 @@
<ul>
<li><a href="/news">news</a></li>
<li><a href="/join">join</a></li>
<li><a href="/docs">docs</a></li>
</ul>

3
lib.sh
View File

@ -7,13 +7,12 @@ DISCOUNT="markdown -f links,image,pants,html,autolink,fencedcode"
alias p=echo
alias l='p >&2'
N(){ f="${1:-$F}";n="${f#$UNKI/}";p "${n%.*}";}
NN(){ f="${1:-$F}";n="${f##*/}";p "${n%%.*}";}
N_(){ f="${1:-$F}";n="$(N "$f")";p "${n#_}";}
M(){ sed '/^$/q' "${2:-$F}"|grep "^$1"|cut -f2-;}
C(){ sed '1,/^$/d' "${1:-$F}";}
X(){
Xd=$((Xd+1));
eval "$(p "set -e";p "cat<<$UNKZ$Xd";cat "${1:--}"|sed 's/`/\\`/g';p;p "$UNKZ$Xd")";
eval "$(p "set -e";p "cat<<$UNKZ$Xd";cat "${1:--}";p;p "$UNKZ$Xd")";
}
modmsg()

3
unk
View File

@ -6,6 +6,7 @@ set -e
: "${UNKI:=I}"
: "${UNKO:=O}"
: "${UNKL:=L}"
: "${UNKF:=La}"
: "${UNKS:=$UNKI/S}"
. ./lib.sh
@ -50,5 +51,3 @@ do [ -d "$F" ] && continue
done
#X "$UNKF" > "$UNKO/atom.xml"
l "Building DP"
X Dp > "$UNKO/tilde.json"

View File

@ -1,10 +0,0 @@
#!/usr/bin/awk -f
/USERS_TOTAL/ {
"ls /home|wc -l" | getline $1;
}
/USERS_CURRENT/ {
"users|tr ' ' '\n'|sort -u|wc -l" | getline $1;
}
{ print; }