]> Sergey Matveev's repositories - btrtrc.git/blob - fs/test.sh
test.sh: Unmount and wait for torrentfs to return after completion
[btrtrc.git] / fs / test.sh
1 mkdir mnt torrents
2 umount mnt
3 set -e
4 GOPPROF=http godo github.com/anacrolix/torrent/cmd/torrentfs -mountDir=mnt -metainfoDir=torrents &
5 cd torrents
6 wget -c https://cdimage.debian.org/debian-cd/current/amd64/bt-cd/debian-9.1.0-amd64-netinst.iso.torrent
7 echo 'magnet:?xt=urn:btih:6a9759bffd5c0af65319979fb7832189f4f3c35d&dn=sintel.mp4' > sintel.magnet
8 cd ..
9 file=debian-9.1.0-amd64-netinst.iso
10 # file=sintel.mp4
11 while [ ! -e "mnt/$file" ]; do sleep 1; done
12 pv "mnt/$file" | md5sum
13 umount mnt
14 wait