]> git.pld-linux.org Git - packages/rpm-build-tools.git/blame_incremental - clean-distfiles.sh
merged rest of the files from CVS packages/ dir
[packages/rpm-build-tools.git] / clean-distfiles.sh
... / ...
CommitLineData
1#!/bin/sh
2# cleanup distfiles like files, i.e archives that can be likely be
3# re-downloaded.
4
5# be sure we are in right dir
6dir=$(dirname "$0")
7cd "$dir"
8
9ext=bz2,gz,rar,tgz,tbz2,zip,jar,Z,tar,png,ico,xpm,gif,rpm,bin,run,exe,iso,xpi,ZIP,dll,pdf
10ls -ldrSh */*.{$ext}
11echo */*.{$ext} | xargs stat -c %s | awk '{s+=$1} END {printf("Total: %d MiB\n", s/1014/1024)}'
12
13echo remove? ctrl+c to abort
14read a
15
16rm -vf */*.{$ext}
This page took 0.061497 seconds and 4 git commands to generate.