Skip to content

Instantly share code, notes, and snippets.

View kumar303's full-sized avatar
💭
🍉

Kumar McMillan kumar303

💭
🍉
View GitHub Profile
@kumar303
kumar303 / gist:9371022
Created March 5, 2014 16:43
brew troubleshooting output
$ brew doctor
Warning: A Python is installed in /Library/Frameworks
Homebrew only supports building against the System-provided Python or a
brewed Python. In particular, Pythons installed to /Library can interfere
with other software installs.
Warning: /usr/local/share/python is not needed in PATH.
Formerly homebrew put Python scripts you installed via `pip` or `pip3`
(or `easy_install`) into that directory above but now it can be removed
@kumar303
kumar303 / gist:9652343
Created March 19, 2014 22:00
uglify example
module.exports = function(grunt) {
grunt.initConfig({
uglify: {
my_target: {
files: {
'build/myscript.min.js': ['lib/myscript.js']
}
}
}
});
@kumar303
kumar303 / gist:9652380
Created March 19, 2014 22:01
karma example
module.exports = function(grunt) {
grunt.initConfig({
karma: {
run: {
configFile: 'karma.conf.js',
singleRun: true
},
},
});
@kumar303
kumar303 / gist:9652404
Created March 19, 2014 22:02
karma dev example
grunt.initConfig({
karma: {
dev: {
configFile: 'karma.conf.js',
autoWatch: true
}
}
});
@kumar303
kumar303 / gist:9652415
Last active August 29, 2015 13:57
mocha example
describe('fxpay', function() {
describe('purchase()', function() {
it('should error if mozPay() is undefined', function(done) {
var productId = '123';
fxpay.purchase(productId, {
onpurchase: function(error) {
assert.equal(error, 'PAY_PLATFORM_UNAVAILABLE');
done();
},
@kumar303
kumar303 / gist:9652425
Last active August 29, 2015 13:57
sinon example
describe('fxpay', function () {
describe('API', function() {
var api;
var server;
beforeEach(function() {
api = new fxpay.API();
server = sinon.fakeServer.create();
});
@kumar303
kumar303 / gist:9652443
Created March 19, 2014 22:04
PhantomJS example
grunt.initConfig({
karma: {
run: {
configFile: 'karma.conf.js',
singleRun: true,
browsers: ['PhantomJS']
},
}
});
@kumar303
kumar303 / gist:9652453
Created March 19, 2014 22:05
travis ci example
language: node_js
node_js:
- 0.10
before_script:
- npm rebuild
script: grunt karma:run
@kumar303
kumar303 / gist:9652462
Created March 19, 2014 22:06
travis ci browser example
before_script:
- npm rebuild
- "export DISPLAY=:99.0"
- "sh -e /etc/init.d/xvfb start"
@kumar303
kumar303 / gist:9652470
Created March 19, 2014 22:06
jshint example
grunt.initConfig({
jshint: {
options: { jshintrc: __dirname + '/.jshintrc' },
files: [
'Gruntfile.js',
'lib/*.js',
'test/*.js',
],
}
});