Skip to content

Instantly share code, notes, and snippets.

@jasoncodes
jasoncodes / README
Last active August 14, 2023 03:29
Notion uncheck all bookmarklet
A simple bookmarklet to uncheck all the checkboxes (including nested checkboxes) in the current Notion document.
Minified using http://chriszarate.github.io/bookmarkleter/.
@jasoncodes
jasoncodes / README
Created September 19, 2018 03:43
JSON bookmarklet
A basic bookmarklet to make JSON readable.
Minified using http://chriszarate.github.io/bookmarkleter/.
require 'bundler'
Bundler.configure
require 'bundler/inline'
gemfile do
source 'http://rubygems.org'
gem 'activesupport', require: 'active_support/all'
gem 'aws-sdk-s3'
gem 'parallel'
@jasoncodes
jasoncodes / README
Last active June 29, 2018 01:30
Expand GitHub Pull Requests
Show outdated comments and large diffs on GitHub Pull Requests.
Minified using http://chriszarate.github.io/bookmarkleter/.
#!/usr/bin/env perl
use strict;
use warnings FATAL => 'all';
{
package pushd;
use Cwd qw(getcwd chdir);
sub new {
keys = [
%w[a 1 x],
%w[a 1 y],
%w[a 2 x],
%w[a 3 x],
%w[a 3 y],
%w[b 3 y],
%w[b 4 z],
]
@jasoncodes
jasoncodes / README
Last active August 29, 2015 14:14
Disable Hyphenation and Justification Bookmarklet
Disables hyphenation and full text justification.
Minified using http://chriszarate.github.io/bookmarkleter/.
@jasoncodes
jasoncodes / fix-bash.sh
Last active August 29, 2015 14:06
Shellshock (CVE-2014-6271 and CVE-2014-7169) patch for OS X 10.9 Mavericks
#!/bin/bash -e
# Shellshock (CVE-2014-6271 and CVE-2014-7169) patch for OS X 10.9 Mavericks
# Based on http://apple.stackexchange.com/a/146851
cd /tmp
mkdir bash-fix
cd bash-fix
curl https://opensource.apple.com/tarballs/bash/bash-92.tar.gz | tar zxf -
cd bash-92/bash-3.2
@jasoncodes
jasoncodes / missing_foreign_key_constraints_spec.sql
Created September 1, 2014 04:51
Find missing foreign key constraints
SELECT CONCAT(col.table_name, '.', col.column_name)
FROM information_schema.columns col
INNER JOIN pg_catalog.pg_tables tbl ON tbl.schemaname = col.table_schema AND tbl.tablename = col.table_name
LEFT JOIN information_schema.columns col_type ON (
col.table_schema = col_type.table_schema AND
col.table_name = col_type.table_name AND
regexp_replace(col.column_name, '_id$', '_type') = col_type.column_name
)
LEFT JOIN (
(
@jasoncodes
jasoncodes / keybase.md
Created March 12, 2014 05:29
Keybase proof

Keybase proof

I hereby claim:

  • I am jasoncodes on github.
  • I am jasoncodes (https://keybase.io/jasoncodes) on keybase.
  • I have a public key whose fingerprint is 00FE 9E5D 9F6E DBF2 B03E 971E CA17 A856 9172 8429

To claim this, I am signing this object: