Data file access on different path (drive)
Lester Anderson
arctica1963@gmail.com
Mon Nov 23 08:54:00 GMT 2015
Hello,
I am fairly new to using Cygwin, so hope that this query is not too simplistic.
I have a bash script that integrates a lot of GMT commands and also
calls a Fortran program to generate a map output. Now the problem is
how to get the script/Cygwin to access two data files on a different
drive (Q:) to the script location (C:/test).
In addition, it also needs to run a Fortran program, so not sure how that works.
The data read front looks like this (the parts that are problematic):
ruta_elev="Q:/geophys/Potential-field datasets/Topography/topo_17.1.img"
ruta_grav="Q:/geophys/Potential-field datasets/Gravity/grav.img.23.1"
img2grd $ruta_elev -V -T1
-R$lon_e_min/$lon_e_max/$lat_e_min/$lat_e_max -S1 -Gelev.grd -m1
img2grd $ruta_grav -T1 -V
-R$lon_e_min/$lon_e_max/$lat_e_min/$lat_e_max -S0.1 -GFA.grd -m1
.... etc
#Call FA2Boug (Fortran) program to calculate Bouguer anomaly
time ./FA2Boug_final
... etc
I have not so far managed to get the script to access the data files
and thus the rest of the script does not work.
Although one can cd to the location with the " " method (it has a
space in the folder name).
$ cd "Q:/geophys/Potential-field datasets/Topography/"
/cygdrive/q/geophys/Potential-field datasets/Topography
The issue seems to be that $ruta_elev (for example) points to the file
topo_17.1.img but does not seem to assign the name when pointing to a
different drive. I am sure it would work with the files in the same
directory, but these are large!
Any pointers on how this should work would be helpful.
Lester
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
More information about the Cygwin
mailing list