Project

General

Profile

1 4597 aaronmk
#!/bin/sh
2
# Removes a file if it's empty
3
# Usage: self file
4
5 4643 aaronmk
if test -f "$1" -a ! -s "$1"; then # regular file and not non-empty
6 4647 aaronmk
    svn rm --force "$1" 2>/dev/null || rm "$1" # try svn first
7 4643 aaronmk
fi