Here is my entire rc.local file
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
cd ~/xcape && ./xcape -e 'Control_L=Escape'
exit 0
In Ubuntu, I need to run ./xcape -e 'Control_L=Escape' inside the xcape directory in order to make my caps lock work as an esc key when pressed by itself, and control when held down.
I need to run this command every time I start up my computer, which is annoying, so I read through things to run this command automatically at startup and sources said to execute commands above the exit 0 which it is, and to have absolute paths. When i turn off the computer and turn it on, it doesn't work and my caps lock key acts as control, but not escape like it should. That's why I'm coming to the conclusion that my command is not being run. what should I do?