Loading isis/src/control/apps/cnettable/tsts/append/Makefile +15 −9 Original line number Diff line number Diff line Loading @@ -3,18 +3,24 @@ APPNAME = cnettable include $(ISISROOT)/make/isismake.tsts commands: cp $(INPUT)/appendTo.txt $(OUTPUT); \ # This test is for the append function with data as of 2017-04-21 find $(INPUT)/*.cub > $(OUTPUT)/cubeList.lst; \ $(APPNAME) fromlist=$(OUTPUT)/cubeList.lst \ cnet=$(INPUT)/testNet.net \ flatfile=$(OUTPUT)/appendTo.txt \ append=true > /dev/null; $(APPNAME) FROMLIST=$(OUTPUT)/cubeList.lst \ CNET=$(INPUT)/testNet.net \ FLATFILE=$(OUTPUT)/cnetstats.txt \ > /dev/null; # Run again with append mode = true, using same files as above. This should duplicate the same # data in the output file. $(APPNAME) FROMLIST=$(OUTPUT)/cubeList.lst \ CNET=$(INPUT)/testNet.net \ FLATFILE=$(OUTPUT)/cnetstats.txt APPEND=TRUE \ > /dev/null; rm -f $(OUTPUT)/cubeList.lst > /dev/null; cat $(OUTPUT)/appendTo.txt | sed s/,\[^,]\*\.cub,/,file.cub,/ \ | sed 's/\([0-9][0-9]*\.[0-9]\)\([0-9][0-9]*\)/\1/g' \ | sed s/`date +%Y-%m-%dT`\[0-2\]\[0-9\]:\[0-5\]\[0-9\]:\[0-5\]\[0-9\]/date/ \ cat $(OUTPUT)/cnetstats.txt | $(SED) s/,\[^,]\*\.cub,/,file.cub,/ \ | $(SED) 's/\([0-9][0-9]*\.[0-9]\)\([0-9][0-9]*\)/\1/g' \ | $(SED) s/`date +%Y-%m-%dT`\[0-2\]\[0-9\]:\[0-5\]\[0-9\]:\[0-5\]\[0-9\]/date/ \ > $(OUTPUT)/output.txt rm -f $(OUTPUT)/appendTo.txt rm -f $(OUTPUT)/cnetstats.txt > /dev/null; # To comment what is going on: # The 3 seds do as follows: # 1. remove cube filenames Loading Loading
isis/src/control/apps/cnettable/tsts/append/Makefile +15 −9 Original line number Diff line number Diff line Loading @@ -3,18 +3,24 @@ APPNAME = cnettable include $(ISISROOT)/make/isismake.tsts commands: cp $(INPUT)/appendTo.txt $(OUTPUT); \ # This test is for the append function with data as of 2017-04-21 find $(INPUT)/*.cub > $(OUTPUT)/cubeList.lst; \ $(APPNAME) fromlist=$(OUTPUT)/cubeList.lst \ cnet=$(INPUT)/testNet.net \ flatfile=$(OUTPUT)/appendTo.txt \ append=true > /dev/null; $(APPNAME) FROMLIST=$(OUTPUT)/cubeList.lst \ CNET=$(INPUT)/testNet.net \ FLATFILE=$(OUTPUT)/cnetstats.txt \ > /dev/null; # Run again with append mode = true, using same files as above. This should duplicate the same # data in the output file. $(APPNAME) FROMLIST=$(OUTPUT)/cubeList.lst \ CNET=$(INPUT)/testNet.net \ FLATFILE=$(OUTPUT)/cnetstats.txt APPEND=TRUE \ > /dev/null; rm -f $(OUTPUT)/cubeList.lst > /dev/null; cat $(OUTPUT)/appendTo.txt | sed s/,\[^,]\*\.cub,/,file.cub,/ \ | sed 's/\([0-9][0-9]*\.[0-9]\)\([0-9][0-9]*\)/\1/g' \ | sed s/`date +%Y-%m-%dT`\[0-2\]\[0-9\]:\[0-5\]\[0-9\]:\[0-5\]\[0-9\]/date/ \ cat $(OUTPUT)/cnetstats.txt | $(SED) s/,\[^,]\*\.cub,/,file.cub,/ \ | $(SED) 's/\([0-9][0-9]*\.[0-9]\)\([0-9][0-9]*\)/\1/g' \ | $(SED) s/`date +%Y-%m-%dT`\[0-2\]\[0-9\]:\[0-5\]\[0-9\]:\[0-5\]\[0-9\]/date/ \ > $(OUTPUT)/output.txt rm -f $(OUTPUT)/appendTo.txt rm -f $(OUTPUT)/cnetstats.txt > /dev/null; # To comment what is going on: # The 3 seds do as follows: # 1. remove cube filenames Loading