Skip to content

Instantly share code, notes, and snippets.

Mikki kobvel

View GitHub Profile
ohh2ahh / increment_build_number.js
Created Jun 1, 2015
Cordova hook for incrementing build numbers
View increment_build_number.js
#!/usr/bin/env node
// Save hook under `project-root/hooks/before_prepare/`
// Don't forget to install xml2js using npm
// `$ npm install xml2js`
var fs = require('fs');
var xml2js = require('xml2js');
lttlrck / gist:9628955
Created Mar 18, 2014
rename git branch locally and remotely
View gist:9628955
git branch -m old_branch new_branch # Rename branch locally
git push origin :old_branch # Delete the old branch
git push --set-upstream origin new_branch # Push the new branch, set local branch to track the new remote
binarymax / canvasfloodfill.js
Created Nov 14, 2012
Javascript Canvas FloodFill functions
View canvasfloodfill.js
//MIT License
//Author: Max Irwin, 2011
//Floodfill functions
function floodfill(x,y,fillcolor,ctx,width,height,tolerance) {
var img = ctx.getImageData(0,0,width,height);
var data =;
var length = data.length;
var Q = [];
var i = (x+y*width)*4;
You can’t perform that action at this time.