[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
existing directories
- Subject: existing directories
- From: Martin Schultz <mgs(at)io.harvard.edu>
- Date: Mon, 25 Jan 1999 13:19:03 -0500
- Newsgroups: comp.lang.idl-pvwave
- Organization: Dept. for Engineering&Applied Sciences,Harvard University
- Xref: news.doit.wisc.edu comp.lang.idl-pvwave:13425
Hi,
maybe something is blocking my mind right now, but I just can't think
of a good (platform independent) way to test whether a directory exists
or not. I am trying to write an 'install.pro' routine (not too fancy but
at least with automatic backup of an old version and automatic creation
of the target directory if not there). Actually, since I am spawning
quite a few unix commands anyhow, a good Unix solution would be fine,
too.
BTW: Has anyone written a routine like this before (which is
documented)? What I have in mind (and working in a rudimentary version)
is this:
* create target directory if necessary
or copy all files in target directory into BACKUP<date> directory
* copy all files from a masterdirectory (either by listfile or file
mask) to target directory
or extract them from the RCS system (version control system).
This would be a generic install routine which would come to life by
package specific caller routines (e.g. install_gamap.pro).
Thanks,
Martin.
--
-------------------------------------------------------------------
Dr. Martin Schultz
Department for Engineering&Applied Sciences, Harvard University
109 Pierce Hall, 29 Oxford St., Cambridge, MA-02138, USA
phone: (617)-496-8318
fax : (617)-495-4551
e-mail: mgs@io.harvard.edu
Internet-homepage: http://www-as.harvard.edu/people/staff/mgs/
-------------------------------------------------------------------