[GRASS-dev] Re: [STATSGRASS] propagating temporary files

On Wed, Jun 07, 2006 at 07:59:29PM +1200, Hamish wrote:

On Wed, Jun 07, 2006 at 03:23:47PM +0800, rsadler@cyllene.uwa.edu.au wrote:

...

> I can disappear these files at run-time, but the strange thing is that
> this didn't appear to be a problem a couple of a weeks ago.

Some months ago we introduced scripts (also commands?) which created
subdirectories within $MAPSET/.tmp/ but the $GISBASE/etc/clean_temp
wasn't yet changed accordingly.

usually $GISBASE/etc/clean_temp is run at GRASS startup and exit to
flush the $MAPSET/.tmp/ dir. At your own risk you can call it within
your GRASS session to clean out the muck.

The current clean_temp program fails to remove subdirectories in
/.tmp/ which are sometimes created.

I have received a new version of clean_temp (written by Roberto Flor)
which needs to be tested:
http://mpa.itc.it/markus/tmp/clean_temp2.c

This new version removes also subdirectories generated in the
$MAPSET/.tmp/ dir.

Markus

Markus wrote:

Some months ago we introduced scripts (also commands?) which created
subdirectories within $MAPSET/.tmp/

I think just some scripts to it "the hard way".

g.tempfile needs a "-d" flag to create a directory and not a file.

see the init.sh script, r.terraflow, for ideas on creating the dir
safely.

Hamish