Skip to content

Instantly share code, notes, and snippets.

@chrisgoffinet
chrisgoffinet / fcc.zsh
Created January 1, 2022 04:48
access clipboard using zsh + maccy
fcc() {
DB=~/Library/Containers/org.p0deje.Maccy/Data/Library/Application\ Support/Maccy/Storage.sqlite
SQL="select distinct ZVALUE
from ZHISTORYITEMCONTENT
where ZTYPE IN ('public.text','public.utf8-plain-text')
order by Z_PK desc"
if ! [ -r "$DB" ]; then
MSG='Maccy database not found. "brew cask install maccy" to install Maccy.'
echo "$MSG"
@staltz
staltz / introrx.md
Last active September 25, 2024 09:04
The introduction to Reactive Programming you've been missing
@vpalos
vpalos / options.js
Created May 20, 2011 07:29
JS: CLI argument parser.
/** Command-line options parser (http://valeriu.palos.ro/1026/).
Copyright 2011 Valeriu Paloş (valeriu@palos.ro). All rights reserved.
Released as Public Domain.
Expects the "schema" array with options definitions and produces the
"options" object and the "arguments" array, which will contain all
non-option arguments encountered (including the script name and such).
Syntax:
[«short», «long», «attributes», «brief», «callback»]