Skip to content

Instantly share code, notes, and snippets.

View alyssais's full-sized avatar
🤒
Out sick

Alyssa Ross alyssais

🤒
Out sick
View GitHub Profile
@alyssais
alyssais / statement.txt
Created January 7, 2018 21:03
OpenPGP key transition statement
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256
Date: 2018-01-07
For a number of reasons, I have recently set up a new OpenPGP key,
and will be transitioning away from my old one.
The old key will continue to be valid for some time, but I prefer all
future correspondence to come to the new one. I would also like this
diff --git a/old.txt b/new.txt
index 9cf6209..760786a 100644
--- a/old.txt
+++ b/new.txt
@@ -12,7 +12,7 @@ These Terms of Service (“Terms”) govern your access to and use of our servic
4. Using the Services
5.[-Disclaimers and-] Limitations of Liability

Keybase proof

I hereby claim:

  • I am alyssais on github.
  • I am qyliss (https://keybase.io/qyliss) on keybase.
  • I have a public key whose fingerprint is 03C0 7C9C CD55 DDA6 1F73 4F02 ED0A E8D0 A913 FDC2

To claim this, I am signing this object:

@alyssais
alyssais / Brewfile
Last active August 17, 2017 15:25
Automatic Wordpress development environment setup using Homebrew (https://brew.sh), Composer (https://getcomposer.org), and Scripts to Rule Them All (https://githubengineering.com/scripts-to-rule-them-all/). Dashes in filenames represent directory separators. License CC0.
tap "homebrew/php"
brew "php71"
brew "mysql"
brew "composer"
@alyssais
alyssais / rugged_leak.rb
Created April 18, 2017 14:46
Investigating a potential memory leak in the Rugged gem
require "rugged"
def diff_parents(commit)
puts commit.oid
commit.parents.each { |parent| parent.diff(commit) }
commit.parents.each { |parent| diff_parents(parent) }
rescue SystemStackError
end
path = "#{__dir__}/rails"
@alyssais
alyssais / install_terminal_theme.sh
Created October 7, 2016 15:23
Installs an Apple Terminal theme. Usage: `install_terminal_theme.sh /path/to/MyTheme.theme`.
#!/bin/sh
set -ue
# Open the theme in Terminal to install it
open -b com.apple.Terminal "$1"
# Close the Terminal window we just opened.
osascript > /dev/null <<OSA
tell application "Terminal"
do script "exit" in selected tab of front window
@alyssais
alyssais / mas-bootstrap.rb
Created September 10, 2016 12:43
Automated Xcode installation on pre-release OS X with mas-cli. mas-cli requires Xcode to compile, so this script downloads a binary of mas-cli, uses it just to install Xcode, then uses the newly installed Xcode to compile mas-cli and replace the pre-compiled binary.
#!/usr/bin/env ruby
require "open-uri"
require "json"
RELEASES_URL = "https://api.github.com/repos/argon/mas/releases"
ASSET_NAME = "mas-cli.zip"
EXECUTABLE_NAME = "mas"
XCODE_ID = "497799835"
@alyssais
alyssais / play.html
Last active April 10, 2016 09:35
This is an HTML file that can be added to the Home Screen on an iPhone. It will open Castro and start playing when tapped. I used to use Workflow for this, but waiting for Workflow to launch was frustrating.
<!doctype html>
<html>
<head>
<title>Castro Play</title>
<meta charset="utf-8">
<meta name="apple-mobile-web-app-capable" content="yes">
<link rel="apple-touch-icon" href="data:image/png;base64,
iVBORw0KGgoAAAANSUhEUgAABAAAAAQACAYAAAB/HSuDAAAAAXNSR0IArs4c
6QAAQABJREFUeAHsvVuWJTmuJXYjb0yiPyRN4Vbpr6tKU5HW0kTuvKRuqbvV
0rBS2AA3CYK0QzM/HuGRWZux3ACSIEhu4sFj/ohv/8v/9z///vu//P4vXkC+
@function null-check($name, $args...) {
@if nth($args, 1) {
@return call($name, $args...);
}
@return null;
}
html {
background: null-check(lighten, blue, 5%);
}
@alyssais
alyssais / backup_passwords.sh
Created February 21, 2016 16:54
Sometimes I need access to my 1Password database on another computer. This launchd task will automatically copy my database to a USB drive as soon as it's changed.
#!/bin/sh
if ! [ -d "/Volumes/RECOVERY" ]; then
echo "Not connected"
exit 1
fi
mkdir -p "/Volumes/RECOVERY/passwords"
rsync -az --delete --exclude ".DS_Store" \
"/Users/penman/dropbox/Apps/1Password/1Password.agilekeychain" \
"/Volumes/RECOVERY/passwords"