From e0a8db11946b88d5aba3d00910adaf9d4409e0a5 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sun, 21 Sep 2025 15:59:09 +0200 Subject: [PATCH] aerc: Enable mailto functionality for aerc Explanation here: https://man.sr.ht/~rjarry/aerc/configurations/mailto.md I built a custom script 'aerc-in-terminal' since I want to expand the $TERMINAL env var and use that instead. `.desktop` files do not allow expanding vars (since they don't run in a user shell), so this is a compromise. --- office/.local/bin/aerc-in-terminal | 3 +++ office/.local/share/applications/aerc.desktop | 16 ++++++++++++++++ 2 files changed, 19 insertions(+) create mode 100755 office/.local/bin/aerc-in-terminal create mode 100644 office/.local/share/applications/aerc.desktop diff --git a/office/.local/bin/aerc-in-terminal b/office/.local/bin/aerc-in-terminal new file mode 100755 index 0000000..8a714bd --- /dev/null +++ b/office/.local/bin/aerc-in-terminal @@ -0,0 +1,3 @@ +#!/bin/sh +# If the user has set $TERMINAL, use it, otherwise fall back to foot. +exec "${TERMINAL:-foot}" -e --class float aerc "$@" diff --git a/office/.local/share/applications/aerc.desktop b/office/.local/share/applications/aerc.desktop new file mode 100644 index 0000000..2921b65 --- /dev/null +++ b/office/.local/share/applications/aerc.desktop @@ -0,0 +1,16 @@ +[Desktop Entry] +Version=1.0 +Name=aerc + +GenericName=Mail Client +GenericName[de]=Email Client +Comment=Launches the aerc email client +Comment[de]=Startet den aerc Email-Client +Keywords=Email,Mail,IMAP,SMTP +Categories=Office;Network;Email;ConsoleOnly + +Type=Application +Icon=utilities-terminal +Terminal=false +Exec=aerc-in-terminal %u +MimeType=x-scheme-handler/mailto