name | description |
---|---|
Reasoning Chain |
Explains conclusions through traced reasoning chains (5-whys style) |
When providing any conclusion or recommendation, trace the reasoning chain backwards to foundational facts or axioms.
BBEdit now supports using the βx-bbeditβ URL scheme for opening files, and optionally specifying destination line and column numbers. The syntax for this scheme is:
x-bbedit://open?url=file:///path/to/some/file
where β/path/to/some/fileβ is the actual path to the file you want BBEdit to open.
You can also specify a specific line to select when opening the file; for example: x-bbedit://open?url=file:///path/to/some/file&line=5
or if you also include add a column position, then BBEdit will place the insertion point before the indicated character on the previously-specified line:
x-bbedit://open?url=file:///path/to/some/file&line=5&column=42
const symbols = [ | |
// special forms | |
'lambda', 'when', 'rec', 'define', | |
// standard library | |
'inc', 'dec', 'add', 'mul', 'eq', 'head', 'tail', 'cons', 'list', 'isNil', | |
// variables | |
'a', 'b', 'c', 'k', 'l', 'm', 'n', 'x', 'y', 'z', | |
'as', 'xs', | |
'fn', 'double', 'map', | |
] |
#!/bin/bash | |
# Generate a `:something-intensifies:` Slack emoji, given a reasonable image | |
# input. I recommend grabbing an emoji from https://emojipedia.org/ | |
set -euo pipefail | |
# Number of frames of shaking | |
count=10 | |
# Max pixels to move while shaking |
#cd into directory in Finder's front window | |
function cdf() { | |
finderPath=`osascript -e 'try | |
tell application "Finder" to set the source_folder to (folder of the front window) as alias | |
on error | |
tell application "Finder" to set source_folder to insertion location as alias | |
end try | |
return POSIX path of source_folder as string'` | |
cd "$finderPath" |
People
![]() :bowtie: |
π :smile: |
π :laughing: |
---|---|---|
π :blush: |
π :smiley: |
:relaxed: |
π :smirk: |
π :heart_eyes: |
π :kissing_heart: |
π :kissing_closed_eyes: |
π³ :flushed: |
π :relieved: |
π :satisfied: |
π :grin: |
π :wink: |
π :stuck_out_tongue_winking_eye: |
π :stuck_out_tongue_closed_eyes: |
π :grinning: |
π :kissing: |
π :kissing_smiling_eyes: |
π :stuck_out_tongue: |
// 3D Dom viewer, copy-paste this into your console to visualise the DOM as a stack of solid blocks. | |
// You can also minify and save it as a bookmarklet (https://www.freecodecamp.org/news/what-are-bookmarklets/) | |
(() => { | |
const SHOW_SIDES = false; // color sides of DOM nodes? | |
const COLOR_SURFACE = true; // color tops of DOM nodes? | |
const COLOR_RANDOM = false; // randomise color? | |
const COLOR_HUE = 190; // hue in HSL (https://hslpicker.com) | |
const MAX_ROTATION = 180; // set to 360 to rotate all the way round | |
const THICKNESS = 20; // thickness of layers | |
const DISTANCE = 10000; // Β―\\_(γ)_/Β― |
find /System/Library/LaunchDaemons /System/Library/LaunchAgents -name "*.plist" \ | |
| while read p ; do plutil -convert json -o - ${p} \ | |
| jq -r ' .. | objects | with_entries(select(.key == "Notification")) | select(. != {}).Notification' | |
done | sort -u > ~/Desktop/all-launchd-notifications.txt |
This is a cheat sheet for how to perform various actions to ZSH, which can be tricky to find on the web as the syntax is not intuitive and it is generally not very well-documented.
Description | Syntax |
---|---|
Get the length of a string | ${#VARNAME} |
Get a single character | ${VARNAME[index]} |