Display the correct version on generated wiki pages.
This commit is contained in:
@@ -23,14 +23,19 @@ namespace OpenRA.Mods.Common.UtilityCommands
|
||||
return true;
|
||||
}
|
||||
|
||||
[Desc("Generate settings documentation in markdown format.")]
|
||||
[Desc("[VERSION]", "Generate settings documentation in markdown format.")]
|
||||
void IUtilityCommand.Run(Utility utility, string[] args)
|
||||
{
|
||||
Game.ModData = utility.ModData;
|
||||
|
||||
var version = utility.ModData.Manifest.Metadata.Version;
|
||||
if (args.Length > 1)
|
||||
version = args[1];
|
||||
|
||||
Console.WriteLine(
|
||||
"This documentation displays annotated settings with default values and description. " +
|
||||
"Please do not edit it directly, but add new `[Desc(\"String\")]` tags to the source code. This file has been " +
|
||||
"automatically generated for version {0} of OpenRA.", utility.ModData.Manifest.Metadata.Version);
|
||||
"automatically generated for version {0} of OpenRA.", version);
|
||||
Console.WriteLine();
|
||||
Console.WriteLine("All settings can be changed by starting the game via a command-line parameter like `Game.Mod=ra`.");
|
||||
Console.WriteLine();
|
||||
|
||||
Reference in New Issue
Block a user