Skip to content

Instantly share code, notes, and snippets.

@haio
haio / gist:6051720
Created July 22, 2013 06:38
npm instructions
--save => updates dependencies entries in the {{{json}}} file
--force => force fetching remote entries if they exist on disk
--force-latest => force latest version on conflict
--production => do NOT install project devDependencies
--no-color => do not print colors
@haio
haio / gist:6051552
Created July 22, 2013 05:49
node prototype inherits
http://stackoverflow.com/questions/6892428/node-js-best-method-for-emitting-events-from-modules
http://www.aka.org.cn/Docs/hacker-howto_2001.html
http://www.catb.org/~esr/faqs/smart-questions.html
大教堂和市集
@haio
haio / gist:6006940
Created July 16, 2013 08:37
linux timezone
tzselect
ntpdate time.windows.com;/sbin/hwclock -w
[
{"keys":["alt+up"],"command":"swap_line_up"},
{"keys":["alt+down"],"command":"swap_line_down"}
]
@haio
haio / gist:5955103
Created July 9, 2013 06:21
Installing libyaml-devel in Centos
In order to install libyaml-devel in Centos, EPEL repo needs to be added by running the following commands:
wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
sudo rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm
Verify the EPEL repos are installed:
$ ls -1 /etc/yum.repos.d/epel* /etc/yum.repos.d/remi.repo
/etc/yum.repos.d/epel.repo
raspberry-pi 树莓派啊树莓派
@haio
haio / gist:5931189
Created July 5, 2013 01:50
sudo npm/node
whereis npm/node
sudo ln -s /usr/local/bin/node /usr/bin/node
sudo ln -s /usr/local/bin/npm /usr/bin/npm
Waht The Fuck!
纯不是对外界一无所知,相反,是在看过了阴暗与腐败之后依然敢用真心沐浴阳光,简单、纯粹的对待这个世界并坚持下去!