blob: 3fa4afbd43e634342b6afe8f8446b8cf318a20ff (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
#!/bin/bash
# Script for LP1 labs that are uploaded to Google Drive with binaries and
# that causes problems with Google Drive's automatic virus scan.
# unzip
for f in *.zip; do unzip -q "$f"; done
# delete build/ and dist/ directories (virus detection in Google Drive)
find . -type d -regex '^.*/\(dist\|build\)$' -print0 | xargs -0 rm -r
# zip
rm *.zip # remove old zip files
for d in */; do
dirname="${d%/}"
zip -qr "$dirname.zip" "$d"
done
# dos2unix (for me)
find . -type f -iregex ".*\.\(csv\|cpp\|h\|hpp\)" -print0 | xargs -0 dos2unix
|