diff options
author | Joseph Hunkeler <jhunkeler@gmail.com> | 2018-12-20 22:01:26 -0500 |
---|---|---|
committer | Joseph Hunkeler <jhunkeler@gmail.com> | 2018-12-20 22:01:26 -0500 |
commit | f4d07b5a2550c7fa6db68a389dbff48dec9d3535 (patch) | |
tree | 341a491a89f6c0842f9cb10ffcc87dbf8ed6d39d /mktestenv.sh | |
parent | 5e8f64e443cb7b6cf27c3ab52cb5e659c79ec121 (diff) | |
download | delivery_control-generalization.tar.gz |
Try to avoid random "ls" deathgeneralization
* Use "find" to populate dev_specs
Diffstat (limited to 'mktestenv.sh')
-rwxr-xr-x | mktestenv.sh | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/mktestenv.sh b/mktestenv.sh index c60893d..5b1ac3b 100755 --- a/mktestenv.sh +++ b/mktestenv.sh @@ -132,12 +132,10 @@ fi # If a release dir already exists, calculate the iteration value from its contents. if [[ $calculate_iter == true ]]; then - find ${deliverable_dir} -type d -name ${name}/dev - if [[ ${?} -eq 0 ]]; then - dev_specs=$(ls -1 ${deliverable_dir}/${name}/dev/${deliverable}*${os}*${pyver_S}*.txt) - fi - latest_iter=-1 + dev_specs=$(find ${deliverable_dir} -type f -wholename \ + *${name}/dev/${deliverable}*${os}*${pyver_S}*.txt) + # Determine the highest iteration found for the release name for dev_spec in ${dev_specs}; do #echo $dev_spec |