- linux 下修改 Inotify Watches Limit 值,参见:官方说明, 但是针对 ubuntu 需要执行“sudo sysctl fs.inotify.max_user_watches=xxxxx”
使用dnsmasq将任意域名的本地DNS域名解析到localhost
dnsmasq是一款简单轻便的DNS服务器,可以用作本地域名解析服务器,公网DNS记录缓存,在本地机器上搭建基于域名的测试环境等用途;
如将local.host
这个自定义域名解析到127.0.0.1
;进而实现使用任意子域名*.local.host
访问nginx或apache对应的的虚拟主机。
以ubuntu14.04上为例:
安装
sudo apt-get install dnsmasq
配置
新建并自定义配置文件,如localnet
;然后重启服务即可生效
$ sudo emacs /etc/dnsmasq.d/localnet
- append line: "address=/dev/127.0.0.1"
$ sudo service dnsmasq restart
其他配置选项可参见配置文件模板/etc/dnsmasq.conf
have fun.
花魂
有感于青芽吐素、玉兰卸羽,故有此作。
斜阳抚,玉兰卸羽,皎玉化绯迷蝶醉;
三月里,柳絮纷飞,青芽吐素送花魁;
碧空静,巧燕不语,鸿鹄标榜奋疾追;
青苔上,再醉一回,幻识盘古是魂归。
公元2011,辛卯年二月廿八夜
于安科
雪夜调
雪又飘,阴风梅雨似冰刀;放眼眺,不见洁霜尽炭烧。
夜无聊,所期所愿不知遥;展眉笑,淡然寡意甚逍遥。
思不扰,命数几何可知道;挥袖道,佳材精琢定可造。
乡愁恼,忆得老友昔玩闹;忘忧飚,苦酒凛冽入肠道。
——二零零九年十二月十二日午夜
应用Gradle构建系统协助Android开发
working with Gradle for Android Development
This is a summary version of the official User Guide
分享一个非常好的国内安卓资源站,FUCKin gfw
play with Emacs
Tips
- 请注意 C-f 、C-b 和 M-f 、M-b 两对之间的类比关系。通常的惯例是:META 系列组合键用来操作“由语言定义的单位(比如词、句子、段落)”,而 CONTROL系列组合键用来操作“与语言无关的基本单位(比如字符、行等等)”。
Working with Android Studio (Intellij IDEA)
Tips
- Navigate menu
- In case you’re not familiar with an API class, file or symbol, the Navigate menu lets you jump directly to the class of a method or field name without having to search through individual classes.
- Inspection scopes
- Scopes set the color of code segments for easy code identification and location. For example, you can set a scope to identify all code related to a specific action bar.
The Hot-Keys mapping of Xcode for iOS develop
Xcode
Action | Hot-Key |
---|---|
Create new file | Command-N |
Build | Command-B |
Run | Command-R |
Access documentation | Control-Clicking on a UI element |
Doc viewer & API Reference | Shift-Command-0 |
Quick Help | Option-click a symbol in Source editor |
Open in assistant editor | Option-Double-click |
Open in another window | Option-Shift |
Show where the file should open | Option-Shift-click |
Open quickly | Shift-Command-O |
Jump to Definition command from Navigate | Shift-Command-J |
Del from insertion to end of line | Command-K |
Display definition in assistant editor | Option-Command-click |
Uninstall constraint or view | Command-Delete |
TO BE CONTINUED …