Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
95 changes: 95 additions & 0 deletions .github/workflows/bluesky.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
name: Publish Notes to Bluesky

on:
push:
branches:
- main
paths:
- 'notes/**'
workflow_dispatch:

env:
SQLX_OFFLINE: true
APP_BASE_URL: https://coreyja.com

jobs:
publish:
name: Publish Notes to Bluesky
runs-on: ubuntu-latest
env:
CARGO_INCREMENTAL: 0
steps:
- name: Setup | Checkout
uses: actions/checkout@v4

- uses: awalsh128/cache-apt-pkgs-action@latest
with:
packages: protobuf-compiler libasound2-dev
version: v0

- name: Install rust
uses: actions-rust-lang/setup-rust-toolchain@v1

- uses: Swatinem/rust-cache@v2

- name: Build Tailwind CSS
run: |
curl -sLO https://github.com/tailwindlabs/tailwindcss/releases/latest/download/tailwindcss-linux-x64 && \
chmod +x tailwindcss-linux-x64 && \
mv tailwindcss-linux-x64 tailwindcss && \
./tailwindcss -i server/src/styles/tailwind.css -o target/tailwind.css

- name: Build release binary
run: cargo build --locked --release

- name: Find unpublished notes
id: find
run: |
unpublished=""
for file in notes/*.md; do
if [ -f "$file" ]; then
if ! grep -q "bsky_url:" "$file"; then
# Check if date is >= 2026-03-01
date_line=$(grep "^date:" "$file" | head -1)
if [ -n "$date_line" ]; then
post_date=$(echo "$date_line" | sed 's/date: //')
if [[ "$post_date" > "2026-02-28" ]] || [[ "$post_date" == "2026-03-01" ]]; then
unpublished="$unpublished $file"
fi
fi
fi
fi
done

unpublished=$(echo "$unpublished" | xargs)
echo "paths=$unpublished" >> $GITHUB_OUTPUT

if [ -n "$unpublished" ]; then
echo "Found unpublished notes: $unpublished"
else
echo "No unpublished notes found"
fi

- name: Publish to Bluesky
if: steps.find.outputs.paths != ''
env:
BLUESKY_IDENTIFIER: ${{ secrets.BLUESKY_IDENTIFIER }}
BLUESKY_APP_PASSWORD: ${{ secrets.BLUESKY_APP_PASSWORD }}
run: |
for path in ${{ steps.find.outputs.paths }}; do
echo "Publishing: $path"
./target/release/server publish-bluesky --path "$path"
done

- name: Commit bsky_url updates
if: steps.find.outputs.paths != ''
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
git add notes/
if git diff --staged --quiet; then
echo "No changes to commit"
else
git commit -m "Add bsky_url to published notes"
git push
fi
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: HTML image lazy loading
date: 2023-06-11
slug: html-image-lazy-loading
kind: til
---

TLDR: Add `loading=lazy` to HTML images for the Browser to load them as the user scrolls
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: Ruby and Sorbet Module Loading Order
date: 2023-06-14
slug: sorbet-module-loading
kind: til
---

Today I learned that Sorbet interfaces do some magic to override how Ruby
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: String Interning
date: 2023-06-18
slug: string-interning
kind: til
---

Today I learned about String Interning. Which is the process of taking a string and turning it into a number that you can use to represent that string. Its often used in cases where you might have a fixed number of strings, and want to perform things like equality checks quicker than doing string equality. You can map each string to a unique integer then do the equality check on the integer instead.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
title: iOS Full Height HTML
slug: ios-full-height-html
kind: til
date: 2023-06-22
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: Cleaning up unused Typescript Files with `ts-prune`
date: 2023-06-27
slug: clean-up-with-ts-prune
kind: til
---

TLDR: `npx ts-prune` will find us-used files in your Typescript project!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: FEN Chess Notation and Battlesnake
date: 2023-07-09
slug: chess-fen
kind: til
---

TIL about FEN Chess notation, a text representation of the state of a chess board.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: Turn a video to frames and then back again with ffmpeg
date: 2023-07-22
slug: ffmpeg-to-frames-and-back-again
kind: til
---

Here are a collection of bash commands and then a final script that I used this week to convert a video to frames.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: Autoformat in VSCode on Auto-Saves
date: 2023-09-08
slug: vscode-autoformat-autosaves
kind: til
---

I've had VS Code setup to format my code on save for a while now, and I love it!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: Why can't I mutate this HashMap - References in Rust
date: 2024-01-06
slug: references-in-rust
kind: til
---

Note: This is an older video I made for TikTok and never posted as a TIL so posting now
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: Video from Screenshots in Git History
date: 2024-01-13
slug: video-from-screenshot-history
kind: til
---

<div class="max-w-prose">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: Fallback Routing with Axum
date: 2024-02-27
slug: fallback-routing-with-axum
kind: til
---

Yesterday I ran into a small problem with my Axum routing for my blog.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---
title: clippy::pedantic and Workspace Lints
slug: clippy-pedantic-workspace
kind: til
date: 2024-03-04
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: Easily use Github Avatars
date: 2024-08-21
slug: github-avatars
kind: til
---

tldr: You can use avatars from Github by adding `.png` to the end of a profile url. For instance this will show you my Github Avatar: `https://github.com/coreyja.png`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: sqlx Offline Mode for Tests
date: 2025-07-03
slug: sqlx-offline-mode-tests
kind: til
bsky_url: https://bsky.app/profile/coreyja.com/post/3lt5qrppadc2u
---

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
title: "Diátaxis: A Framework for Documentation"
date: 2026-02-12
slug: diataxis-documentation-framework
kind: til
---

Today I was trying to remember the name of the documentation framework that splits docs into four quadrants — tutorials, how-to guides, reference, and explanation. It's called **Diátaxis**.
Expand Down
2 changes: 1 addition & 1 deletion posts/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ use color_eyre::Result;
use self::{blog::PostMarkdown, date::PostedOn, title::Title};

pub mod blog;
pub mod notes;
pub mod podcast;
pub mod til;

pub mod date;
pub mod title;
Expand Down
Loading
Loading