Why do my fw ids always have "-dirty" at the end?

#1

I’ve noticed that my build id shown in mDash always has the label _dirty at the end of it.
I initially assumed it was to do with uncommitted changes, but I’ve made sure it’s my repo is all clean but I still get the same result.

I’ve also tried to delete the build and deps directory and rebuild and flash but no luck.
I see the same result of my firmware built as part of my build pipeline which is definitely a clean build.

Any thoughts?

#2

Think I’ve found my answer: https://git-scm.com/docs/git-describe

#3

For reference: https://github.com/cesanta/mongoose-os/blob/master/tools/mgos_fw_meta.py

The format seems to be:

  1. date
  2. ‘-’
  3. time
  4. ‘/’
  5. git -C repo_path describe --dirty --tags --always (with the dirty saved, but stripped from this string)
  6. ‘-’
  7. git -C repo_path rev-parse --abbrev-ref HEAD
  8. -dirty (if it was set as dirty in step 5)