Skip to content

Instantly share code, notes, and snippets.

View dalemanthei's full-sized avatar

Dale Manthei dalemanthei

  • Great White North, eh.
View GitHub Profile
@dalemanthei
dalemanthei / init.lua
Last active March 12, 2017 08:21
Hamerspoon config examples for hyper key
-- hattip https://github.com/lodestone/hyper-hacks
-- hattip https://gist.github.com/ttscoff/cce98a711b5476166792d5e6f1ac5907
-- hattip https://gist.github.com/prenagha/1c28f71cb4d52b3133a4bff1b3849c3e
-- A global variable for the Hyper Mode
k = hs.hotkey.modal.new({}, "F17")
-- The following keys are configured as hot keys in their respective apps (or in Keyboard Maestro)
-- d → Dash (configure in Dash preferences)
@dalemanthei
dalemanthei / _.md
Created September 19, 2016 17:30
y axes times 3
@dalemanthei
dalemanthei / _.md
Created September 19, 2016 15:43
reddit base number 2
@dalemanthei
dalemanthei / _.md
Created September 19, 2016 15:33
reddit base number 2
@dalemanthei
dalemanthei / _.md
Created September 19, 2016 15:29
reddit base
@dalemanthei
dalemanthei / _.md
Last active September 16, 2016 18:57
reddit base
@dalemanthei
dalemanthei / path.sublime-project
Created January 31, 2016 20:16
Sublime Text 3 standard path block to add external folder to project and exclude all the gorp
{
"path": "/<path-to-project-folder>",
"folder_include_patterns": [],
"folder_exclude_patterns": ["**/jspm_packages", "**/node_modules", "**/target", "**/.settings", "**/.externalToolBuilders"],
"file_exclude_patterns": [".gitignore", ".jazzignore", "pom.xml", ".factorypath", ".project"]
},
@dalemanthei
dalemanthei / provide-$log.js
Last active January 24, 2016 22:43
Enable $log for production AngularJS running in Jasmine
beforeEach(module('myApp', function($provide) {
$provide.value('$log', console);
}));
@dalemanthei
dalemanthei / filter-from-injector.js
Last active January 24, 2016 22:41
A Jasmine beforeEach function to get a filter for testing
var myFilter;
beforeEach(function () {
module('myModule');
inject(function ($injector) {
myFilter = $injector.get('$filter')('myFilter');
});
});
@dalemanthei
dalemanthei / compileDirective.js
Created January 24, 2016 22:40
Jasmine-helper-compileDirective.js
var compileDirective = function (html, scope) {
element = $compile(angular.element(html))(scope);
scope.$digest();
return element;
};