mirror of
https://github.com/neovim/neovim.git
synced 2025-09-25 20:48:32 +00:00
version: generate "build number" from commit timestamp
- cmake: git_timestamp() returns last commit time formatted as `YYYYMMddHHmm`. - Always include commit hash in :version and --version output. `nvim --version` sample output: NVIM 0.0.0-alpha+201410070245 (compiled Oct 7 2014 05:30:45) Commit: f747b2b1ff7bfe7eb00cc2be82d7af87c98f1111
This commit is contained in:
@@ -18,9 +18,8 @@
|
||||
#include "nvim/version_defs.h"
|
||||
|
||||
char *Version = VIM_VERSION_SHORT;
|
||||
|
||||
char *longVersion = NVIM_VERSION_LONG_DATE __DATE__ " " __TIME__ ")";
|
||||
|
||||
char *longVersion = NVIM_VERSION_LONG " (compiled " __DATE__ " " __TIME__ ")";
|
||||
char *version_commit = "Commit: " NVIM_VERSION_COMMIT;
|
||||
|
||||
#ifdef INCLUDE_GENERATED_DECLARATIONS
|
||||
# include "version.c.generated.h"
|
||||
@@ -747,6 +746,7 @@ void list_version(void)
|
||||
// When adding features here, don't forget to update the list of
|
||||
// internal variables in eval.c!
|
||||
MSG(longVersion);
|
||||
MSG(version_commit);
|
||||
|
||||
// Print the list of extra patch descriptions if there is at least one.
|
||||
char *s = "";
|
||||
|
Reference in New Issue
Block a user