[GRASSLIST:2521] Re:directory cleaning help

Erin ODoherty/RMRS/USDAFS eodoherty at fs.fed.us
Fri Sep 28 12:09:17 EDT 2001


Kevin,
Use g.remove rast=[filename]
it'll get rid off all the  files related to that raster (under cell,
cellhd, cats, hist, colr).

Alternatively, if you want to get rid of everything in a whole directory
and
all it's subdirectories with that name (and I mean everything, so be
careful) then use the Unix command
find [directory path] -name [filename] -exec rm -r {} \;

to be safe you can run this first
find [directory path] -name [filename] -print
and if everything listed is slated for destruction then run the previous
command.
Cheers,
Erin

Erin O'Doherty
Research Ecologist, USDA Forest Service
Rocky Mountain Research Station
e-mail: eodoherty at fs.fed.us




                                                                                             
                    Kevin Slover                                                             
                    <kjslover at nhc.no        To:     GRASS List <grasslist at baylor.edu>        
                    aa.gov>                 cc:                                              
                    Sent by:                Subject:     [GRASSLIST:2517] directory cleaning 
                    owner-GRASSLIST@        help                                             
                    baylor.edu                                                               
                                                                                             
                                                                                             
                    09/28/01 08:38                                                           
                    AM                                                                       
                                                                                             
                                                                                             




just a quick question, this might be more related to Linux question...but
is there a way to clean raster files without going to each individual
directory (ie cell, fcell, etc...)??  It is a pain to have to go to each
directory and rm the files...
--
        LTJG Kevin Slover,NOAA   GIS Specialist/Meteorologist/Oceanographer

              Tropical Prediction Center/National Hurricane Center
                    11691 SW 17th Street Miami FL 33165
                 Work: (305) 229-4456 Fax : (305) 553-1264





More information about the grass-user mailing list