Skip to content

Instantly share code, notes, and snippets.

View cori's full-sized avatar
🏠
Scruggs!

cori schlegel cori

🏠
Scruggs!
View GitHub Profile
jq -r 'paths(scalars) as $p | "." + ([([$p[] | tostring] | join(".")), (getpath($p) | tojson)] | join(": "))'
@cori
cori / sorting-aws-cli-describe-images-output.md
Created October 27, 2021 15:36 — forked from michalstala/sorting-aws-cli-describe-images-output.md
How to sort AWS CLI describe-images output using jd

As an example query AWS for a list of all NAT Instance AMIs:


aws ec2 describe-images --filter Name="owner-alias",Values="amazon" --filter Name="name",Values="amzn-ami-vpc-nat*" --region us-west-2 | jq '.Images | sort_by(.CreationDate)'

If only specific fields are required to print into output:

@cori
cori / roam-quick-capture.js
Last active March 30, 2023 03:50
Roam Quick Capture with Page Title Userscript
// ==UserScript==
// @name Roam Quick Note with Page Title
// @version 0.0.1
// @description Quick notes selected text to Roam.
// @author cori schlegel
// @match *
// @grant GM.registerButton
// @grant GM.openInTab
// @noframes
// ==/UserScript==