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
#!/bin/bash | |
if [[ $EUID -ne 0 ]]; then | |
echo "You must be a root user" 2>&1 | |
exit 1 | |
fi | |
echo "<VirtualHost *:80> | |
ServerAdmin admin@example.co.nz | |
ServerName $1 |
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
<?php | |
/** | |
* WordPress Query Comprehensive Reference | |
* Compiled by luetkemj - luetkemj.com | |
* | |
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters | |
* Source: https://core.trac.wordpress.org/browser/tags/3.9/src/wp-includes/query.php | |
*/ | |
$args = array( |
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
#!/bin/bash | |
# Pre-commit hook to make a mysql dump right before committing and add it to the commit. | |
# | |
# Change the following values to suit your local setup. | |
# Add this file on your .git/hooks/ and name it as 'pre-commit' | |
# | |
# The name of a database user with read access to the database. | |
DBUSER=[dbuser] |
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
#!/bin/bash | |
# Post-merge hook to add a mysql db when post-merge occurs. | |
# | |
## Change the following values to suit your local setup. | |
# The name of a database user with read access to the database. | |
DBUSER=[dbuser] | |
# The password associated with the above user. Leave commented if none. | |
DBPASS=[dbpass] |
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
var custom_menu = { | |
handle_colors: function(){ | |
// by default this works with $(window).on('load resize scroll') | |
$('.scroller').on('load resize scroll', function(){ | |
var index_item = custom_menu._get_index(), | |
class_item = $('.wrapper-milkguard:eq('+index_item+')').data('menu-color') |
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
ExpiresActive On | |
ExpiresDefault A0 | |
# 1 WEEK - possible to be changed, unlikely | |
<FilesMatch "\.(jpg|jpeg|png|gif|swf)$"> | |
ExpiresDefault A604800 | |
</FilesMatch> | |
# 3 HOUR - core content, changes quickly | |
<FilesMatch "\.(txt|xml|js|css)$"> |
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
# Open your bashprofile | |
alias openbash="subl ~/.bash_profile"; | |
# Thanks to jamie@blacksheepdesign.co.nz | |
alias showFiles="defaults write com.apple.finder AppleShowAllFiles YES; killall Finder /System/Library/CoreServices/Finder.app"; | |
alias hideFiles="defaults write com.apple.finder AppleShowAllFiles NO; killall Finder /System/Library/CoreServices/Finder.app"; | |
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
# Find .htaccess and do chmod | |
sudo find / -type f -name '.htaccess' -exec chmod 604 {} \; | |
# Find wp-config.php and do chmod | |
sudo find / -type f -name 'wp-config.php' -exec chmod 644 {} \; |
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
/* | |
# Usage for your Javascript | |
$(document).ready(function(){ | |
var animate_squared = new animation({ | |
obj: '#your-tag .item', | |
}); |
OlderNewer