Instance | Branch |
---|
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
body { | |
text-align: center; | |
> #container { | |
text-align:left; | |
margin:0 auto; | |
width:500px; | |
} | |
} | |
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
/** | |
* Calculator, hand-coded only with HTML and CSS3. | |
*/ | |
body {background: #eee;} | |
h1 {text-align: center; font-family: 'Consolas', monospace; font-weight: normal; font-size: 3em;} | |
#calc { | |
width: 250px; | |
padding: 25px; |
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
# Customize BASH PS1 prompt to show current GIT repository and branch. | |
# by Mike Stewart - http://MediaDoneRight.com | |
# SETUP CONSTANTS | |
# Bunch-o-predefined colors. Makes reading code easier than escape sequences. | |
# I don't remember where I found this. o_O | |
# Reset | |
Color_Off="\[\033[0m\]" # Text Reset |
Inspiration: Deis Commit Style Guide
I often quote Deis in sections below.
It makes going back and reading commits easier. It also allows you to spend less time thinking about what your commit message should be.
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
// Implementation in ES6 | |
function pagination(c, m) { | |
var current = c, | |
last = m, | |
delta = 2, | |
left = current - delta, | |
right = current + delta + 1, | |
range = [], | |
rangeWithDots = [], | |
l; |
Inspired by dannyfritz/commit-message-emoji
See also gitmoji.
Commit type | Emoji |
---|---|
Initial commit | 🎉 :tada: |
Version tag | 🔖 :bookmark: |
New feature | ✨ :sparkles: |
Bugfix | 🐛 :bug: |
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
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteBase / | |
RewriteCond %{HTTP_HOST} !^$ | |
RewriteCond %{HTTP_HOST} !^www\. [NC] | |
RewriteCond %{HTTPS}s ^on(s)| | |
RewriteRule ^ http%1://www.%{HTTP_HOST}%{REQUEST_URI} [R=301] | |
RewriteCond %{THE_REQUEST} ^GET\ (.*)\.html\ HTTP |
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
#!/usr/local/bin/zsh | |
DirConf="/usr/local/etc" | |
PIDPATH="/usr/local/var/run" | |
PHPVersion="5.6" | |
MYSQL="/usr/local/bin/mysql.server" | |
NGINX="/usr/local/bin/nginx" | |
PHPFPM="/usr/local/sbin/php-fpm" | |
MEMCACHED="/usr/local/bin/memcached -m 24 -P $PIDPATH/memcached.pid -u root" |
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
/** | |
* Replace 'customer' role (WooCommerce use by default) with your own one. | |
**/ | |
add_filter('woocommerce_new_customer_data', 'wc_assign_custom_role', 10, 1); | |
function wc_assign_custom_role($args) { | |
$args['role'] = 'subscriber'; | |
return $args; | |
} |
OlderNewer