How do I set caps to BOTH control and escape in ubuntu/gnome?

I've seen a few questions about this, but none that answered it to my satisfaction.

The question:

"I'm on ubuntu-flavored linux. I want to use caps as an escape and a control at the same time. (Esc on tap, control on hold). Karabiner lets me do this in Mac. Is there an easy way to do it for me?"

Previous stabs at the question:

  1. How do I install caps2esc?
  2. Remapping Caps Lock to Control and Escape (not the usual way)
  3. Overload capslock with esc and ctrl using xcape

Solution 1:

  1. Don't use xmodmap. It's a trap!
  2. Install xcape
  3. Use gnome-tweaks to turn capslock into control
  4. Use xcape -d to verify that capslock is key 66
  5. Set xcape -e '#66=Escape' in Startup Applications or ~/.profile

That's it!

No xmodmap. No crazy systemd settings. No dconf. It just works.

Solution 2:

This is possible based on

# make CapsLock behave like Ctrl:                                
setxkbmap -option ctrl:nocaps
# make short-pressed Ctrl behave like Escape:
xcape -e 'Control_L=Escape'