]> git.sur5r.net Git - i3/i3/blobdiff - i3-dmenu-desktop
i3-dmenu-desktop: run commands when they don’t match a .desktop file
[i3/i3] / i3-dmenu-desktop
index 65e99ec09b13c663df6820dbcbf293c588bb463d..cf5b41e0f8f97d943aebc44e3ec6824d6d49de47 100755 (executable)
@@ -346,7 +346,13 @@ if (exists($choices{$choice})) {
         last;
     }
     if (!defined($app)) {
-        die "Invalid input: “$choice” does not match any application.";
+        warn "Invalid input: “$choice” does not match any application. Trying to execute nevertheless.";
+        $app->{Name} = '';
+        $app->{Exec} = $choice;
+        # We assume that the app is old and does not support startup
+        # notifications because it doesn’t ship a desktop file.
+        $app->{StartupNotify} = 0;
+        $app->{_Location} = '';
     }
 }