blynkkk / blynk-library

Blynk library for IoT boards. Works with Arduino, ESP32, ESP8266, Raspberry Pi, Particle, ARM Mbed, etc.
https://blynk.io
MIT License
3.81k stars 1.38k forks source link

Added BLYNK_FIRMWARE_VERSION_CMDLINE defining firmware version with -D cmdline param #560

Closed Bascy closed 2 years ago

Bascy commented 2 years ago

Description

This addition allows specifying the BLYNK_FIRMWARE_VERSION from the command line or platformio.ini with a -DBLYN K_FIRMWARE_VERSION_CMDLINE="1.2.3"

This makes it easier to i.e. determine the firmware version automatically from the latest git tag

vshymanskyy commented 2 years ago

It should probably be handled by your sketch. I.e:


#ifdef BLYNK_FIRMWARE_VERSION_CMDLINE
#define BLYNK_FIRMWARE_VERSION  BLYNK_TOSTRING(BLYNK_FIRMWARE_VERSION_CMDLINE)
#endif