[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [STUMP] Exec and dialog UI

From: Mehul Sanghvi
Subject: Re: [STUMP] Exec and dialog UI
Date: Sat, 29 Oct 2011 09:52:10 -0400

On Sat, Oct 29, 2011 at 07:32, Rafael Ibraim <address@hidden> wrote:
> Hello! I'm trying to create a shortcut to netcfg-menu(for those who
> don't know, it's a small dialog-like app that allows you to select
> which network profile you want to activate), but both
> (stumpwm:run-shell-command "sudo netcfg-menu") and
> (stumpwm:run-commands "exec sudo netcfg-menu") aren't working(no
> output is shown and nothing happens). Am I missing something?
> PS* netcfg-menu is correctly configured in sudoers to *not ask* for
> the root password.
> Thanks!

Since it is using dialog, it needs a terminal to run in, which you were missing
from your command.  What you might want to do is something like the following:

(defcommand run-netcfg-menu () ()
    "Run or switch to netcfg-menu"
    (run-or-raise "urxvt -title NetCfg -name NetCfgt -n NetCfg -e
netcfg-menu" ))

Then you can bind run-netcfg-menu to a key combination.

(define-key n (kbd "n") "netcfg-menu")

I have keymap assigned to Mod4-x which I use for my own key
combinations.  It means I just
press the Windows key, then "x", and then whatever key combination I
need to.  Sounds like
a lot of keys, but really isn't.

Mehul N. Sanghvi
email: address@hidden

reply via email to

[Prev in Thread] Current Thread [Next in Thread]