skeleton to create new issues

This commit is contained in:
Solene Rapenne 2021-09-26 21:27:49 +02:00
parent 943e13e570
commit f8980531d2
14 changed files with 157 additions and 0 deletions

2
issues/Makefile Normal file
View File

@ -0,0 +1,2 @@
all:
find . -maxdepth 1 -type d -name 'issue-*' -exec ./make_issue.sh {} \;

3
issues/_common/footer Normal file
View File

@ -0,0 +1,3 @@
</main>
</body>
</html>

70
issues/_common/header Normal file
View File

@ -0,0 +1,70 @@
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>OpenBSD_WEBZINE_ISSUE #1</title>
<style>
h1 {
text-align: center;
font-size:3em;
font-weight:bold;
}
#banner {
border-top: .2em double black;
border-bottom: .2em double black;
padding:.5em;
margin-bottom:2em;
}
.right {
text-align:right;
float:right;
}
.puffies {
margin: auto;
text-align: center;
}
.permalink {
color: black;
text-decoration: none;
}
.permalink:visited {
color: black;
}
.permalink:hover {
color: darkgrey;
}
p {
text-align: justify;
text-justify: auto;
}
html, body {
margin: auto;
font-size: 1.1em;
font-family:serif;
}
html {
background-color: #F5F5F5;
}
body {
background-color: #FEFEFE;
padding: 30px;
max-width: 80ch;
}
main {
column-count:2;
column-gap: 2em;
}
</style>
</head>
<body>

View File

@ -0,0 +1,6 @@
<div id="title">OpenBSD Webzine</div>
<div id="banner">
<span>ISSUE #1</span>
<span class="right">Sat Sep 25 12:06:17 UTC 2021</span>
</div>
<main>

View File

@ -0,0 +1,6 @@
<!-- SECTION -->
<h2>Headlines</h2>
<ul>
<li>OpenBSD 7.0 release very soon</li>
</ul>

View File

@ -0,0 +1,6 @@
<!-- SECTION -->
<div class="puffies">🐡🐡🐡</div>
<h2>Recent -current changes</h2>
<ul>
<li></li>
</ul>

View File

@ -0,0 +1,6 @@
<!-- SECTION -->
<div class="puffies">🐡🐡🐡</div>
<h2>6.9-stable changes</h2>
<ul>
<li></li>
</ul>

View File

@ -0,0 +1,3 @@
<div class="puffies">🐡🐡🐡</div>
<!-- SECTION -->
<h2>Interview</h2>

View File

@ -0,0 +1,5 @@
<div class="puffies">🐡🐡🐡</div>
<!-- SECTION -->
<h2>Shell tips</h2>
<p>
</p>

View File

@ -0,0 +1,6 @@
<div class="puffies">🐡🐡🐡</div>
<!-- SECTION -->
<h2>Reader comments</h2>
<p>
<em>Message received from XXX</em>
</p>

View File

@ -0,0 +1,6 @@
<div class="puffies">🐡🐡🐡</div>
<!-- SECTION -->
<h2>Going further</h2>
<ul>
<li><a href=""></a></li>
</ul>

View File

@ -0,0 +1,5 @@
<div class="puffies">🐡🐡🐡</div>
<!-- SECTION -->
<h2>Artworks of the moment</h2>
<img src="" alt="MANDATORY TEXT HERE" width="100%"/>

View File

@ -0,0 +1,6 @@
<div class="puffies">🐡🐡🐡</div>
<!-- SECTION -->
<h2>On social medias</h2>
<ul>
<li><a href=""></a></li>
</ul>

27
issues/make_issue.sh Executable file
View File

@ -0,0 +1,27 @@
#!/bin/sh
usage() {
echo "./$0 directory"
exit 1
}
die() {
echo "$1"
exit 1
}
DIR=$(basename $1)
CURINODE=$(stat -f "%i" current/)
test -d "$DIR" || usage
test -d ../public/ || die "You must run this from openbsd-webzine/current"
ls $DIR/*.html 2>&1 >/dev/null || die "no html file in $DIR"
if [ "$(stat -f '%i' $DIR)" -eq "$CURINODE" ]
then
DEST=dev
else
DEST=public
fi
cat _common/header $DIR/*html _common/footer > ../${DEST}/${DIR}.html