This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Original from http://ryanbigg.com/2013/08/bundler-local-paths/ | |
> bundle config local.spree ~/Projects/gems/spree | |
- creates ~/.bundle/config | |
- which is used by all projects/apps | |
# Per app | |
> bundle config --local local.gem "path/to/local/gem" | |
- note: I had to manually cd into project/app directory to get this to create the file at 'app/.bundle/config' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#AppleScript | |
#- bounce wifi: turn it off, then turn it on | |
#- open AppleScript Editor, paste lines 4,5,6, save as application | |
#- ** oh be sure to set the network_device -- en0 in my case to the correct interface | |
set network_device to "en0" | |
do shell script "networksetup -setairportpower " & network_device & " off" | |
do shell script "networksetup -setairportpower " & network_device & " on" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
I have a directive (errorhandler, see below) that is restricted to Element and Attribute | |
Currently, I've got two separate two way bindings, and two separate watchers: | |
one for the element case, one for the attribute case | |
** Is there a way to conditionally set the directives isolate scope? | |
scope : { | |
errors : "=????" //use errorhandler value if available, else use @error value |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
I ran into a problem trying to go to https://github.com using Google Chrome | |
where I'd get an ssl/security warning saying the certificate is not trusted. | |
I tracked this down to an expired Digicert Certificate. | |
After chasing around the web, one solution I saw was to reinstall the os x | |
10.9.2 update. But that won't work, cuz I'm on 10.9.4. | |
TL;DR: I chat w/ Logan over at Digicert... Boom. Fixed. Thanks Logan! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
atm = psi | |
============ | |
1.0 = 14.696 | |
1.1 = 16.166 | |
1.2 = 17.635 | |
1.3 = 19.105 | |
1.4 = 20.574 | |
1.5 = 22.044 | |
1.6 = 23.514 | |
1.7 = 24.983 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#bounce bluetooth | |
set unload to "kextunload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport" | |
set load to "kextload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport" | |
do shell script unload with administrator privileges | |
do shell script load with administrator privileges |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# from: http://blog.pivotal.io/labs/labs/a-simple-way-to-detect-unused-files-in-a-project-using-git | |
# `git ls-files` -> get a list of files from a directory | |
# `git grep` + loop -> check for reference to file in repo | |
# list or remove the file | |
# dry run: just list the unused files | |
for FILE in $(git ls-files ./img); do | |
git grep $(basename "$FILE") > /dev/null || echo "would remove $FILE" | |
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# adapted from: https://gist.github.com/adgedenkers/3874427 | |
# VPN_NAME is the name of your vpn | |
-- adapted from https://gist.github.com/adgedenkers/3874427 | |
tell application "System Events" | |
-- start playing with the VPN | |
tell current location of network preferences | |
-- set the name of the VPN service from your Network Settings | |
set VPNService to service "VPN_NAME" | |
-- determine current VPN connection status |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# git: delete local + remote tag | |
git tag -d TagName && git push origin :refs/tags/TagName | |
# git: checkout file from a different branch | |
git checkout <branch_name> -- <paths> | |
http://nicolasgallagher.com/git-checkout-specific-files-from-another-branch/ | |
# vim: find instances of uncommented out console statements | |
search mode / then \(\/\/.*\)\@<!console |
OlderNewer