The UNIX and Linux Forums
>
Top Forums
>
Shell Programming and Scripting
shell script to delete directories...
User Name
Remember Me?
Password
Google UNIX.COM
Forums
Portal
Register
Rules & FAQ
Contribute
Members List
Arcade
Search
Today's Posts
Mark Forums Read
Thread
:
shell script to delete directories...
View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
#
8
(
permalink
)
05-16-2008
era
Herder of Useless Cats
Join Date: Mar 2008
Location: /there/is/only/bin/sh
Posts: 3,092
The double awks are wasteful, though.
Code:
find . -type d | awk -F "/" '!/\.\/200/ { print $2 }'
Note also that 200* in a regular expression means 20 or 200 or 2000 or 20000 or ...
era
View Public Profile
Visit era's homepage!
Find all posts by era