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
(1.7.9+) | |
Stores password in cache for 15 minutes (default): | |
git config --global credential.helper cache | |
Define custom timeout: | |
git config credential.helper 'cache --timeout=3600' | |
OS Keystore: | |
git config --global credential.helper osxkeychain |
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
In the unfortunate case where a branch other than master is often used - or becomes the new "master" - and a replacement of master with it is required, execute the following codes: | |
git checkout branchie | |
git merge -s ours master | |
git checkout master | |
git merge branchie |
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
/** | |
* st/filemanager.js | |
* FileManager | |
* | |
* Dependencies: | |
* - jQuery | |
* - StoryTroop (st/storytroop) | |
* - StoryTroop.ui (st/ui) | |
* - Mustache (lib/mustache-wp) | |
*/ |
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
var parser = document.createElement('a'); | |
parser.href = "http://example.com:3000/pathname/?search=test#hash"; | |
parser.protocol; // => "http:" | |
parser.hostname; // => "example.com" | |
parser.port; // => "3000" | |
parser.pathname; // => "/pathname/" | |
parser.search; // => "?search=test" | |
parser.hash; // => "#hash" | |
parser.host; // => "example.com:3000" |
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() { | |
var myLoader = require.config( { | |
baseUrl: '/js' | |
// any other settings here. | |
}); | |
myLoader( [ 'list', 'of', 'deps' ], function( dep1, dep2, dep3 ) { | |
/* do stuff here */ | |
}); | |
}()) |
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
/** | |
* ttpopover.js v0.2 | |
* TT PopOver plugin | |
* @author Rodrigo Z. Arthuso | |
* | |
* Requires jQuery 1.7+, mustache.js 0.5+ | |
* | |
* @TODO Review update position on resize | |
*/ |
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
var selection = jQuery([ "item1", "item2", "item3" ]), | |
pop = [].pop; | |
console.log( pop.call( selection ), selection.length, selection[1] ); | |
// output: "item3" 2 "item2" |
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
# Magento | |
server { | |
listen 80; | |
server_name store; | |
error_log /var/log/nginx/store.error_log; | |
root /home/rod/www/magento; | |
index index.php; | |
location / { |
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
$(document).ready(function() { | |
if ($.browser.msie && $.browser.version.charAt(0) < 9) myScript.ieSelectFixedWidth('select.mini, select.medium'); | |
} | |
// ... | |
var myScript = { | |
ieSelectFixedWidth: function(el) { | |
$(el).each(function(k, v) { | |
var obj = $(v); |
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
/* | |
* Small workaround to support the 'placeholder' attribute found on HTML5's input elements. | |
* This version requires jquery 1.6+ | |
*/ | |
var myScript = ( function( $ ) { | |
function placeHolderFallback() { | |
var forms = $( 'form' ); | |
if ( forms.length > 0 ) { |
NewerOlder