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
# Updates all git repositories within a directory - Works on Mac (mention it here as other scripts did not) | |
# Assumption #1 - leading branch name is `master` - this changed to be `main` recently - check please in advance | |
# Assumption #2 - working with forks only using the git remote named `upstream` | |
# Assumption #3 - Having clean git repositories - no changed files | |
find . -maxdepth 2 -name '.git' -prune -type d -exec dirname {} \; | parallel --eta 'echo {} && git -C {} checkout master && git -C {} fetch upstream && git -C {} rebase -f upstream/master' | |
# Simplified version using no fork and origin only | |
# find . -maxdepth 2 -name '.git' -prune -type d -exec dirname {} \; | parallel --eta 'echo {} && git -C {} checkout master && git -C {} pull' |
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
import jQuery from 'jquery/dist/jquery' | |
/* | |
* Override the bootstrap 3.3.7 Tooltip.getPosition() function to fix | |
* position issues with SVG elements when the page/viewport is scrolled. | |
*/ | |
;(function ($) { | |
// const original = $.extend(true, {}, $.fn.tooltip.Constructor.prototype) | |
const extension = { |
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
# Install ttfautohint on Ubuntu 12.04 LTS | |
# @author: Jean Lescure | |
# 2014/04/23 | |
# Clone ttfautohint git repo to 'tmp' dir and cd into resulting repo folder | |
cd /tmp | |
git clone http://repo.or.cz/ttfautohint.git | |
cd ttfautohint | |
# Handle bootstrap's dependency: automake |
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
// # Mocha Guide to Testing | |
// Objective is to explain describe(), it(), and before()/etc hooks | |
// 1. `describe()` is merely for grouping, which you can nest as deep | |
// 2. `it()` is a test case | |
// 3. `before()`, `beforeEach()`, `after()`, `afterEach()` are hooks to run | |
// before/after first/each it() or describe(). | |
// | |
// Which means, `before()` is run before first it()/describe() |
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
<!DOCTYPE html> | |
<meta charset="utf-8"> | |
<title>Zoom + Pan</title> | |
<style> | |
.overlay { | |
fill: none; | |
pointer-events: all; | |
} | |
div{border:1px solid black; margin: 10px;} |