- copy the file
commit-msg
to.git/hooks/commit-msg
- make sure your delete the sample file
.git/hooks/commit-msg.sample
- Make commit msg executable.
chmod +x .git/hooks/commit-msg
- Edit
commit-msg
to better fit your development branch, commit regex and error message - Profit $$
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
[user] | |
name = Pavan Kumar Sunkara | |
email = [email protected] | |
username = pksunkara | |
[core] | |
editor = vim | |
whitespace = fix,-indent-with-non-tab,trailing-space,cr-at-eol | |
excludesfile = ~/.gitignore | |
[sendemail] | |
smtpencryption = tls |
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
sudo launchctl unload /System/Library/LaunchDaemons/com.apple.racoon.plist | |
sudo launchctl load /System/Library/LaunchDaemons/com.apple.racoon.plist |
- Add VPN Configuration
- IPSEC
- Server: your-ip
- Account: shell user
- Password: shell password
- Use certificate: Off
- Group name: Blank
- Secret: your-strong-secret
Here are a list of headless browsers that I know about:
- [HtmlUnit][1] - Java. Custom browser engine. JavaScript support/DOM emulated. Open source.
- [Ghost][2] - Python only. WebKit-based. Full JavaScript support. Open source.
- [Twill][3] - Python/command line. Custom browser engine. No JavaScript. Open source.
- [PhantomJS][4] - Command line/all platforms. WebKit-based. Full JavaScript support. Open source.
- [Awesomium][5] - C++/.Net/all platforms. Chromium-based. Full JavaScript support. Commercial/free.
- [SimpleBrowser][6] - .Net 4/C#. Custom browser engine. No JavaScript support. Open source.
- [ZombieJS][7] - Node.js. Custom browser engine. JavaScript support/emulated DOM. Open source.
- [EnvJS][8] - JavaScript via Java/Rhino. Custom browser engine. JavaScript support/emulated DOM. Open source.
- What do Etcd, Consul, and Zookeeper do?
- Service Registration:
- Host, port number, and sometimes authentication credentials, protocols, versions numbers, and/or environment details.
- Service Discovery:
- Ability for client application to query the central registry to learn of service location.
- Consistent and durable general-purpose K/V store across distributed system.
- Some solutions support this better than others.
- Based on Paxos or some derivative (i.e. Raft) algorithm to quickly converge to a consistent state.
- Service Registration:
- Centralized locking can be based on this K/V store.
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 | |
# Functions ============================================== | |
# return 1 if global command line program installed, else 0 | |
# example | |
# echo "node: $(program_is_installed node)" | |
function program_is_installed { | |
# set to 1 initially | |
local return_=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
static function OnBeforeRequest(oSession: Session) { | |
if (oSession.RequestMethod == 'GET' && oSession.PathAndQuery.IndexOf('part_of_your_url') > 0) { | |
oSession.utilCreateResponseAndBypassServer(); | |
oSession.oResponse.headers.HTTPResponseCode = 401; | |
oSession.oResponse.headers.HTTPResponseStatus = '401 Not Authorized'; | |
oSession.oResponse.headers['Access-Control-Allow-Origin'] = '*'; | |
oSession.utilSetResponseBody('response_body'); | |
} | |
} |
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 express= require('express'); | |
var http = require('http'); | |
var fs = require('fs'); | |
var path = require('path'); | |
var app = express(); | |
server = http.createServer(app); | |
app.set('view engine', 'jade'); |
NewerOlder