[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
update for rmdir
From: |
Nico Schottelius |
Subject: |
update for rmdir |
Date: |
Thu, 04 Oct 2001 00:37:48 +0200 |
Hello again!
I discussed that some time with Bob Proulx, no I want your opinion about
my thoughts:
Most of the gnu tools like ls, cp, rm, grep, chmod, chown, ... have the
option -r or -R
included. Why not rmdiring recursivly ?
If a directory only includes other directories, we could remove all of
them with
rmdir -r first-directory/
Bob mailed this small shell script to me, that does what I mean:
#!/bin/sh
if [ $# -lt 1 ]; then
echo 'Error: missing arguments' 1>&2
echo 'Usage: rmdirtree file [file ...]' 1>&2
exit 1
fi
find "$@" -depth -type d -print0 | xargs -0 rmdir
But in fact, why should we not integrate it into rmdir ?
All the other tools have -r, this is inconstant.
Regards,
Nico
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- update for rmdir,
Nico Schottelius <=