Skip to content

Instantly share code, notes, and snippets.

View zjhiphop's full-sized avatar
🎯
Focusing

newboy zjhiphop

🎯
Focusing
  • cloud-tea
  • USA
View GitHub Profile

Installing SSHPASS

SSHPass is a tiny utility, which allows you to provide the ssh password without using the prompt. This will very helpful for scripting. SSHPass is not good to use in multi-user environment. If you use SSHPass on your development machine, it don't do anything evil.

Installing on Ubuntu

apt-get install sshpass

Installing on OS X

@zjhiphop
zjhiphop / introrx.md
Last active August 29, 2015 14:23 — forked from staltz/introrx.md

The introduction to Reactive Programming you've been missing

(by @andrestaltz)

So you're curious in learning this new thing called Reactive Programming, particularly its variant comprising of Rx, Bacon.js, RAC, and others.

Learning it is hard, even harder by the lack of good material. When I started, I tried looking for tutorials. I found only a handful of practical guides, but they just scratched the surface and never tackled the challenge of building the whole architecture around it. Library documentations often don't help when you're trying to understand some function. I mean, honestly, look at this:

Rx.Observable.prototype.flatMapLatest(selector, [thisArg])

Projects each element of an observable sequence into a new sequence of observable sequences by incorporating the element's index and then transforms an observable sequence of observable sequences into an observable sequence producing values only from the most recent observable sequence.

@zjhiphop
zjhiphop / introrx.md
Last active August 29, 2015 14:23 — forked from staltz/introrx.md

The introduction to Reactive Programming you've been missing

(by @andrestaltz)

So you're curious in learning this new thing called Reactive Programming, particularly its variant comprising of Rx, Bacon.js, RAC, and others.

Learning it is hard, even harder by the lack of good material. When I started, I tried looking for tutorials. I found only a handful of practical guides, but they just scratched the surface and never tackled the challenge of building the whole architecture around it. Library documentations often don't help when you're trying to understand some function. I mean, honestly, look at this:

Rx.Observable.prototype.flatMapLatest(selector, [thisArg])

Projects each element of an observable sequence into a new sequence of observable sequences by incorporating the element's index and then transforms an observable sequence of observable sequences into an observable sequence producing values only from the most recent observable sequence.

Tabs and Windows

Function Shortcut
Previous Tab + Left Arrow
Next Tab + Right Arrow
Go to Tab + Number
Go to Window + Option + Number
Go to Split Pane by Direction + Option + Arrow
Go to Split Pane by Order of Use + ] , + [
[program:mongodb]
command=/opt/mongodb/bin/mongod --dbpath /storage/mongodb_data --rest
directory=/opt/mongodb
user=root
autostart=false
@zjhiphop
zjhiphop / app.js
Last active August 29, 2015 14:25 — forked from fidelisrafael/app.js
Easy way to export data to XLS format using Node.js
// clone this gist to a empty folder, the run:
// npm init (and follow steps)
// npm install express --save
// npm install swig --save
// node app.js and open http://localhost:3000
function App() {
var express = require('express');
@zjhiphop
zjhiphop / gslint.conf
Last active August 29, 2015 14:26 — forked from niksumeiko/gslint.conf
Sample Closure Linter configuration file used within WebStorm IDE
--strict
--jsdoc
--summary
--beep
--check_html
--nomultiprocess
--debug_indentation
--time
@zjhiphop
zjhiphop / results.txt
Created October 30, 2011 03:17 — forked from JacksonTian/results.txt
各种移动设备的viewport取值
Devices landscape(w/h) portrait(w/h)
HTC g10 533/260 320/473
ipad1 1024/690 768/946
ipad2 1024/690 768/946
Samsung9100 533/237 320/450
Samsung9000 533/239 320/452
LePhone 533/250 320/463
ipod(4.2.1) 480/208 320/356
//以下数据来自支付宝 颂赞
MOROTOLA ME722 320/488 569/239
@zjhiphop
zjhiphop / LICENSE.txt
Created December 4, 2011 07:09 — forked from 140bytes/LICENSE.txt
140byt.es -- Click ↑↑ fork ↑↑ to play!
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2011 YOUR_NAME_HERE <YOUR_URL_HERE>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
@zjhiphop
zjhiphop / git_test
Created February 13, 2012 09:09
git_test
var initialize= function () {
this.register();
}