Table of Contents
- Leetcode
- wireshark
- gimp
- celery
- RabbitMQ
- monit
- ip location
- regular expression
- comments should be sentence
- Text to ascii art
- Share files
- Linux 使用投影仪
- Mouse
- Ipython + matplotlib
- MC
- Video streaming
- Free ssl certificate(startssl)
- Vim 4913
- Presentation
- 开启 crontab 的日志
- ssh 遇到 permission denied (publickey)
- scp(secure copy)
- Add swap on LinuxMint 16(build YCM need swap)
- Todo
许多待整理凌乱的东西暂时先放这里,等攒攒多了有头绪了再整理归类。
Leetcode
wireshark
$ sudo dpkg-reconfigure wireshark-common 选择 Yes 然后将自己的用户加入 wireshark 组
gimp
- turotials on gimp.org
- GIMP资源汇总 on ubuntu forum
- gimp turotials
- learn-how-use-gimp-like-a-pro-beginner-video-tutorials
- 40 Top GIMP Tutorials to Turn you Into a Professional – Beginner to Advanced
celery
RabbitMQ
- RabbitMQ 使用参考
- RabbitMQ简介
- [[翻译] [RabbitMQ+Python入门经典] 兔子和兔子窝](http://blog.ftofficer.com/2010/03/translation-rabbitmq-python-rabbits-and-warrens/)
- rabbitmq
monit
ip location
regular expression
comments should be sentence
Start with a capital, have a subject and a verb, use a complete sentence, end
with a period.
The reasons:
- Capitals means a start, and a period is a indication of the end.
- Focus on what you are writing. Explaining yourself to others is a good way to
understand what you are doing. - Easier to extend them later. The second sentence could be added more natually,
and he don't have to modify the old sentence. - The breken windows theory. If you take care of small things, other are more
likely to take care of the bigger things.
Text to ascii art
Share files
- Filenergy – A simple file sharing tool written in python using flask
- doora by wong2
- personal-file-sharing-center
- personal-file-sharing-center by blahgeek
- flaskup-A simple Flask application to share files
Linux 使用投影仪
我的使用场景为:Linux Mint 16,Nvidia GTX570m 显卡,已经安装闭源驱动。
- 首先接上投影仪
- nvidia-settting 然后自己点鼠标操作 Xserver Displayer Configuration 操作
- 选择 clone 和相应分辨率 (具体有点忘记,下次看看去)
这样基本就能用了,但是由于我的是 1080P 的屏幕,投影仪的最高分辨率为 1366*768,
所以只能显示自己笔记本屏幕上的一部分,但是勉强能用了 =。=
Mouse
$ xset m 1 5
Ipython + matplotlib
- matplotlib-绘制精美的图表
- Matplotlib Tutorial(译)
- Matplotlib 教程
- matplotlib绘图练习
- 利用Python进行数据分析——绘图和可视化
- nbviewer
MC
- 七种武器之mc
- official site
- Midnight Commander (mc) Guide:
- faq
- mc-tips
- mctutorial
- An Introduction to the Midnight Commander
Video streaming
- served(nodejs)
- Video Streaming with Flask
- Simple stream your media with Flask Python Web framework tutorial!
Free ssl certificate(startssl)
Vim 4913
The reason:
/* * Check if we can create a file and set the owner/group to * the ones from the original file. * First find a file name that doesn't exist yet (use some * arbitrary numbers). */ STRCPY(IObuff, fname); for (i = 4913; ; i += 123) { sprintf((char *)gettail(IObuff), "%d", i); if (mch_lstat((char *)IObuff, &st) < 0) break; }
Reference:
Presentation
开启 crontab 的日志
$ sudo vim /etc/rsyslog.d/50-default.conf
去掉注释符 # (第十行大概)
#cron.* /var/log/cron.log
重启 rsyslog
$ sudo /etc/init.d/rsyslog restart
ssh 遇到 permission denied (publickey)
查看账户 home 目录下的 .ssh 目录的权限 755,所有者和所属组是否是自己。
scp(secure copy)
get file from server:
$ scp -P port root@server_ip:/remote/path/file /local/path/file
get dir from server:
$ scp -P port -r root@server_ip:/remote/dir/ /local/dir/
send file to server:
scp -P port /local/path/file root@server_ip:/remote/path/file
send dir to server:
scp -P port -r /local/dir/ root@server_ip:/remote/dir/
Add swap on LinuxMint 16(build YCM need swap)
crete a 2G(example) file by typing:
$ sudo fallocate -l 2G /swapfile
verify:
$ ls -lh /swapfile -rw-r--r-- 1 root root 2.0G Jul 24 17:19 /swapfile
enabling the swap file
lock down the permissions by typing:
$ sudo chmod 600 /swapfile
set up the swap space:
$ sudo mkswap /swapfile Setting up swapspace version 1, size = xxxxx KiB no label, UUID=xxxxxx
enable it:
$ sudo swapon /swapfile
check:
$ sudo swapon -s Filename Type Size Used Priority /swapfile file xxxxxx 0 -1