This file contains hidden or 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
| function lazyMan (name) { | |
| let man = { name }; | |
| let tasks = []; | |
| let excute = () => { | |
| let task = tasks.shift(); | |
| task && task(); | |
| }; | |
| man.talk = () => { | |
| tasks.push(() => { | |
| console.log(`Hi! This is ${name}!`); |
This file contains hidden or 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
| /*! | |
| * dump.js, dump mongodb. | |
| * Copyright(c) 2012 Taobao.com | |
| * Author: busi.hyy <busi.hyy@taobao.com> | |
| * | |
| * 每天凌晨3点从mongo dump一份到指定文件夹,前缀为20121113_ | |
| * 只保留最近七天的dump文件 | |
| * Example: `node dump 127.0.0.1:27071 back database collection1 collection2 ...` | |
| */ |
This file contains hidden or 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
| ## Configure eth0 | |
| # | |
| # vi /etc/sysconfig/network-scripts/ifcfg-eth0 | |
| DEVICE="eth0" | |
| NM_CONTROLLED="yes" | |
| ONBOOT=yes | |
| HWADDR=A4:BA:DB:37:F1:04 | |
| TYPE=Ethernet | |
| BOOTPROTO=static |
This file contains hidden or 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
| <html> | |
| <head> | |
| <title>jsonp test</title> | |
| <script src="http://code.jquery.com/jquery-1.6.2.min.js"></script> | |
| <script type="text/javascript"> | |
| $(function(){ | |
| $('#select_link').click(function(e){ | |
| e.preventDefault(); | |
| console.log('select_link clicked'); | |