commit 043a9f4776f105b31c5c5fb54d76f5609d22f932
parent aaeb40265495388576c7cba60d2013a07782025e
Author: Oscar Benedito <oscar@oscarbenedito.com>
Date:   Sat, 12 Aug 2023 12:22:27 +0200

Broken links and small fixes

Diffstat:
MMakefile | 5++++-
MREADME.md | 3+--
Mcontent/_index.html | 12+++++-------
Mcontent/blog/2019-10-06-dark-theme.html | 18++++++++++++++++--
Mcontent/blog/2019-11-17-lineageos-with-microg.html | 2+-
Mcontent/blog/2020-03-02-types-of-networks.html | 6+++---
Mcontent/blogroll.html | 3+--
Mgensite.py | 8++++----
Mlayouts/post.html | 4++--
9 files changed, 37 insertions(+), 24 deletions(-)

diff --git a/Makefile b/Makefile @@ -1,6 +1,6 @@ DST = /srv/oscarbenedito.com -.PHONY: site server blogroll deploy loc clean +.PHONY: site server blogroll deploy brokenlinks loc clean site: python3 gensite.py @@ -20,6 +20,9 @@ deploy: python3 gensite.py rsync --perms --recursive --checksum --delete _site/ $(DST) +brokenlinks: + muffet -t 60 -c 10 http://oscarbenedito.com + loc: grep -vE '^[[:space:]]*#|^[[:space:]]*$$|^[[:space:]]*"""' gensite.py | wc -l diff --git a/README.md b/README.md @@ -6,8 +6,7 @@ bare-bones static site generator). ## Dependencies -To generate the site all you need is Python 3 and the markdown library (install -with `pip3 install markdown`). +To generate the site all you need is Python 3. ## Other notes diff --git a/content/_index.html b/content/_index.html @@ -6,18 +6,16 @@ Hello and welcome to my website! My name is Oscar Benedito and I am a 25-year-old from Barcelona. I enjoy tinkering with and customizing computers and I often undertake small software projects for personal use. When away from a computer, I like to do sport (the particular sport varies depending - on the season and year) and I occasionally juggle. Last year I graduated in Mathematics and - Computer Engineering from <a href="https://www.upc.edu/en">UPC</a> and I am currently working as - a Software Engineer at Oracle.</p> + on the season and year) and I occasionally juggle. I graduated in Mathematics and Computer + Engineering from <a href="https://www.upc.edu/en">UPC</a> and I am currently working as a Software + Engineer at Oracle.</p> <!-- /p --> <p> I encourage you to check out some of my content: <a href="/blog/">my blog</a>, where I talk about privacy, software and other related topics, or <a href="https://git.oscarbenedito.com">my Git - repositories</a> (which are mirrored on <a href="https://git.sr.ht/~ob">SourceHut</a> and <a - href="https://github.com/oscarbenedito">GitHub</a>). If you want to read more about my - academic/professional life, check out <a href="https://www.linkedin.com/in/oscarbenedito">my - LinkedIn profile</a>.</p> + repositories</a>. If you want to read more about my academic/professional life, check out <a + href="https://www.linkedin.com/in/oscarbenedito">my LinkedIn profile</a>.</p> <!-- /p --> <h2>Contact me</h2> diff --git a/content/blog/2019-10-06-dark-theme.html b/content/blog/2019-10-06-dark-theme.html @@ -2,6 +2,7 @@ <!-- slug: dark-theme --> <!-- categories: Personal domain, Projects --> <!-- date: 2019-10-06T00:00:00Z --> +<!-- lastmod: 2023-06-23T00:00:00Z --> <p> The first contact I had with HTML and CSS was about two years ago, when I created my first website @@ -43,8 +44,8 @@ Looking around for simple themes to base my new stylesheet in, I found a couple that, combined, could result in a similar website than the one I had. I based my theme on the <a href="https://github.com/nanxiaobei/hugo-paper/">Hugo Paper</a> theme (you can see that the cards - look very similar) and I added a header (inspired by the <a - href="https://github.com/shankar/hugo-grapes/">Hugo Grapes</a> theme) and a footer. I changed how + look very similar) and I added a header (inspired by the Hugo Grapes<sup id="fnref1"><a + href="#fn1">1</a></sup> theme) and a footer. I changed how some elements appeared (such as the tables), I added some more features that I found interesting and I themed it with the colors I wanted. I also used my old site to inspire the new features (especially the header and footer), so it might resemble a site using Bulma, although it is @@ -57,3 +58,16 @@ a dark theme that toggles instantly, and it is now so much easier for me to redesign certain parts of the website, as I know more CSS and have a better understanding of my stylesheet.</p> <!-- /p --> + +<p><em>Edit</em>: Removed broken link and added note about it.</p> + +<!-- footnotes --> +<hr /> + +<ol> + <li id="fn1"> + The theme used to be hosted <a href="https://github.com/shankar/hugo-grapes/">here</a>, but the + link no longer works. If you are interested, you can find images of the theme if you search for + it. <a href="#fnref1" title="Jump back to footnote 1 in the text">&#8617;</a></li> + <!-- /li --> +</ol> diff --git a/content/blog/2019-11-17-lineageos-with-microg.html b/content/blog/2019-11-17-lineageos-with-microg.html @@ -96,7 +96,7 @@ <hr /> <ol> - <li id="fn1"> + <li id="fn1"> It wasn't actually that quick. I tried to reinstall LineageOS with Gapps once again, but, for some reason, it wouldn't work and the phone stopped working (it was stuck on the boot screen, I left it for hours). I finally got help from an acquaintance (we had to go into Emergency diff --git a/content/blog/2020-03-02-types-of-networks.html b/content/blog/2020-03-02-types-of-networks.html @@ -10,7 +10,7 @@ operates, we can classify it as centralized, decentralized or distributed.</p> <!-- /p --> -<h3>Centralized networks</h3> +<h2>Centralized networks</h2> <p> When all the nodes on a network are connected to one unique node, we call it a centralized @@ -33,7 +33,7 @@ the resources are provided by one sole party.</p> <!-- /p --> -<h3>Decentralized networks</h3> +<h2>Decentralized networks</h2> <p> Decentralized networks don't have one central node, but multiple of them, which are connected @@ -58,7 +58,7 @@ servers might update at different times, when each administrator decides to do so.</p> <!-- /p --> -<h3>Distributed networks</h3> +<h2>Distributed networks</h2> <p> Distributed networks only have one type of node, and they are connected with each other (although diff --git a/content/blogroll.html b/content/blogroll.html @@ -12,9 +12,8 @@ <li><a href="https://www.codesections.com/blog/">Codesections</a> — <a href="https://www.codesections.com/rss.xml">Feed</a></li> <li><a href="https://chown.me">Daniel Jakots</a> — <a href="https://chown.me/blog/feeds/atom.xml">Feed</a></li> <li><a href="https://www.davd.io">David Prandzioch</a> — <a href="https://www.davd.io/index.xml">Feed</a></li> - <li><a href="https://desmondrivet.com/posts/blog/">Desmond Rivet</a> — <a href="https://desmondrivet.com/posts/feed_blog.xml">Feed</a></li> <li><a href="https://emanuelpina.pt">Emanuel Pina</a> — <a href="https://emanuelpina.pt/index.xml">Feed</a></li> - <li><a href="https://hacdias.com/articles/">Henrique Dias</a> — <a href="https://hacdias.com/articles.atom">Feed</a></li> + <li><a href="https://hacdias.com/articles/">Henrique Dias</a> — <a href="https://hacdias.com/articles/feed.xml">Feed</a></li> <li><a href="https://www.paritybit.ca/blog">Jake Bauer</a> — <a href="https://www.paritybit.ca/feed.xml">Feed</a></li> <li><a href="https://jlelse.blog">Jan-Lukas Else</a> — <a href="https://jlelse.blog/.rss">Feed</a></li> <li><a href="https://atthis.link">Marc</a> — <a href="https://atthis.link/rss.xml">Feed</a></li> diff --git a/gensite.py b/gensite.py @@ -365,10 +365,10 @@ def main(): # minify css if os.path.splitext(file)[1] == '.css': - content = re.sub('\s*/\*(?:.|\n)*?\*/\s*', '', content) - content = re.sub('\s+', ' ', content) - content = re.sub('\s*({|}|;|,)\s*', r'\1', content) - content = re.sub(':\s*', ':', content) + content = re.sub(r'\s*/\*(?:.|\n)*?\*/\s*', '', content) + content = re.sub(r'\s+', ' ', content) + content = re.sub(r'\s*({|}|;|,)\s*', r'\1', content) + content = re.sub(r':\s*', ':', content) rfile = '{0}.min{1}'.format(*os.path.splitext(rfile)) h = hashlib.sha256() diff --git a/layouts/post.html b/layouts/post.html @@ -14,7 +14,7 @@ </article> {{ _if multiple_pages }}<nav class="pagination">{{ _fi }} - {{ _if next_url }}<a class="button" href="/{{ next_url }}" title="{{ next_title }}">&larr; Newer Post</a>{{ _fi }} - {{ _if prev_url }}<a class="button right" href="/{{ prev_url }}" title="{{ prev_title }}">Previous Post &rarr;</a>{{ _fi }} + {{ _if next_url }}<a class="button" href="/{{ next_url }}" title="{{ next_title }}">&larr; Next post</a>{{ _fi }} + {{ _if prev_url }}<a class="button right" href="/{{ prev_url }}" title="{{ prev_title }}">Previous post &rarr;</a>{{ _fi }} {{ _if multiple_pages }}</nav>{{ _fi }} </main>