aboutsummaryrefslogtreecommitdiff
path: root/build/openring/index.html
diff options
context:
space:
mode:
Diffstat (limited to 'build/openring/index.html')
-rw-r--r--build/openring/index.html35
1 files changed, 2 insertions, 33 deletions
diff --git a/build/openring/index.html b/build/openring/index.html
index 85449ba..b4e799a 100644
--- a/build/openring/index.html
+++ b/build/openring/index.html
@@ -3,11 +3,12 @@
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
+ <meta name="color-scheme" content="dark light">
<link rel="icon" href="data:,">
<title>Building openring with Jekyll Build</title>
<link href="/atom.xml" type="application/atom+xml" rel="alternate" title="Atom feed for blog posts" />
<link href="/rss.xml" type="application/rss+xml" rel="alternate" title="RSS feed for blog posts" />
-<style>*{box-sizing:border-box;}body{font-family:sans-serif;line-height:1.33;margin:0 auto;max-width:650px;padding:1rem;}img{max-width:100%;}pre{border:1px solid;overflow:auto;padding:5px;}table{text-align:left;width:100%;}.footnotes{font-size:90%;}</style>
+<style>*{box-sizing:border-box;}body{font-family:sans-serif;line-height:1.33;margin:0 auto;max-width:650px;padding:1rem;}blockquote{background:rgba(0,0,0,0.1);border-left:4px solid;padding-left:5px;}img{max-width:100%;}pre{border:1px solid;overflow:auto;padding:5px;}table{text-align:left;width:100%;}.footnotes{font-size:90%;}</style>
</head>
<nav>
@@ -16,30 +17,18 @@
<main>
<h1 id="building-openring-with-jekyll-build">Building openring with Jekyll Build</h1>
-
<p>2022-12-02</p>
-
<p>I think it&#8217;s great when bloggers post their own personal &#8220;reading list&#8221; of blogs they themselves follow. Whether this is a customized Blogroll page or footnotes in their individual articles, I find it really helpful to find more interesting content on the &#8220;indie&#8221; web. This isn&#8217;t a new concept by any means, but I wanted something a little more &#8220;dynamic&#8221;[^1] for my own blog.</p>
-
<p>After some digging I came across <a href="https://sr.ht/~sircmpwn/openring/">openring</a> and it&#8217;s great. Fully customizable, lightweight and completely open source. What more could you ask for?</p>
-
<p>So, I thought others might be interested in how I&#8217;ve implemented openring through my own Jekyll build system.</p>
-
<h2 id="installing-openring">Installing openring</h2>
-
<p>You can pull the project <a href="https://sr.ht/~sircmpwn/openring/">directly via SourceHut</a> if you wish, but I would recommend installing through your default package manager. I&#8217;m running Arch, so for me it was as simple as running:</p>
-
<pre><code>yay -S openring
</code></pre>
-
<p>That&#8217;s it. I now have full local access to openring!</p>
-
<h2 id="jekyll-includes">Jekyll Includes</h2>
-
<p>You <em>could</em> setup a whole new directory specifically for your openring files, but that seems like overkill. Instead, we will simply add two new files to our existing <code>_includes</code> directory. We will name these files <code>openring-in.html</code> and <code>openring-out.html</code>.</p>
-
<h3 id="openring-in.html-contents">openring-in.html Contents</h3>
-
<pre><code>&#60;!-- License-Id: CC0-1.0 --&#62;
&#60;section class="webring"&#62;
&#60;h3&#62;Articles from blogs I follow around the world wide web&#60;&#47;h3&#62;
@@ -91,21 +80,14 @@
}
&#60;&#47;style&#62;
</code></pre>
-
<blockquote>
<p>Sidenote: You will get minor Liquid Syntax warnings in the console when running your website via <code>serve</code> or <code>build</code>. I don&#8217;t really mind those warnings but if you do, feel free to move these files out into their own sub-directory in your project folder.</p>
</blockquote>
-
<h3 id="openring-out.html-contents">openring-out.html Contents</h3>
-
<p>This will generate itself for us every time we rebuild our Jekyll website. It is important to note that any changes you make in this file will be overwritten the next time you rebuild! All custom styling or layout changes should be made in the <code>openring-in.html</code> file.</p>
-
<h2 id="our-new-build-script">Our &#8220;New&#8221; Build Script</h2>
-
<p>To simplify things, we are going to place our main commands in a single build script in the root directory of our Jekyll project. For my personal blog, I&#8217;ve named this file <code>build-site.sh</code>. I know - I&#8217;m extremely creative.</p>
-
<p>Place the following inside that file:</p>
-
<pre><code>openring \
-s https:&#47;&#47;example.com&#47;feed.xml \
-s https:&#47;&#47;example.com&#47;feed.xml \
@@ -114,35 +96,22 @@
&#62; _includes&#47;openring-out.html
bundle exec jekyll build
</code></pre>
-
<h2 id="edit-">Edit <code>_config.yml</code></h2>
-
<p>Next we need to make sure we exclude our new <code>build-site</code> script file, since we really don&#8217;t need that pushed up to the main server:</p>
-
<pre><code># Includes &#47; Excludes
exclude:
- build-site.sh
</code></pre>
-
<h2 id="almost-done">Almost Done&#8230;</h2>
-
<p>Now you just need to decide where you want your <code>openring</code> feed outputs to render. For this example, we will place them at the bottom of every blog post inside the <code>_layouts&#47;post.html</code> file, like so:</p>
-
<pre><code>{% raw %}{% include openring-out.html %}{% endraw %}
</code></pre>
-
<h2 id="build-it-they-will-come">Build It &#38; They Will Come</h2>
-
<p>This next step is only for those using <a href="https://srht.site">SourceHut Pages</a> to build and host their websites. If you use a different platform (ie Netlify, Vercel, GitHub Pages) the concept should be similar but will most likely require more tweaking on your end. Just a fair warning.</p>
-
<p>I won&#8217;t go into great detail about build script for SourceHut Pages, but feel free to take a look at my <a href="https://git.sr.ht/~bt/bt.ht/tree/master/item/.build.yml">very own build file for this website</a>. That <em>should</em> work out-of-the-box for most standard Jekyll websites. (Just be sure to edit with your own details!)</p>
-
<p><strong>That&#8217;s it</strong>. You now have links to blogs you enjoy that will update with each build. Of course, the &#8220;latest&#8221; blog posts shown will become out-of-date if you don&#8217;t blog (or at least re-build your website) on a regular basis. But for me, I see this as a good motivator to keep pushing out content!</p>
-
<p>Happy sharing!</p>
-
<h2 id="refs">Refs</h2>
-
<ol>
<li>Well, as dynamic as a static website can be!</li>
</ol>