Skip to content

Instantly share code, notes, and snippets.

View jrk's full-sized avatar

Jonathan Ragan-Kelley jrk

View GitHub Profile
#!/usr/bin/env ruby
#
# Trying to guess what the best first-choice word in Wordle might be.
#
# Author: Rob Miller <[email protected]>
# Boosts the score of a word that matches the first letter, with the
# rationale that getting the first letter makes the word easier for
# a human being to guess
FIRST_LETTER_WEIGHT = 2
@drewkerr
drewkerr / get-focus-mode.js
Last active June 4, 2025 00:14
Read the current Focus mode on macOS Monterey (12.0+) using JavaScript for Automation (JXA)
const app = Application.currentApplication()
app.includeStandardAdditions = true
function getJSON(path) {
const fullPath = path.replace(/^~/, app.pathTo('home folder'))
const contents = app.read(fullPath)
return JSON.parse(contents)
}
function run() {
@pdarragh
pdarragh / papers.md
Last active February 23, 2025 02:04
Approachable PL Papers for Undergrads

Approachable PL Papers for Undergrads

On September 28, 2021, I asked on Twitter:

PL Twitter:

you get to recommend one published PL paper for an undergrad to read with oversight by someone experienced. the paper should be interesting, approachable, and (mostly) self-contained.

what paper do you recommend?

@merlinmann
merlinmann / wisdom.md
Last active April 28, 2025 20:57
Merlin's Wisdom Project (Draft)

Merlin's Wisdom Project

Or: “Everybody likes being given a glass of water.”

By Merlin Mann.

It's only advice for you because it had to be advice for me.

# IDA (disassembler) and Hex-Rays (decompiler) plugin for Apple AMX
#
# WIP research. (This was edited to add more info after someone posted it to
# Hacker News. Click "Revisions" to see full changes.)
#
# Copyright (c) 2020 dougallj
# Based on Python port of VMX intrinsics plugin:
# Copyright (c) 2019 w4kfu - Synacktiv
#!/bin/bash
###
### my-script — does one thing well
###
### Usage:
### my-script <input> <output>
###
### Options:
### <input> Input file to read.
### <output> Output file to write. Use '-' for stdout.
@linuz90
linuz90 / better-roam-research.css
Last active August 31, 2022 04:41
Better Roam Research CSS
:root {
--font-size: 15.5px;
--border-color: rgba(0, 0, 0, 0.08);
--subtle-border-color: rgba(0, 0, 0, 0.05);
--main-background-color: hsl(210, 9%, 98%);
--body-background-color: #ffffff;
--reference-item-background: hsl(0, 0%, 99%);
--brackets-color: rgba(0, 0, 0, 0.25);
--empty-text-color: hsl(203, 12%, 75%); }
@mattvh
mattvh / _layout.html
Created May 29, 2020 07:28
Baking Static Sites with Python and Jinja
<!doctype html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>{{ title }}</title>
<link rel="stylesheet" href="static/style.css">
</head>
<body>
<div class="container">
@raysan5
raysan5 / custom_game_engines_small_study.md
Last active July 30, 2025 14:42
A small state-of-the-art study on custom engines

CUSTOM GAME ENGINES: A Small Study

a_plague_tale

WARNING: Article moved to separate repo to allow users contributions: https://github.com/raysan5/custom_game_engines

A couple of weeks ago I played (and finished) A Plague Tale, a game by Asobo Studio. I was really captivated by the game, not only by the beautiful graphics but also by the story and the locations in the game. I decided to investigate a bit about the game tech and I was surprised to see it was developed with a custom engine by a relatively small studio. I know there are some companies using custom engines but it's very difficult to find a detailed market study with that kind of information curated and updated. So this article.

Nowadays lots of companies choose engines like [Unreal](https:

@JoeyBurzynski
JoeyBurzynski / 55-bytes-of-css.md
Last active August 4, 2025 13:45
58 bytes of css to look great nearly everywhere

58 bytes of CSS to look great nearly everywhere

When making this website, i wanted a simple, reasonable way to make it look good on most displays. Not counting any minimization techniques, the following 58 bytes worked well for me:

main {
  max-width: 38rem;
  padding: 2rem;
  margin: auto;
}