This file contains hidden or 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
public static class IDictionaryExtension | |
{ | |
public static JsonDictionary<K, V> ToJsonDictionary<K,V>(this IDictionary<K, V> dict) | |
{ | |
if (dict == null) | |
return null; | |
var jsonDict = new JsonDictionary<K, V>(); | |
foreach (var key in dict.Keys) | |
{ | |
jsonDict[key] = dict[key]; |
This file contains hidden or 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
#!/usr/bin/env ruby | |
# require all the necessary files | |
$: << ::File.expand_path('../src', __FILE__) | |
require 'app' | |
require 'geofence' | |
# at this point bundler should be setup and the :development group | |
# should have been included. However, just to be sure, I'm going to | |
# include bundler again and require the console group. |
This file contains hidden or 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
require 'bundler/setup' | |
bundler.require(:development, :test, :console) | |
$: << File.expand_path('../src', __FILE__) | |
require 'app' | |
require 'models/user_account' | |
require 'models/car' | |
# Load config and connect to DB | |
App.init() |
This file contains hidden or 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
#!/bin/bash | |
# Load the keyboard back. (Should probably do this | |
# while the external one is still attached.) | |
sudo kextload /System/Library/Extensions/AppleUSBTopCase.kext/Contents/PlugIns/AppleUSBTCKeyboard.kext/ |
This file contains hidden or 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
#!/bin/bash | |
# Unload the keyboard so I can use my external keyboard | |
# and not worry about accidentally pressing buttons on | |
# the built-in. This may not be a problem for you but, you | |
# should see my desk sometimes (Oh no!!) ;-) | |
sudo kextunload /System/Library/Extensions/AppleUSBTopCase.kext/Contents/PlugIns/AppleUSBTCKeyboard.kext/ |
NewerOlder