⌘T | go to file |
⌘⌃P | go to project |
⌘R | go to methods |
⌃G | go to line |
⌘KB | toggle side bar |
⌘⇧P | command prompt |
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
# If you don't have Homebrew installed, you should. Do this. | |
/usr/bin/ruby -e "$(/usr/bin/curl -fksSL https://raw.github.com/mxcl/homebrew/master/Library/Contributions/install_homebrew.rb)" | |
# Install DNSMasq from Homebrew | |
brew install dnsmasq | |
# Create a directory for virtual hosts files | |
mkdir -p /usr/local/etc/dnsmasq.d | |
# Create a config for DNSMasq |
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
server.modules = ( | |
"mod_access", | |
"mod_alias", | |
"mod_accesslog", | |
"mod_extforward", | |
"mod_rewrite", | |
#"mod_fastcgi", | |
"mod_proxy", | |
"mod_redirect" ) |
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
try: | |
from recaptcha.client import captcha | |
from pylons import request, config | |
class RecaptchaValidator(Schema): | |
''' | |
Validates ReCAPTCHA against their web service | |
''' |
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 | |
### BEGIN INIT INFO | |
# Provides: manage process gunicorn_paster | |
# Required-Start: $local_fs $remote_fs $network | |
# Required-Stop: $local_fs $remote_fs $network | |
# Should-Start: $gunicorn_paster | |
# Should-Stop: $gunicorn_paster | |
# Default-Start: 2 3 4 5 | |
# Default-Stop: 0 1 6 | |
# Short-Description: Start gunicorn_paster. |
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
/** | |
* The first commented line is your dabblet’s title | |
*/ | |
background: #f06; | |
background: linear-gradient(45deg, #f06, yellow); | |
min-height: 100%; |
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
/** | |
* The first commented line is your dabblet’s title | |
*/ | |
background: #f06; | |
background: linear-gradient(45deg, #f06, yellow); | |
min-height: 100%; |
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 | |
### BEGIN INIT INFO | |
#启动 停止 webapp author wangkai hqman@gmail.com | |
# Short-Description: Start gunicorn_paster. | |
# Description: Start gunicorn_paster. | |
### END INIT INFO | |
PIDFILE=WEBAPP.PID | |
ENVINI=development.ini |
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 | |
sudo find '/Applications/Google Chrome.app' \ | |
\( -name inspector.css -or -name devTools.css \) \ | |
-exec sh -c 'cat >> $1 <<WAT | |
/* Added on `date` */ | |
#drawer .monospace, | |
#drawer .source-code { | |
font-size: 18px !important; |
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> | |
<head> | |
<title>Stay Standalone</title> | |
<meta name="apple-mobile-web-app-capable" content="yes"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no"> | |
<script src="stay_standalone.js" type="text/javascript"></script> | |
</head> | |
<body> | |
<ul> | |
<li><a href="http://google.com/">Remote Link (Google)</a></li> |
OlderNewer