wesnoth_addon_manager: added --version flag
This commit is contained in:
parent
390f21c872
commit
b41bb0249f
2 changed files with 5 additions and 1 deletions
|
@ -19,6 +19,7 @@
|
|||
* wesnoth_addon_manager now supports SSL/TLS connection (using the `--secure` flag)
|
||||
* wesnoth_addon_manager now supports IPv6 connection (using the `--ipv6` flag)
|
||||
* Added new command line flag `--terms` to wesnoth_addon_manager (retrieves and prints the add-ons server upload terms)
|
||||
* wesnoth_addon_manager now supports the `--version` flag (reports the current Wesnoth version)
|
||||
|
||||
## Version 1.17.13
|
||||
### Add-ons client
|
||||
|
|
|
@ -13,6 +13,7 @@ import sys, os.path, re, time, glob, shutil
|
|||
from subprocess import Popen
|
||||
import wesnoth.wmlparser3 as wmlparser
|
||||
from wesnoth.campaignserver_client import CampaignClient
|
||||
from wesnoth import version
|
||||
|
||||
# This is the validation code for the -u arguments. It checks if the input path is valid
|
||||
def valid_file_path(path):
|
||||
|
@ -26,7 +27,9 @@ def valid_file_path(path):
|
|||
if __name__ == "__main__":
|
||||
import argparse
|
||||
|
||||
argumentparser = argparse.ArgumentParser()
|
||||
argumentparser = argparse.ArgumentParser(prog="wesnoth_addon_manager")
|
||||
argumentparser.add_argument("--version", action="version",
|
||||
version="%(prog)s " + version.as_string)
|
||||
argumentparser.add_argument("-a", "--address", help="specify server address",
|
||||
default="add-ons.wesnoth.org")
|
||||
argumentparser.add_argument("--html",
|
||||
|
|
Loading…
Add table
Reference in a new issue