From fe21c890a42a01ddd8b07b343ae9130dd81c4642 Mon Sep 17 00:00:00 2001 From: parker-research <166864283+parker-research@users.noreply.github.com> Date: Mon, 4 May 2026 23:30:06 -0600 Subject: [PATCH] Add --version lowercase flag to comply with convention --- README.md | 5 ++++- src/main.cpp | 5 +++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index cc2d2c6..7e48627 100644 --- a/README.md +++ b/README.md @@ -119,6 +119,8 @@ openFPGALoader -- a program to flash FPGA -v, --verbose Produce verbose output --verbose-level arg verbose level -1: quiet, 0: normal, 1:verbose, 2:debug + --force-terminal-mode force progress bar output as if connected to + a terminal -h, --help Give this help list --verify Verify write operation (SPI Flash only) --xvc Xilinx Virtual Cable Functions @@ -130,7 +132,8 @@ openFPGALoader -- a program to flash FPGA -X, --read-xadc Read XADC (Xilinx FPGA only) --read-register arg Read Status Register(Xilinx FPGA only) --user-flash arg User flash file (Gowin LittleBee FPGA only) - -V, --Version Print program version + -V, --version Print program version + --Version Print program version (Deprecated) Mandatory or optional arguments to long options are also mandatory or optional for any corresponding short options. diff --git a/src/main.cpp b/src/main.cpp index f6bdcb7..9ca2940 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -1027,7 +1027,8 @@ int parse_opt(int argc, char **argv, struct arguments *args, cxxopts::value(args->read_register)) ("user-flash", "User flash file (Gowin LittleBee FPGA only)", cxxopts::value(args->user_flash)) - ("V,Version", "Print program version"); + ("V,version", "Print program version") + ("Version", "Print program version (Deprecated)"); options.parse_positional({"bitstream"}); auto result = options.parse(argc, argv); @@ -1055,7 +1056,7 @@ int parse_opt(int argc, char **argv, struct arguments *args, args->verbose = verbose_level; } - if (result.count("Version")) { + if (result.count("Version") || result.count("version")) { std::cout << "openFPGALoader " << VERSION << std::endl; return 1; }