I posted Autorun Keyboard Settings for Awesomewm on Sunday, 12 April, 2020

Getting Control and Escape keys where I want them

Post linux settings awesomewm

Autorun Keyboard Settings for Awesomewm

I like my Caps Lock key to not be a Caps Lock key. Act as Escape when I tap on it. Act as Control when I press it with another key. And never ever enable SHOUT MODE.

This is the third time I’ve done this. This is also the third time I had to look up how to do this. Better save it on the site.

setxcbmap takes care of adding Control functionality and removing Caps Lock behavior. I need xcape for Escape key behavior. Since I’m running Manjaro on my Linux partition this week, I’ll use pamac to install.

$ pamac install xcape

I set up an autostart script to get this in every Awesomewm session.

#!/usr/bin/env bash

function run {
  if ! pgrep -f $1 ;

run setxkbmap -option ctrl:nocaps
run xcape -e 'Control_L=Escape'

It’s a script, so make sure it’s executable.

$ chmod 755 ~/.config/awesome/autorun.sh

Add one line of code to my rc.lua to make sure autorun.sh gets spawned on startup.

-- {{{ Autorun
-- }}}

And that’s it!


Got a comment? A question? More of a comment than a question? Talk to me about this post!

Indieweb Social

Did you mention this somewhere? I'd love it if you sent me the link!

disclaimer about timing

Mentions are sent to webmention.io. I fetch the latest mentions when building the site, so I may not see your feedback right away. Especially if my site's broken, which is often the case.

Public replies and mentions might be shared on the site, but I try to do a little quality check first.

Site Links