Copyright ©

Mongoose OS Forum

ATTENTION! This forum has moved to:

Do not post any new messages.

How to get git tags and commit id into the build id

when building the demo programs, the version numbers come out with the git tag, commit id, whether my local copy is dirty or not, and branch.

Success, built example-neopixel-c/esp32 version 1.0 (20181025-193503/2.6.0-1-g8f147ae-dirty-master).

when building my own programs, they come out as:

Success, built sti-gateway/esp32 version 1.0 (20181030-204153).

what is the magic mojo to get mos build to add the git information to the build id?


  • rojerrojer Dublin, Ireland

    i assume you use remote build. you will need to set up local build for this - install Docker and use mos build --clean
    then, assuming your app is inside a git repo, mos will pick up the status of the repo. it's not possible with remote build because only limited subset of files is being transferred to the server for building, and that does not include git repo stuff.

    Thanked by 1dwegscheid
  • I don't remember if I was using local builds before, but I am now, and am tagging things as I go, so it's working.

    Success, built sti-gateway/esp32 version 1.0 (20181106-180023/1.0.1-master-g28c8ce9ad).
Sign In or Register to comment.