--- a/mkProfile
+++ b/mkProfile
@@ -2,9 +2,9 @@
#======================================================================
# M K P R O F I L E
# doc: Sun Jan 19 18:55:26 2003
-# dlm: Sun Mar 22 10:22:46 2015
+# dlm: Thu Mar 17 07:41:03 2016
# (c) 2003 A.M. Thurnherr
-# uE-Info: 91 63 NIL 0 0 72 10 2 4 NIL ofnI
+# uE-Info: 93 35 NIL 0 0 72 0 2 4 NIL ofnI
#======================================================================
# Make an LADCP Profile by Integrating W (similar to Firing's scan*).
@@ -89,6 +89,8 @@
# May 24, 2014: - finally added (gimbal-)pitch & roll to default output
# - renamed heading to hdg and pitchroll to tilt
# Mar 22, 2015: - made it work for moored time series as well
+# Mar 17, 2015: - adapted to new Getopt library
+# - removed warning
# NOTES:
# - the battery values are based on transmission voltages (different
@@ -108,7 +110,7 @@
require "$1/RDI_BB_Read.pl";
require "$1/RDI_Coords.pl";
require "$1/RDI_Utils.pl";
-require "getopts.pl";
+use Getopt::Std;
$USAGE = "$0 @ARGV";
die("Usage: $0 " .
@@ -120,7 +122,7 @@
"[output -f)ields <field[,...]> " .
"[-M)agnetic <declination>] [profile -B)ottom <depth>] " .
"<RDI file>\n")
- unless (&Getopts("4AB:F:M:Qd:g:r:n:e:c:f:m:p:") && @ARGV == 1);
+ unless (&getopts("4AB:F:M:Qd:g:r:n:e:c:f:m:p:") && @ARGV == 1);
$RDI_Coords::minValidVels = 4 if ($opt_4); # no 3-beam solutions
@@ -813,7 +815,7 @@
p($dta{ENSEMBLE}[$e]->{X}); p($dta{ENSEMBLE}[$e]->{X_ERR});
p($dta{ENSEMBLE}[$e]->{Y}); p($dta{ENSEMBLE}[$e]->{Y_ERR});
}
- if (defined(@f)) {
+ if (@f) {
foreach $f (@f) {
my($fn,$fi) = ($f =~ m{([^[]*)(\[.*)});
$fn = $f unless defined($fn);