1. 程式人生 > >Linux運維之批量下載指定網站的100個圖片檔案,並找出大於200KB的檔案

Linux運維之批量下載指定網站的100個圖片檔案,並找出大於200KB的檔案

題目為:

 有一百個圖片檔案,它們的地址都是
http://down.fengge.com/img/1.png
http://down.fengge.com/img/2.png

一直到 http://down.fengge.com/img/100.png
批量下載這100個圖片檔案,並找出其中大於200KB的檔案。 

 

這個使用shell指令碼實現

#!/bin/bash
for i in {1..100}
do
    wget http://down.fengge.com/img/$i.png
done
find ./ -name "*.png" -size +200K