diff options
| -rw-r--r-- | Makefile | 4 | ||||
| -rw-r--r-- | bottom.html | 9 | ||||
| -rwxr-xr-x | build.sh | 8 | ||||
| -rw-r--r-- | src/style.css | 5 |
4 files changed, 11 insertions, 15 deletions
| @@ -1,4 +1,4 @@ | |||
| 1 | DEST="sebastiano@tronto.net:/var/www/htdocs/sebastiano.tronto.net" | 1 | DEST="sebastiano@new.tronto.net:/var/www/new.tronto.net" |
| 2 | RSYNC=$$( (command -V rsync 2>&1 > /dev/null && echo rsync) || echo openrsync) | 2 | RSYNC=$$( (command -V rsync 2>&1 > /dev/null && echo rsync) || echo openrsync) |
| 3 | 3 | ||
| 4 | all: clean | 4 | all: clean |
| @@ -11,6 +11,6 @@ clean: | |||
| 11 | deploy: synchttp | 11 | deploy: synchttp |
| 12 | 12 | ||
| 13 | synchttp: | 13 | synchttp: |
| 14 | ${RSYNC} -rv --delete --rsync-path=openrsync http/ ${DEST} | 14 | ${RSYNC} -rv --delete http/ ${DEST} |
| 15 | 15 | ||
| 16 | .PHONY: all clean deploy synchttp | 16 | .PHONY: all clean deploy synchttp |
diff --git a/bottom.html b/bottom.html index 682420d..1c196b1 100644 --- a/bottom.html +++ b/bottom.html | |||
| @@ -5,14 +5,9 @@ | |||
| 5 | <footer> | 5 | <footer> |
| 6 | <table> | 6 | <table> |
| 7 | <tr> | 7 | <tr> |
| 8 | <td class="lastupdate">Last update: LASTUPDATE</td> | ||
| 8 | <td class="contact"> | 9 | <td class="contact"> |
| 9 | <a href="mailto:sebastiano@tronto.net"> | 10 | <a href="mailto:sebastiano@tronto.net">sebastiano@tronto.net</a> |
| 10 | sebastiano@tronto.net | ||
| 11 | </a> | ||
| 12 | </td> | ||
| 13 | <td class="hosted"> | ||
| 14 | Hosted at | ||
| 15 | <a href="https://openbsd.amsterdam">openbsd.amsterdam</a> | ||
| 16 | </td> | 11 | </td> |
| 17 | </tr> | 12 | </tr> |
| 18 | </table> | 13 | </table> |
| @@ -1,6 +1,7 @@ | |||
| 1 | #!/bin/sh | 1 | #!/bin/sh |
| 2 | 2 | ||
| 3 | basedir="$(pwd)" | 3 | basedir="$(pwd)" |
| 4 | bottomtmp="$(mktemp)" | ||
| 4 | 5 | ||
| 5 | recursivebuild() { | 6 | recursivebuild() { |
| 6 | local destdir=$(echo "$1" | sed 's|^src|http|') | 7 | local destdir=$(echo "$1" | sed 's|^src|http|') |
| @@ -44,7 +45,7 @@ copyfile() { | |||
| 44 | mdpreprocess "$file" | \ | 45 | mdpreprocess "$file" | \ |
| 45 | lowdown --html-no-skiphtml --html-no-escapehtml \ | 46 | lowdown --html-no-skiphtml --html-no-escapehtml \ |
| 46 | >> "$ind" | 47 | >> "$ind" |
| 47 | cat bottom.html >> "$ind" | 48 | cat "$bottomtmp" >> "$ind" |
| 48 | ;; | 49 | ;; |
| 49 | noheadermd) | 50 | noheadermd) |
| 50 | t="$(markdowntitle "$file")" | 51 | t="$(markdowntitle "$file")" |
| @@ -55,7 +56,7 @@ copyfile() { | |||
| 55 | ;; | 56 | ;; |
| 56 | html) | 57 | html) |
| 57 | t="$(htmltitle "$file")" | 58 | t="$(htmltitle "$file")" |
| 58 | cat top.html "$file" bottom.html | sed "s/TITLE/$t/" > "$ind" | 59 | cat top.html "$file" "$bottomtmp" | sed "s/TITLE/$t/" > "$ind" |
| 59 | ;; | 60 | ;; |
| 60 | raw) | 61 | raw) |
| 61 | namenoraw="$(basename "$file" | sed 's/\.raw$//')" | 62 | namenoraw="$(basename "$file" | sed 's/\.raw$//')" |
| @@ -118,7 +119,7 @@ makeblogindexandfeed() { | |||
| 118 | done | 119 | done |
| 119 | 120 | ||
| 120 | echo '</table>' >> "$bf" | 121 | echo '</table>' >> "$bf" |
| 121 | cat bottom.html >> "$bf" | 122 | cat "$bottomtmp" >> "$bf" |
| 122 | 123 | ||
| 123 | { echo ""; echo "</channel>"; echo "</rss>"; } >> "$ff" | 124 | { echo ""; echo "</channel>"; echo "</rss>"; } >> "$ff" |
| 124 | } | 125 | } |
| @@ -164,5 +165,6 @@ month() { | |||
| 164 | esac | 165 | esac |
| 165 | } | 166 | } |
| 166 | 167 | ||
| 168 | sed "s/LASTUPDATE/$(date +'%Y-%m-%d')/" <bottom.html >"$bottomtmp" | ||
| 167 | makeblogindexandfeed | 169 | makeblogindexandfeed |
| 168 | recursivebuild src | 170 | recursivebuild src |
diff --git a/src/style.css b/src/style.css index 7f7f0d2..5a1ecf5 100644 --- a/src/style.css +++ b/src/style.css | |||
| @@ -3,9 +3,8 @@ header nav table { width: 100%; } | |||
| 3 | .logo img { max-width: 3em; margin: 0 0 0 0; } | 3 | .logo img { max-width: 3em; margin: 0 0 0 0; } |
| 4 | .links { text-align: right; font-weight: bold; } | 4 | .links { text-align: right; font-weight: bold; } |
| 5 | .links a { font-weight: bold; color: black; } | 5 | .links a { font-weight: bold; color: black; } |
| 6 | footer table { font-style: italic; width: 100%; } | 6 | .contact { text-align: right; } |
| 7 | .hosted { text-align: right; } | 7 | .contact a { font-weight: bold; } |
| 8 | .hosted a, .contact a { font-weight: bold; } | ||
| 9 | 8 | ||
| 10 | /* Content */ | 9 | /* Content */ |
| 11 | html { margin: 1em auto; max-width: 42em; font-family: sans-serif } | 10 | html { margin: 1em auto; max-width: 42em; font-family: sans-serif } |
