bifravst / cat-tracker-fw

Cat Tracker Firmware
https://bifravst.github.io/
3 stars 3 forks source link

Update FW version when building, using to be released version #11

Closed coderbyheart closed 4 years ago

coderbyheart commented 4 years ago

The application firmware version should match the GitHub release:

screenshot-2019-08-19T090904

The version string is set here: https://github.com/bifravst/cat-tracker-fw/blob/e942e99879d3c656c34c3e4599684bdb4194231e/applications/cat_tracker/src/mqtt_codec/mqtt_codec.c#L261-L262

coderbyheart commented 4 years ago

@simensrostad I want that application firmware matches the released version (because what is v0.4.0-690-gcf20e8f17f18, does not seem to relate to any commit in this repo).

So how can the version string be set when the FW is compiled? This should happen ideally through an environment variable which will be used to update a constant in the source code, or I could also (over-)write a version.c file with the version information (where the default version is defined as 0.0.0-development).

simensrostad commented 4 years ago

I added a file named version.h under src/mqtt_codec with a define DEVICE_APP_VERSION that can be written over.

simensrostad commented 4 years ago

If you find it more convenient to have it in src i can relocate it

coderbyheart commented 4 years ago

I mean, the app version is not exclusively related to MQTT codec, so why is it in that folder?

simensrostad commented 4 years ago

Yes, good point. I will move it to src.

github-actions[bot] commented 4 years ago

:tada: This issue has been resolved in version 0.11.3 :tada:

The release is available on GitHub release

Your semantic-release bot :package::rocket: