aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGabriel Arakaki Giovanini <mail@gabrielgio.me>2022-06-23 23:09:17 +0200
committerGabriel Arakaki Giovanini <mail@gabrielgio.me>2022-06-23 23:13:40 +0200
commita588d31babc97d8749cf531379c9c2e25d7225fa (patch)
tree3fc4b5261df6cd48655bb3a2fbd4d9257c4d6144
parent4f3b7a9fbb951257a039a84cafcd9f897a6bc197 (diff)
downloadgabrielgio.me-a588d31babc97d8749cf531379c9c2e25d7225fa.tar.gz
gabrielgio.me-a588d31babc97d8749cf531379c9c2e25d7225fa.tar.bz2
gabrielgio.me-a588d31babc97d8749cf531379c9c2e25d7225fa.zip
feat: Add openring feed
Add a nice way to suggest some feed I interested in.
-rw-r--r--.build.yml12
-rw-r--r--.gitignore2
-rw-r--r--Makefile16
-rw-r--r--themes/flamingo/layouts/index.html10
-rw-r--r--themes/flamingo/layouts/partials/sidebar.html9
-rw-r--r--webring.template4
6 files changed, 50 insertions, 3 deletions
diff --git a/.build.yml b/.build.yml
index d58a4e6..d38abf1 100644
--- a/.build.yml
+++ b/.build.yml
@@ -1,7 +1,13 @@
image: alpine/latest
packages:
- rsync
+ - go
- hugo
+ - make
+
+sources:
+ - https://git.sr.ht/~gabrielgio/gabrielgio.me
+ - https://git.sr.ht/~sircmpwn/openring
secrets:
- 008c4f67-b864-47f8-9790-cd32f2ae8516
@@ -10,9 +16,13 @@ environment:
deploy: builds@gabrielgio.me
tasks:
+ - openring: |
+ cd openring
+ go build -o openring
+ sudo cp openring /usr/local/bin/
- build: |
cd gabrielgio.me
- hugo
+ make
- deploy: |
cd gabrielgio.me
sshopts="ssh -o StrictHostKeyChecking=no"
diff --git a/.gitignore b/.gitignore
index 364fdec..b6a1061 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,3 @@
public/
+
+openring.html
diff --git a/Makefile b/Makefile
new file mode 100644
index 0000000..7bdc6d1
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,16 @@
+
+
+all: openring
+ hugo
+
+serve: openring
+ hugo serve
+
+
+openring:
+ openring -n 6 \
+ -s https://drewdevault.com/blog/index.xml \
+ -s https://mazzo.li/rss.xml \
+ -s https://blog.golang.org/feed.atom \
+ < webring.template \
+ > themes/flamingo/layouts/partials/openring.html
diff --git a/themes/flamingo/layouts/index.html b/themes/flamingo/layouts/index.html
index c142435..0e07e11 100644
--- a/themes/flamingo/layouts/index.html
+++ b/themes/flamingo/layouts/index.html
@@ -7,7 +7,13 @@
{{ .Render "summary" }}
{{ end }}
</div>
- <!-- {{ partial "pagination.html" . }} -->
+ <div>
+ <h3>WHAT I READ</h3>
+ </div>
+ <div>
+ <ul>
+ {{ partial "openring.html" . }}
+ </ul>
+ </div>
</main>
-<!-- {{ partial "sidebar.html" . }} -->
{{ end }}
diff --git a/themes/flamingo/layouts/partials/sidebar.html b/themes/flamingo/layouts/partials/sidebar.html
index 9070f56..c7288f0 100644
--- a/themes/flamingo/layouts/partials/sidebar.html
+++ b/themes/flamingo/layouts/partials/sidebar.html
@@ -1,6 +1,15 @@
<aside>
<div>
<div>
+ <h3>WHAT I READ</h3>
+ </div>
+ <div>
+ <ul>
+ {{ partial "openring.html" . }}
+ </ul>
+ </div>
+
+ <div>
<h3>LATEST POSTS</h3>
</div>
<div>
diff --git a/webring.template b/webring.template
new file mode 100644
index 0000000..6faebe7
--- /dev/null
+++ b/webring.template
@@ -0,0 +1,4 @@
+{{range .Articles}}
+<li>[<a href="{{.SourceLink}}">{{.SourceTitle}}</a>] <a href="{{ .Link }}">{{ .Title }}</a></li>
+{{end}}
+