From b93077289c88bb09429d59683b27044011d438bc Mon Sep 17 00:00:00 2001 From: Eric Bryant Date: Fri, 21 Sep 2018 03:54:47 -0400 Subject: [PATCH 1/3] Rename nmpfilter.cpp to nmpbyregion.cpp --- nmpfilter/{nmpfilter.cpp => nmpbyregion.cpp} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename nmpfilter/{nmpfilter.cpp => nmpbyregion.cpp} (100%) diff --git a/nmpfilter/nmpfilter.cpp b/nmpfilter/nmpbyregion.cpp similarity index 100% rename from nmpfilter/nmpfilter.cpp rename to nmpfilter/nmpbyregion.cpp From 65158646c713a7f80bf0da25d126288bd4eff30d Mon Sep 17 00:00:00 2001 From: Eric Bryant Date: Fri, 21 Sep 2018 03:55:39 -0400 Subject: [PATCH 2/3] nmpfilter -> nmpbyregion --- nmpfilter/README.md | 4 ++-- nmpfilter/nmpbyregion.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/nmpfilter/README.md b/nmpfilter/README.md index 32e01966..05fd3d99 100644 --- a/nmpfilter/README.md +++ b/nmpfilter/README.md @@ -1,10 +1,10 @@ -# nmpfilter +# nmpbyregion **Purpose:**
Splits *tm-master.nmp* into smaller .nmp files filtered by region. **usage:**
-`nmpfilter HwyDataDir MasterNMP OutputDir`, where +`nmpbyregion HwyDataDir MasterNMP OutputDir`, where * `HwyDataDir` is the path of the *hwy_data* directory in the HighwayData repository, or equivalent * `MasterNMP` is the path of *tm-master.nmp* * `OutputDir` is the directory in which to write the resulting .nmp files. Trailing slash required. diff --git a/nmpfilter/nmpbyregion.cpp b/nmpfilter/nmpbyregion.cpp index 89d26ccc..64481b55 100644 --- a/nmpfilter/nmpbyregion.cpp +++ b/nmpfilter/nmpbyregion.cpp @@ -60,7 +60,7 @@ void filter(vector &RgList, char *MasterNMP, char *OutputDir) int main(int argc, char *argv[]) { if (argc != 4) - { cout << "usage: nmpfilter HwyDataDir MasterNMP OutputDir\n"; + { cout << "usage: nmpbyregion HwyDataDir MasterNMP OutputDir\n"; return 0; } vector RgList; From 4b4da292f1d7a8262d10aa18b0bd9a22900219f4 Mon Sep 17 00:00:00 2001 From: Eric Bryant Date: Fri, 21 Sep 2018 04:01:26 -0400 Subject: [PATCH 3/3] localupdate.sh: nmpfilter -> nmpbyregion --- siteupdate/python-teresco/localupdate.sh | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/siteupdate/python-teresco/localupdate.sh b/siteupdate/python-teresco/localupdate.sh index a0e77ca4..8dcd9c88 100644 --- a/siteupdate/python-teresco/localupdate.sh +++ b/siteupdate/python-teresco/localupdate.sh @@ -47,15 +47,15 @@ echo "$0: launching siteupdate.py" PYTHONIOENCODING='utf-8' ./siteupdate.py -d TravelMapping-$datestr $graphflag -l $datestr/$logdir -c $datestr/$statdir -g $datestr/$graphdir -n $datestr/$nmpmdir | tee $datestr/$logdir/siteupdate.log 2>&1 || exit 1 date -if [ -x ../../nmpfilter/nmpfilter ]; then - echo "$0: running nmpfilter" - ../../nmpfilter/nmpfilter $tmbase/HighwayData/hwy_data $datestr/$logdir/tm-master.nmp $datestr/$logdir/nmpbyregion/ - echo "$0: creating zip archive of all nmp files created by nmpfilter" +if [ -x ../../nmpfilter/nmpbyregion ]; then + echo "$0: running nmpbyregion" + ../../nmpfilter/nmpbyregion $tmbase/HighwayData/hwy_data $datestr/$logdir/tm-master.nmp $datestr/$logdir/nmpbyregion/ + echo "$0: creating zip archive of all nmp files created by nmpbyregion" cd $datestr/$logdir/nmpbyregion zip -q nmpbyregion.zip *.nmp cd - else - echo "$0: SKIPPING nmpfilter (../../nmpfilter/nmpfilter not executable)" + echo "$0: SKIPPING nmpbyregion (../../nmpfilter/nmpbyregion not executable)" fi if [ "$install" == "0" ]; then