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/sh | |
| container=$1 | |
| pass=$2 | |
| if [ -z "$container" ] || [ -z "$pass" ]; then | |
| echo "usage: $0 container newRootPassword" | |
| exit | |
| fi | |
| mysql_image=$(docker inspect $container --format "{{ .Config.Image }}") |
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
| <!doctype html> | |
| <html> | |
| <title>Flatten.js, General SVG Flattener</title> | |
| <head> | |
| <script> | |
| /* | |
| Random path and shape generator, flattener test base: https://jsfiddle.net/fjm9423q/embedded/result/ | |
| Basic usage example: https://jsfiddle.net/nrjvmqur/embedded/result/ |
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/sh | |
| # @author Rob Wu <gwnRob@gmail.com> (https://robwu.nl) | |
| version=$1 | |
| if [[ "${version}" != *"."* ]] ; then | |
| echo "Repeat the command with an exact version:" | |
| suffix="[0-9.]*" | |
| # Version not specified in $1 | |
| [ -z $version ] && suffix="[0-9][0-9.]+" | |
| curl -s http://www.oldapps.com/google_chrome.php | grep -oP "google_chrome.php\?old_chrome=[0-9]+\">[A-Za-z ]+\K${version}${suffix}( [A-Za-z()]+)?" -m 10 | |
| elif [ -e "${version}_chrome_installer.exe" ] ; then |
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
| <?php | |
| if (!class_exists('Tax_CTP_Filter')){ | |
| /** | |
| * Tax CTP Filter Class | |
| * Simple class to add custom taxonomy dropdown to a custom post type admin edit list | |
| * @author Ohad Raz <admin@bainternet.info> | |
| * @version 0.1 | |
| */ | |
| class Tax_CTP_Filter | |
| { |
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
| function WindowController () { | |
| this.id = Math.random(); | |
| this.isMaster = false; | |
| this.others = {}; | |
| window.addEventListener( 'storage', this, false ); | |
| window.addEventListener( 'unload', this, false ); | |
| this.broadcast( 'hello' ); |
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
| /* | |
| * Takes provided URL passed as argument and make screenshots of this page with several viewport sizes. | |
| * These viewport sizes are arbitrary, taken from iPhone & iPad specs, modify the array as needed | |
| * | |
| * Usage: | |
| * $ casperjs screenshots.js http://example.com | |
| */ | |
| var casper = require("casper").create(); |
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
| /* | |
| * Normalized hide address bar for iOS & Android | |
| * (c) Scott Jehl, scottjehl.com | |
| * MIT License | |
| */ | |
| (function( win ){ | |
| var doc = win.document; | |
| // If there's a hash, or addEventListener is undefined, stop here | |
| if( !location.hash && win.addEventListener ){ |
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
| # Rename tags named foo-bar-#.#.# to v#.#.# and push the tag changes | |
| git tag -l | while read t; do n="v${t##*-}"; git tag $n $t; git push --tags ; git tag -d $t; git push origin :refs/tags/$t ; done |