From 81a34c33742d9fcc8c33e2a8d206addaa1cc5ac1 Mon Sep 17 00:00:00 2001 From: Scoopta Date: Thu, 20 Feb 2020 23:51:54 -0800 Subject: [PATCH] Wofi can now be named wofi-askpass. This is for easy use as a sudo askpass program --- src/main.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/main.c b/src/main.c index 5afb687..4701b14 100644 --- a/src/main.c +++ b/src/main.c @@ -608,6 +608,11 @@ int main(int argc, char** argv) { if(strcmp(get_exec_name(argv[0]), "dmenu") == 0) { map_put(config, "mode", "dmenu"); cache_file = "/dev/null"; + } else if(strcmp(get_exec_name(argv[0]), "wofi-askpass") == 0) { + map_put(config, "mode", "dmenu"); + cache_file = "/dev/null"; + password_char = "*"; + prompt = "Password"; } else if(mode != NULL) { map_put(config, "mode", mode); } else if(map_get(config, "mode") == NULL) {