File: dh_rmemptydirs

package info (click to toggle)
gcc-4.8 4.8.4-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 587,180 kB
  • ctags: 425
  • sloc: makefile: 65,711; sh: 1,248; perl: 165; awk: 23; cpp: 14
file content (10 lines) | stat: -rwxr-xr-x 251 bytes parent folder | download | duplicates (71)
1
2
3
4
5
6
7
8
9
10
#! /bin/sh -e

pkg=`echo $1 | sed 's/^-p//'`

: # remove empty directories, when all components are in place
for d in `find debian/$pkg -depth -type d -empty 2> /dev/null`; do \
    while rmdir $d 2> /dev/null; do d=`dirname $d`; done; \
done

exit 0