dotfiles/sxhkd
Marty Oehme 5ca27e5fd5
scripts: Add script to read wallabag articles
Added script to easily read wallabag articles on the command line (or
open them in browser), using the wallabag-cli python program in the
background.

Once invoked, will fetch a list of articles (optionally restricted to
read/unread/starred), and allow a choice through fzf.

Will then display the article in the user's preferred pager, editor, or
browser.

Can be invoked through the shell via `reader`, or through sxhkd shortcut
`r` from 'academia' mode (`alt + a`).
2021-03-05 17:07:11 +01:00
..
.config/sxhkd scripts: Add script to read wallabag articles 2021-03-05 17:07:11 +01:00
.local/bin Tiny fixes 2020-09-22 22:34:50 +02:00
README.md [sxhkd] Add script to show current sxhkd mode 2020-05-26 11:50:20 +02:00

sxhkd

sxhkd -- simple X hotkey daemon

sxhkd is set up to manage most of the key bindings in this dotfile configuraition. It is primarily used for three things: system control, to invoke rofi, and to switch between different desktop operating modes.

system control

  • super+x: lock the system, i.e. put a lockscreen in front of it, unlocked with your password
  • media keys: control the Brightness, Volume, Mute of the system
  • super+return: open a terminal

rofi invocations

  • super+backspace: system management (shutdown,reboot,logout,..)
  • super+space: app launching
  • super+r: extended run menu
  • super+p: password/secret autofill menu
  • super+F8: theme setting menu
  • super+q: quick access to bookmarks and search bangs

modal desktop

The modal setup of this desktop allows to first invoke an operating mode and then open the possibility for additional keybindings. For example, alt + m will invoke the media mode and then media playback can be controlled through the hjkl keys. Think of it like invoking the insert mode, or visual mode in a modal editor like vim.

The idea behind the modal system is to not overload normal system operation with key binds that are only needed every now and again, and mostly as a coherent package. If I want to control my media playback, by seeking forward or backward, having quick access to controlling the volume seems logical. But I may not want to open a scholarly pdf, or programming project at the same time, so these actions don't need to be included in a coherent 'media' mode.

The modes currently are:

  • media, for controlling playback and volume
  • academia, for opening pdf, seeing upcoming readings, and editing references

They are still in flux and may change every now and again as I put this modal setup to the test. To get a closer look at the actual key binds, look into .config/sxhkd/sxhkdrc for now.

modal notifications

To know which mode is currently active on the desktop, this module includes a script which will print sxhkd's current mode to stdout, or a file. This script can be used to show the active mode in a status bar, for example (as the polybar module in these dotfiles does).

The script lives in .local/bin/sxhkd-chain-labels and can be invoked from the path by default. To see available options and the configuration file format use sxhkd-chain-labels -h, or take look at the script itself.

This module overwrites the usual sxhkd program invocation using an alias, which makes sxhkd always (if no options are passed) create and use a named pipe in the XDG_RUNTIME_DIR directory. This is the default location the script will pick it up in.