shellscript
(2019/06/29追è¨) å®è·µçãç¶²ç¾ çãã¤ç°¡æ½ã«ã¾ã¨ã¾ã£ãããã¥ã¡ã³ããè¦ã¤ããã®ã§ã¡ã¢ï¼æ¥æ¬èªè¨³ï¼*1ã github.com ãã®tipsã¯ããããLinuxã使ã£ã¦ããå¿ è¦ããã人ãç¹ã«ç«¯æ«æä½ã«è¦æ¦ãã¦ãã人ããããã¯ç«¯æ«æä½ã«å¯¾ãã¦å«æªæããæ±ãã¦ãã人ã«åâ¦
(2019/06/29追è¨) å®è·µçãç¶²ç¾ çãã¤ç°¡æ½ã«ã¾ã¨ã¾ã£ãããã¥ã¡ã³ããè¦ã¤ããã®ã§ã¡ã¢ï¼æ¥æ¬èªè¨³ãããï¼*1ã github.com ãã®tipsã¯ããããLinuxã使ã£ã¦ããå¿ è¦ããã人ãç¹ã«ç«¯æ«æä½ã«è¦æ¦ãã¦ãã人ããããã¯ç«¯æ«æä½ã«å¯¾ãã¦å«æªæããæ±ãã¦ããâ¦
ã·ã§ã«ã¹ã¯ãªãããæ¸ãã¦ãã¦ããµã¨0~1ã®ä¹±æ°ããæ軽ã«çæããããªã£ãã®ã§ãå®é¨çµæãã¡ã¢ï¼ awkã«ã¯çµã¿è¾¼ã¿ã§rand()ã¨ããé¢æ°ãç¨æããã¦ãã¦ãä¾ãã°ä»¥ä¸ã®ãããªå½¢ã§å¼ã³åºããã³ã«0~1ã®ç¯å²ã®ä¹±æ°ãçæãã¦ãããï¼ awk 'BEGIN{ srand('"$RANDOâ¦
çºå£°ç·´ç¿:Intel C/C++ ãç¨ãã Google Testç°å¢ãæºåãããåèã«ãã¦googletestã®ã»ããã¢ãããè¡ãã·ã§ã«ã¹ã¯ãªãããæ¸ããï¼ ãã¼ã ãã£ã¬ã¯ããªã«ã½ã¼ã¹ãè½ã¨ãã¦ãã¦ãã³ã³ãã¤ã«ããå¾ã«/usr/local/ã«å¿ è¦ãªãããã¨ã©ã¤ãã©ãªãcpãã¦ããã ãï¼â¦
äºåäºæ¥åçä¹±4æ¥ç®(ã®å)ã®è¨äº ååå¼ç¨ããkilltreeã¹ã¯ãªããã®ä¸ã«ä»¥ä¸ã®ãããªã³ã¼ãããã£ãï¼ local _sig=${2:-TERM} ãã®${2:-TERM}ã¯ãå¤æ°å±éãããã¿ã¤ãã³ã°ã§ã$2ã«å¤ãè¨å®ããã¦ããªãå ´åã«TERMãåºåããï¼ ããªãã¡ãçµæçã«$2ã空ã â¦
äºåäºæ¥åçä¹±ï¼æ¥ç®ã®è¨äº ãã¯ããAdvent Calendarã§ããªãã§ããªããªã£ã¦ãããã©ããããªæ²ããç¾å®ã¯ãã¦ããã¦ï¼ ååã®è©±ãstackoverflowã§ãã§ã«è°è«ããå°½ãããã¦ãã¦ã解çã®ä¸ã¤ã«èªåã®ã¹ã¯ãªããä¼¼ãæ§é ã®ã·ã§ã«ã¹ã¯ãªããããã£ãï¼ #!/binâ¦
äºåäºæ¥åçä¹±ã2æ¥ç®ã®è¨äºï¼ å®è¡ä¸ã®ããã»ã¹ãkillããããã対象ã®ããã»ã¹ãkillããã¨åããã»ã¹ãã¾ã³ãåãã¡ããããããã»ã¹ããªã¼ã丸ãã¨killããããªã£ãï¼ ã©ãããªãkillã³ãã³ãã£ã½ãããã»ã¹IDã§æå®ãã¦ãæå®ããããã»ã¹ãrootã¨ãã¦â¦
ä¾ãã°ã¤ãã³ãã®å®è¡æéãè¨é²ãããã°ãã¡ã¤ã«ãããåã ã®ã¤ãã³ãã®å¹³åå®è¡æéãç®åºãããã¨ããï¼ ä¾ãã°ä»¥ä¸ã®ãããªawkã使ã£ã¦çµ±è¨ãåããã¨ãã§ããï¼ ãã°ãã¡ã¤ã«ã¯ä»¥ä¸ã®ãããªæãã®ãã®ãæ³å®ï¼ #event exec_time foo 10 hoge 8.431 fugaâ¦