hversion.c 305 B

1234567891011
  1. #include "hversion.h"
  2. #include "htime.h"
  3. const char* get_compile_version() {
  4. static char s_version[64] = {0};
  5. datetime_t dt = get_compile_datetime();
  6. snprintf(s_version, sizeof(s_version), "%d.%02d.%02d.%02d",
  7. H_VERSION_MAJOR, dt.year%100, dt.month, dt.day);
  8. return s_version;
  9. }