Add console command to get version information

See: #652
This commit is contained in:
Jonathan G Rennison
2024-02-15 18:43:27 +00:00
parent 53f86b3aab
commit 58f8971f17
7 changed files with 23 additions and 21 deletions

View File

@@ -899,7 +899,9 @@ int openttd_main(int argc, char *argv[])
case 'x': scanner->save_config = false; break;
case 'J': _quit_after_days = Clamp(atoi(mgo.opt), 0, INT_MAX); break;
case 'Z': {
CrashLog::VersionInfoLog();
char buffer[65536];
CrashLog::VersionInfoLog(buffer, lastof(buffer));
fputs(buffer, stdout);
return ret;
}
case 'X': only_local_path = true; break;