From 5525113d130addf2083a7f1359c04cf7d2d08aa7 Mon Sep 17 00:00:00 2001 From: Cellie Date: Wed, 4 Apr 2018 09:44:34 +0200 Subject: [PATCH] Improved the compile and flash scripts. --- compile.sh | 4 +--- flash.sh | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/compile.sh b/compile.sh index 373786e..11f55ec 100755 --- a/compile.sh +++ b/compile.sh @@ -1,5 +1,3 @@ -echo -n 'const char * sketchVersion = "' > gitTagVersion.h -git --no-pager describe --tags --always --dirty | tr --delete '\n' >>gitTagVersion.h -echo -n '";' >> gitTagVersion.h +echo "const char * sketchVersion = \"$(git describe --tags --always --dirty)\";" > gitTagVersion.h ~/arduino-1.8.5/arduino --verify test.ino rm gitTagVersion.h diff --git a/flash.sh b/flash.sh index 4041286..c385d4d 100755 --- a/flash.sh +++ b/flash.sh @@ -1,5 +1,3 @@ -echo -n 'const char * sketchVersion = "' > gitTagVersion.h -git --no-pager describe --tags --always --dirty | tr --delete '\n' >>gitTagVersion.h -echo -n '";' >> gitTagVersion.h +echo "const char * sketchVersion = \"$(git describe --tags --always --dirty)\";" > gitTagVersion.h ~/arduino-1.8.5/arduino --upload test.ino --pref custom_DebugLevel=esp32_none rm gitTagVersion.h