最新消息:

linux命令

vi乱码 cat,more正常

vi乱码 cat,more正常

admin 9年前 (2015-05-18) 4444浏览 0评论

今天在做一个东西的时候发现,LANG设置为en_US.UTF-8,putty上的编码设置为Use font encoding, putty上输出汉字正常,重定向到文件后vi乱码,cat,more这个文件汉字显示也正常,查了网上很多东西最后发现按一种说...

Python 实现 linux下more命令

Python 实现 linux下more命令

admin 10年前 (2014-11-13) 4367浏览 0评论

并把上面脚本加到环境变量里   chmod 755 more.py ln -n more.py /usr/bin/more1 调用 more1 即可 cat /var/log/dmesg | more1 截图   #!/usr/bin/en...

sudo: sorry, you must have a tty to run sudo

sudo: sorry, you must have a tty to run sudo

admin 10年前 (2014-11-10) 2868浏览 0评论

使用不同账户,执行执行脚本时候sudo经常会碰到 sudo: sorry, you must have a tty to run sudo这个情况,其实修改一下sudo的配置就好了 vi /etc/sudoers (最好用visudo命令) 注释掉 ...

Timing Details With cURL

Timing Details With cURL

admin 10年前 (2014-10-30) 3627浏览 0评论

Jon’s recent Find the Time to First Byte Using Curl post reminded me about the additional timing details that cURL can provid...