Sunday, July 24, 2022

How to run an interactive shell script in a terminal with two clicks in Mint XFCE

Rev 7/24/22


Running non-interactive shell scripts is just a matter of giving them execute-permission (right-click on file, select Properties, then Permissions, etc.), and then double-clicking on them.

But if your shell script requires user input, you need to run it in a terminal, and one way to do that is to create a Thunar custom action named something like Run Shell Script that runs the following command, without the brackets: [xfce4-terminal -e "./%n"], with the appearance-condition of *.sh. This is all explained in my post entitled "Performing spell-check via right-click in XFCE."  Then, to execute the shell script, just right-click on it, then select Run Shell Script in the menu which appears.

Mint 20.3 XFCE also has "screen zoom" (or "desktop zoom") capability. You just select Compiz as the window manager (go to Settings in the main menu, and select Desktop Settings, which is not the same as Desktop), and if you want to use the keyboard to control the zoom-level, go into Compiz-settings and disable the mouse zoom-settings (perhaps not necessary) and select some key-combination for zoom-in and zoom-out. I chose Alt-Super-(up-arrow) and Alt-Super-(down-arrow), respectively, and it works like a charm.

There are many other settings related to zoom, but I just left them alone. You could, for example, make it possible to use a mouse or touchpad to trace out a rectangular area on the screen and zoom it to full screen, or at least to maximum zoom-level if it's too small to zoom to full-screen. (The left mouse-button is Button 1.) In Xubuntu 22.04, the XFCE window-manager, xfwm4, apparently has a zoom function, so you wouldn't need to use Compiz for that.