A ZSH theme optimized for people who use:
- Solarized
- Git
- Unicode-compatible fonts and terminals (I use iTerm2 + Menlo)
For Mac users, I highly recommend iTerm 2 + Solarized Dark
## This gist is intended to provide a code example for the | |
# 'Making Signed Requests' section of the 'Authentication Overview' document. | |
# (http://developer.netflix.com/docs/Security). | |
# | |
# We are going to make a catalog request. The hardest part of | |
# it is figuring out how to generate the oauth_signature. | |
require 'cgi' | |
require 'base64' | |
require 'openssl' |
Navigation: | |
cmd-p Goto Anything ('@' for functions, ':' for line number) | |
cmd-r Function finder | |
ctl-g Goto line number | |
cmd-sft-p Command palette | |
cmd-sft-f Find in Files | |
cmd-opt-r Toggle regex when finding | |
cmd-opt-# Columns | |
ctr-# Switch columns |
#!/bin/sh | |
### | |
# SOME COMMANDS WILL NOT WORK ON macOS (Sierra or newer) | |
# For Sierra or newer, see https://github.com/mathiasbynens/dotfiles/blob/master/.macos | |
### | |
# Alot of these configs have been taken from the various places | |
# on the web, most from here | |
# https://github.com/mathiasbynens/dotfiles/blob/5b3c8418ed42d93af2e647dc9d122f25cc034871/.osx |
require "spec_helper" | |
describe ExampleController do | |
context "GET #index" do | |
let(:resources) { FactoryGirl.create_list(:resource) } | |
before do | |
get :index | |
end |
#!/usr/bin/env sh | |
# Filename: update-hosts.sh | |
# Authors: George Lesica <george@lesica.com> | |
# Danilo Fasolin Salmazio <dfasolin@gmail.com> | |
# Description: Replaces the HOSTS file with a customized version (hosts-file.net) that blocks | |
# domains that serve ads and malicious software, creating a backup of the old | |
# file. | |
# Improvements: Add the partial file, a /etc/hosts_dev with some development hosts and creates | |
# a logfile |
@UIApplicationMain | |
final class AppDelegate: UIResponder, UIApplicationDelegate { | |
let healthKitManager = HealthKitManager() | |
func application(application: UIApplication, didFinishLaunchingWithOptions launchOptions: [NSObject: AnyObject]?) -> Bool { | |
if onboardingComplete { | |
healthKitManager.requestAccessWithCompletion() { success, error in | |
if success { print("HealthKit access granted") } | |
else { print("Error requesting access to HealthKit: \(error)") } | |
} |
heroku pg:backups:restore
to upload your Postgres db dump.