aboutsummaryrefslogtreecommitdiffstats
path: root/src/main.cpp
diff options
context:
space:
mode:
authorsaturneric <[email protected]>2024-11-22 22:06:30 +0000
committersaturneric <[email protected]>2024-11-22 22:06:30 +0000
commite16e15db09d89a997db73e313b966f95e6c59f56 (patch)
tree4f6be7375b983eda33b5faa37b9c7a3af0a57ed6 /src/main.cpp
parentfix: correct the path to the executable of app image mode (diff)
downloadGpgFrontend-e16e15db09d89a997db73e313b966f95e6c59f56.tar.gz
GpgFrontend-e16e15db09d89a997db73e313b966f95e6c59f56.zip
feat: rewrite core init processes and add env option
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 9c1234e2..fbd53649 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -80,6 +80,7 @@ auto main(int argc, char* argv[]) -> int {
parser.addOptions({
{{"v", "version"}, "show version information"},
{{"t", "test"}, "run all unit test cases"},
+ {{"e", "environment"}, "show environment information"},
{{"l", "log-level"},
"set log level (trace, debug, info, warn, error)",
"debug"},
@@ -95,6 +96,10 @@ auto main(int argc, char* argv[]) -> int {
GpgFrontend::ParseLogLevel(parser.value("l"));
}
+ if (parser.isSet("e")) {
+ return GpgFrontend::PrintEnvInfo();
+ }
+
if (parser.isSet("t")) {
ctx->gather_external_gnupg_info = false;
ctx->load_default_gpg_context = false;