Skip to content

Instantly share code, notes, and snippets.

function mdclean {
# TEST
# echo -e $"**TITLE**\n* hello\n\t* world\n \t* :wave:" | sed -E "s/^([ $(printf '\t')]*)\* /\1- /"
pbpaste | \
/usr/bin/sed -E "s/^([ $(printf '\t')]*)\* /\1- /" | \
pbcopy
}

Things to do in London

  1. Harrod's, especially the food halls

  2. Hamley's (world's oldest and largest toy store)

  3. Oxford Street (equivalent of 5th avenue), especially Selfridge's

  4. Hyde Park (there's a Christmas Fair here)

-- https://gist.github.com/swinton/9f0be6bc451b614c7d02fa5d47e6d5e7
on alfred_script(q)
set cmd to q
tell application "iTerm"
activate
tell current window
set t to (create tab with default profile)
set s to current session of t
tell s to write text cmd
end tell

I got HookHand working locally, it’s pretty interesting, I feel like the way it exposes webhook data as environment variables might be fairly tricky to work with:

  • First:
cat ~/scratch/HookHand/scripts/test

#!/bin/sh
echo "TEST!"
echo "parameters: $*"
echo "HOOKHAND* environment variables:"

HELLO WORLD

👋 🌎

@swinton
swinton / gh-org-members.sh
Last active December 5, 2017 16:46
Exports members of GitHub org as a CSV
#!/bin/bash
#
# Exports members of an org as a CSV
# Usage:
# ./gh-org-members.sh > members.csv
# Dependencies:
# - jq (https://github.com/stedolan/jq)
export GITHUB_TOKEN="[your personal access token]"

Keybase proof

I hereby claim:

  • I am swinton on github.
  • I am swinton (https://keybase.io/swinton) on keybase.
  • I have a public key ASAnfVFPL9bXH-HShRSoef5uZaz89bq_jD0vz3QwneDrMQo

To claim this, I am signing this object:

Albums that have stayed with me, and always will

Just a dumping ground for now...

  1. The Cure - Standing on a Beach
  2. The Cure - Disintegration
  3. Metallica - And Justice For All...
  4. Iron Maiden - Iron Maiden
  5. Primal Scream - Screamadelica
  6. Ride - Nowhere

Most of my friends know I practice Immigration law. As such, I have worked with the refugee community for over two decades. This post is long, but if you want actual information about the process, keep reading.

I can not tell you how frustrating it is to see the misinformation and outright lies that are being perpetuated about the refugee process and the Syrian refugees. So, here is a bit of information from the real world of someone who actually works and deals with this issue. The refugee screening process is multi-layered and is very difficult to get through. Most people languish in temporary camps for months to years while their story is evaluated and checked.

First, you do not get to choose what country you might be resettled into. If you already have family (legal) in a country, that makes it more likely that you will go there to be with family, but other than that it is random. So, you can not simply walk into a refugee camp, show a document, and say, I want to go to America. Instead, the UNHCR (Unit