I'm new to xmonad. Is it possible to run a shell script (say ~/x.sh) every time you click, for example, f1? How does that look in a config file? I have googled quite a bit now without finding anything that looks like what I want.
Xmonad, how to bind a key to running a shell script?
2k views Asked by Var87 At
1
There are 1 answers
Related Questions in LINUX
- Is there some way to use printf to print a horizontal list of decrementing hex digits in NASM assembly on Linux
- Why does Hugo generate different taxonomy-related HTML on different OS's?
- Writes in io_uring do not advance the file offset
- Why `set -o pipefail` gives different output even though the pipe is not failing
- what really controls the permissions: UID or eUID?
- Compiling eBPF program in Docker fails due to missing '__u64' type
- Docker container unable to make HTTPS requests to external API
- Whow to use callback_query_handler in Python 3.10
- Create kea runtime directory at startup in Yocto image
- Problem on CPU scheduling algorithms in OS
- How to copy files into the singularity sandbox?
- Android kernel error: undefined reference to `get_hw_version_platform'
- Is there a need for BPF Linux namespace?
- Error when trying to execute a binary compiled in a Kali Linux machine on an Ubuntu system
- Issue with launching application after updating ElectronJs to version 28.0.0 on Windows and Linux
Related Questions in BASH
- When does Bash read heredocs?
- Why `set -o pipefail` gives different output even though the pipe is not failing
- Run an external command within jq to manipulate each values of a particular key
- API key 401 error in .env.development file
- How to "Enable mobile data" on a Huawei E3372 4G USB dongle using a bash script in Windows
- ImageMagick / Bash : pipe ignored(?) when filename format variable used
- MacOS Bash-Script: while read p and echo
- Parse command line arguments and write useful usage message without additional code
- JQ JSON - Values to Array
- why variable substitution is so different?
- postbank_pdf2csv: how to setup with Cygwin in Windows?
- Custom Bash functions & custom statements - Need some advice
- unexpected operator == in square brackets when trying to use gum lib
- How to disable a bash builtin inside a docker container
- Use sed or rename find series of alphabet then replace with with the same alphabet and a dash -
Related Questions in SHELL
- macOS - Most secure way of a GUI SUDO_ASKPASS
- When does Bash read heredocs?
- Why `set -o pipefail` gives different output even though the pipe is not failing
- Run multiple shell scripts in Dockerfile
- Alias does not take effect when I use Vim to execute external commands
- why variable substitution is so different?
- Error: fish: ${ is not a valid variable in fish
- Custom Bash functions & custom statements - Need some advice
- unexpected operator == in square brackets when trying to use gum lib
- Delete first three lines containing a certain word
- Keep the log for the last 14 days
- Iterate over items in one array and groups of items in second array
- Keep multi-version of a static-lib like what we do for shared-libs
- How to write function in bash for reuse shell commands inside using osascript?
- Why is it that when I pass certain directory names to `ls`, sometimes it does not list their contents?
Related Questions in WINDOW-MANAGERS
- Basic window manager: Z-order ping-pong between overlapping windows
- Xlib Window Manager: Closing Focused Window Causes Unexpected Shutdown
- How can I track button release events?
- Combine pinned apps and tasklist/open clients
- Disable X's middle-mouse paste functionality in a window manager
- Switch between multiple instances of the same app via alt-` in Windows 11
- Issue with displaying a custom layout over the Android accessibility screen
- root.overrideredirect() removes tkinter app from taskbar
- Force The Location Of A Gtk4 Window On A Wayland WM
- In AwesomeWM(git) is it possible to resize floating windows without rendering their contents in real time? (box resize)
- WindowManager: BadTokenException with Accessibility service context
- Issue with Caliburn Micro's WindowManager Method in WPF - Window Minimization Problem
- Tkinter methods lift(), lower(), deiconify() and geometry() not working (properly or at all) on Linux Mint Cinnamon
- XMonad IndependantScreens does not load workspaces on second Screen at startup
- Windows 11 application timing becomes uneven when "backgrounded"
Related Questions in XMONAD
- How can I change XMobar's Kbd monitor plugin such that clicking on it loops throught the layouts?
- Xmonad is ignoring my keybinding for switching workspaces
- Xmobar commands stuck on 'Updating...'
- Using the BatteryP monitor plugin's -a option causes waitForProcess error in XMobar
- How do I spawn a shell command from X monad and get it output?
- Clickable XMobar works... but crashes XMobar. What is the modern approach I should follow to have anything I want clickable in XMobar?
- How do I make xmonad use a haskell-based xmobar?
- How to manage XMonad (and xmobar and anything else related to it) via GHCup+cabal?
- How do I write the action to loop through layouts?
- How can I figure out specific app is running on Xmonad?
- XMonad: workspaces seem not to be working
- XMonad.Util.Paste.sendKey does not work in some applications?
- XMonad IndependantScreens does not load workspaces on second Screen at startup
- Adjust keybinding depending on number of screens in Xmonad
- Is there a `ifWindowCount` function in xmonad?
Popular Questions
- How do I undo the most recent local commits in Git?
- How can I remove a specific item from an array in JavaScript?
- How do I delete a Git branch locally and remotely?
- Find all files containing a specific text (string) on Linux?
- How do I revert a Git repository to a previous commit?
- How do I create an HTML button that acts like a link?
- How do I check out a remote Git branch?
- How do I force "git pull" to overwrite local files?
- How do I list all files of a directory?
- How to check whether a string contains a substring in JavaScript?
- How do I redirect to another webpage?
- How can I iterate over rows in a Pandas DataFrame?
- How do I convert a String to an int in Java?
- Does Python have a string 'contains' substring method?
- How do I check if a string contains a specific word?
Trending Questions
- UIImageView Frame Doesn't Reflect Constraints
- Is it possible to use adb commands to click on a view by finding its ID?
- How to create a new web character symbol recognizable by html/javascript?
- Why isn't my CSS3 animation smooth in Google Chrome (but very smooth on other browsers)?
- Heap Gives Page Fault
- Connect ffmpeg to Visual Studio 2008
- Both Object- and ValueAnimator jumps when Duration is set above API LvL 24
- How to avoid default initialization of objects in std::vector?
- second argument of the command line arguments in a format other than char** argv or char* argv[]
- How to improve efficiency of algorithm which generates next lexicographic permutation?
- Navigating to the another actvity app getting crash in android
- How to read the particular message format in android and store in sqlite database?
- Resetting inventory status after order is cancelled
- Efficiently compute powers of X in SSE/AVX
- Insert into an external database using ajax and php : POST 500 (Internal Server Error)
Use
xevto determine the keysym of yourF1-key, which is on my system0xffbe, and addto your
xmonad.hs. As described in XMonad.Util.EZConfig, usein your
mainfunction, and recompile+restart. Probably it also works withadditionalKeysPand<F1>, but i haven't tested that - the link above has all infos.