The code for my personal website, powered by Jekyll. arthr.me
jekyll-site personal-website
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix: uses `jsonify` filter to generate prose index files

+12 -99
-87
CLAUDE.md
··· 1 - # CLAUDE.md 2 - 3 - This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. 4 - 5 - ## Project Overview 6 - 7 - This is Arthur Freitas's personal website/blog at [arthr.me](https://arthr.me). It's a Jekyll 4.4.1 site using a custom gem-based theme called `linus`. The site is deployed to Cloudflare Pages and written primarily in Portuguese (pt-BR). 8 - 9 - The blog was previously hosted on Tumblr (accounts `arthrfrts` and `irrelefante`). Many posts have a `tumblr_url` front matter field from that migration. 10 - 11 - ## Commands 12 - 13 - ```sh 14 - # Serve locally with drafts and incremental builds 15 - bundle exec jekyll serve --drafts --incremental 16 - 17 - # Clean build artifacts 18 - bundle exec jekyll clean 19 - 20 - # Update gems 21 - bundle update 22 - ``` 23 - 24 - ## Architecture 25 - 26 - ### Theme 27 - 28 - The site uses a custom gem theme `linus` (~> 1.0). The theme provides layouts, includes, and styles. Local includes override gem stubs: 29 - 30 - - `_includes/head.html` — IndieAuth, webmention endpoints, syndication links 31 - - `_includes/below-post.html` — webmention display (`{% webmentions page.url %}`) 32 - - `_includes/end.html` — webmention JS (`{% webmentions_js %}`) 33 - 34 - ### Content 35 - 36 - Posts live in `_posts/YYYY-MM-DD-slug.md`. The standard front matter for a post: 37 - 38 - ```yaml 39 - --- 40 - layout: post 41 - title: 'Post title' 42 - date: '2024-01-01T10:00:00-03:00' 43 - category: Notas # One of: Notas, Links, Impressões, Fotos 44 - tags: 45 - - tag-name 46 - tumblr_url: https://arthrfrts.tumblr.com/post/... # optional, migrated posts only 47 - source: https://example.com # optional, for Links category 48 - image: /uploads/image.jpg # optional, cover image 49 - syndicate_to: # optional, POSSE targets 50 - - bluesky 51 - - tumblr 52 - - flickr # Fotos only 53 - syndication_urls: # written back by GitHub Action 54 - bluesky: https://bsky.app/profile/.../post/... 55 - tumblr: https://arthrfrts.tumblr.com/post/... 56 - flickr: https://flickr.com/photos/arthrfrts/... 57 - --- 58 - ``` 59 - 60 - The four categories have designated colors defined in `_config.yml`: 61 - - **Notas** — yellow (`#F5C842`) 62 - - **Links** — blue (`#6BAED6`) 63 - - **Impressões** — red-orange (`#F06A55`) 64 - - **Fotos** — light blue (`#88C0D0`) 65 - 66 - ### Redirects 67 - 68 - `_redirects` is processed as a Jekyll template and generates Cloudflare Pages redirect rules. It maps old Tumblr post URLs and `/tagged/` URLs to their current equivalents. When adding new redirect rules, add them to this file. 69 - 70 - ### Static Pages 71 - 72 - - `index.html` — uses `blog` layout 73 - - `sobre.md` — About page (`/sobre/`) 74 - - `arquivo.md` — Archive page (`/arquivo/`) 75 - - `404.html` — Error page 76 - 77 - ### Feeds & IndieWeb 78 - 79 - The site exposes RSS at `/feed.xml` and JSON Feed at `/feed.json`. It supports Webmentions via `jekyll-webmention_io` and IndieAuth via the `head.html` include. 80 - 81 - ### Media 82 - 83 - Upload images to `/uploads/`. The `.pages.yml` configures the Nova CMS for content editing. 84 - 85 - ## Code Style 86 - 87 - EditorConfig enforces: 2-space indentation, LF line endings, 80-character max line length, no trailing whitespace (trailing whitespace is preserved in `.md` files).
+4 -4
json/categories.jsonp
··· 4 4 [ 5 5 {%- for category in site.categories %} 6 6 { 7 - "name": "{{- category | first -}}", 8 - "value": "{{- category | first -}}" 9 - }{%- unless forloop.last -%}, {% endunless-%} 10 - {% endfor -%} 7 + "name": {{ category | first | jsonify }}, 8 + "value": {{ category | first | jsonify }} 9 + }{%- unless forloop.last -%}, {%- endunless -%} 10 + {%- endfor %} 11 11 ] 12 12 )
+4 -4
json/links.jsonp
··· 4 4 [ 5 5 {%- for post in site.posts %} 6 6 { 7 - "name": "{{- post.title | default: post.excerpt | strip_html | normalize_whitespace | replace: '"', '\"' -}}", 8 - "value": "{{- post.url | relative_url -}}" 9 - }{%- unless forloop.last -%}, {% endunless-%} 10 - {% endfor -%} 7 + "name": {{ post.title | default: post.excerpt | strip_html | strip_newlines | normalize_whitespace | jsonify }}, 8 + "value": {{ post.url | relative_url | jsonify }} 9 + }{%- unless forloop.last -%}, {%- endunless -%} 10 + {%- endfor %} 11 11 ] 12 12 )
+4 -4
json/tags.jsonp
··· 4 4 [ 5 5 {%- for tag in site.tags %} 6 6 { 7 - "name": "{{- tag | first -}}", 8 - "value": "{{- tag | first -}}" 9 - }{%- unless forloop.last -%}, {% endunless-%} 10 - {% endfor -%} 7 + "name": {{ tag | first | jsonify }}, 8 + "value": {{ tag | first | jsonify }} 9 + }{%- unless forloop.last -%}, {%- endunless -%} 10 + {%- endfor %} 11 11 ] 12 12 )