From cd6644ea4ddc78597934ab0ef5ba50e3c3daa927 Mon Sep 17 00:00:00 2001 From: Mitja Felicijan Date: Sat, 8 Jul 2023 23:25:41 +0200 Subject: Moved to a simpler SSG --- public/alacritty-open-links-with-modifier.html | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100755 public/alacritty-open-links-with-modifier.html (limited to 'public/alacritty-open-links-with-modifier.html') diff --git a/public/alacritty-open-links-with-modifier.html b/public/alacritty-open-links-with-modifier.html new file mode 100755 index 0000000..e71f797 --- /dev/null +++ b/public/alacritty-open-links-with-modifier.html @@ -0,0 +1,25 @@ +Alacritty open links with modifier

Alacritty open links with modifier

Jun 25, 2023

Alacritty by default makes all links in the terminal output clickable and this +gets annoying rather quickly. I liked the default behavior of Gnome terminal +where you needed to hold Control key and then you could click and open links.

To achieve this in Alacritty you need to provide a hint in the configuration +file. Config file is located at ~/.config/alacritty/alacritty.yml.

hints:
+  enabled:
+  - regex: "(mailto:|gemini:|gopher:|https:|http:|news:|file:|git:|ssh:|ftp:)\
+            [^\u0000-\u001F\u007F-\u009F<>\"\\s{-}\\^⟨⟩`]+"
+    command: xdg-open
+    post_processing: true
+    mouse:
+      enabled: true
+      mods: Control
+

The following should work under any Linux system. For macOS, you will need to +change command: xdg-open to something else.

Now the links will be visible and clickable only when Control key is being +pressed.

Source: https://github.com/alacritty/alacritty/issues/5246

\ No newline at end of file -- cgit v1.2.3