Archive for 二月, 2016


tim cook & FBI

http://www.apple.com/customer-letter/

 

老美的科技公司和FBI差不多是一个量级的?

FBI居然会提出这么不合理的要求? 它是打算给apple经费嘛?做一个全新的OS,那不是小事,那是需要人和银子的。

估计与人银子无关,苹果不差这些。一定是别的什么原因。保护用户隐私,应该不是主要原因。

科技公司(APPLE)和美国政府(FBI)完全不是一个圈子的,说不到一起。

这是美式民主的一个体现?美国从来就不是政府说了算的世界。

 

Advertisements

trap of bash

trap is a command which is rarely used for most linux shell developers. But sometimes it is very useful, especially when u have some background jobs running and would like to cleanup such jobs if the scripts exits abnormally.

http://mywiki.wooledge.org/SignalTrap

This page has an excellent explanation for trap command.

Besides it gives the difference between what “kill –SIGINT pid” does and CTRL+C, it is

  • the first applys to a process pid
  • the second applys to the forground job, all processes which belong to that job will receive SIGINT

Another tip is of using “& wait” make bash script asynchrous, so that  trap Command List can be executed immediately instead of only being run after the script’s  foreground process is complete.

 

ref