[^first]R is functional language, which means that your code often contains a lot of ( parentheses).
And complex code often means nesting those parentheses together, which make code hard to read and understand.
傳統寫法
watch_file=`stat -c %Y owen_watch_file.sh`; | |
now_=`date +%s`; | |
if [ $[ $now_-$watch_file ] -gt 1 ];then | |
echo 'Owen Good Job!'; | |
else | |
echo 'This file Not be changed!'; | |
fi |
watch_file=`stat -c %Y owen_watch_file.sh`; | |
now_=`date +%s`; | |
if [ $[ $now_-$watch_file ] -gt 1 ];then | |
echo 'Owen Good Job!'; | |
else | |
echo 'This file Not be changed!'; | |
fi |
# linux 新增硬碟空間作法 | |
```shell= | |
# 卸載先前 pure Storage | |
umount /data1 | |
# 無法卸載,仍有user再上面使用,列出user 並將user執行程序殺除 <數字>c 表示正在執行 | |
fuser -m /data1 |
class(x) #AsIs
usrAgent="Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.71 Safari/537.36" | |
getOption("HTTPUserAgent") | |
options(HTTPUserAgent=usrAgent) | |
url.regular <- "https://www.sportslottery.com.tw/web/services/rs/betting/tournamentGames/15102/0/t-4102.json?groups=278&groups=283&groups=289&groups=293&groups=683&locale=tw&brandId=defaultBrand&channelId=1" | |
httr_options("useragent") | |
curl_docs("useragent") | |
httr::set_config( config( ssl_verifypeer = 0L ) ) | |
res = GET(url = url.regular,user_agent(usrAgent)) |