https://avatars.githubusercontent.com/u/6058558

程式狂想筆記

php pcntl_fork 多程序小記

之前在 swoole 有簡單紀錄 pcntl_fork
我在寫那篇之前,以為 pcntl_fork 執行子程序大概不會收到執行結果
不過今天仔細看,可以接收到程式執行結果
但還是不能傳接收參數值

Shell 快速統計資料夾下底層檔案數量

1 for i in */ .*/ ; do echo -n $i": " ; (find "$i/" -maxdepth 1 -mindepth 1 -type d | wc -l) ; done mindepth 0 數字是指.本層開始搜尋的(包含.)自己,但通常會用 1(不包含 .) maxdepth 1 數字是使.往後搜尋資料夾 1 for i in */ .*/ ; do echo -n $i": " ; (find "$i" -maxdepth 3 -type f -name "*.docx" | wc -l) ; done Recursively counting files in a Linux directory - Stack Overflow

shell script 布林運算順序

一般寫程式都有 not and or 順序去做運算
但今天我發現 shell script 運算結果跟(別的)程式結果不太一樣
查了一下發現,shell script 是由左往右

Windows 註冊瀏覽器協定方法

最近要使用瀏覽器套件 暴力猴 操作一些程式
一直再想有什麼可以執行 bash 方法
最後有找到一篇 window 註冊協定

Pulse Secure 不能使用,重新安裝方法

最近用 VPN 連到公司網域
但不明原因遠端只要關掉就打不開
只有在重新開機開起 Pulse Secure 可以使用
重開應用程式就不能了
然後過了好幾天,我登入更新完後,就不能用了
移除也移除不了…
網路上看也沒有人解決 orz

只好自己來!!!