How to install Espanso on Debian or Ubuntu or Raspberry Pi OS

edafe.de/espanso

“Replace ‘:poke’ with ‘Pokémon,’ or save some time by replacing ‘:greeting’ with a stock email template. That’s the basic idea, but Espanso goes much further. It’s one of the most powerful utilities I’ve used, and if you’re willing to do a bit of legwork to set it up properly, it can be one of the most powerful tools on your PC, too”, writes Jacob Roach.

www.xda-developers.com

Installing Espanso for Wayland

Espanso is a cross-platform text expander written in Rust. Follow these instructions to install Espanso 2.3.0 for Wayland on your Debian-based distribution.

Compiling from source

If you are installing on any platform other than amd64 or simply prefer compiling software from source, start at Step 1.

Using the Debian binary package

If you are installing on amd64 hardware and would like to use the binary package for installation, start at Step 7.


Step 1

Install the required packages from your distribution’s software repository.

$ sudo apt install --yes build-essential git libdbus-1-dev libssl-dev libwxgtk3.*-dev libxkbcommon-dev wl-clipboard

Step 2

Download and install the Rust Programming Language.

$ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

Select option 1) – just press enter.

1) Proceed with standard installation (default - just press enter)
2) Customize installation
3) Cancel installation
>

Step 3

Reload the PATH environment variable to include cargo, which is the build tool for Rust.

$ source "$HOME/.cargo/env"

Step 4

Clone the Espanso GitHub repository onto your local machine.

$ git clone https://github.com/espanso/espanso "$HOME/git/espanso"

Step 5

Compile Espanso in release mode.

$ cd "$HOME/git/espanso" && cargo build -p espanso --release --no-default-features --features modulo,vendored-tls,wayland

Step 6

Move Espanso to its correct location in your Linux system.

$ sudo mv "$HOME/git/espanso/target/release/espanso" /usr/local/bin/

Continue with Step 10.


Step 7

Install the required packages from your distribution’s software repository.

$ sudo apt-get install --yes libwxgtk3.2-1t64 wl-clipboard

Step 8

Download espanso-debian-wayland-amd64.deb onto your local machine.

$ wget -P "$HOME/Downloads/" --show-progress https://github.com/espanso/espanso/releases/download/v2.3.0/espanso-debian-wayland-amd64.deb

Step 9

Install the downloaded package.

$ sudo dpkg -i "$HOME/Downloads/espanso-debian-wayland-amd64.deb"

Step 10

Give Espanso the permissions required for its operation.

$ sudo setcap "cap_dac_override+p" $(which espanso)

Check to see whether the Espanso binary was installed successfully.

$ espanso --version

Step 11

Register Espanso as a systemd service and launch the program.

$ espanso service register && espanso start && espanso status

Use the wizard and start with a practical example.

Image

Step 12

After completing the wizard, use [Alt + Space] to open the search bar.

GNOME and PIXEL desktops only

Change the default shortcut for opening the search bar to resolve an existing conflict.

$ sed -i 's/search_shortcut: ALT+SPACE/search_shortcut: ALT+SHIFT+SPACE/' "$HOME/.config/espanso/config/default.yml"

Use [Alt + Shift + Space] to open the search bar.

Experimental support for Wayland

Espanso has some known limitations under Wayland. Most notably, “there is currently no support for App-specific configurations”.

Click to copy