Lorenzo Bettini is an Associate Professor in Computer Science at the Dipartimento di Statistica, Informatica, Applicazioni "Giuseppe Parenti", Università di Firenze, Italy. Previously, he was a researcher in Computer Science at Dipartimento di Informatica, Università di Torino, Italy. He has a Masters Degree summa cum laude in Computer Science (Università di Firenze) and a PhD in "Logics and Theoretical Computer Science" (Università di Siena). His research interests cover design, theory, and the implementation of statically typed programming languages and Domain Specific Languages. He is also the author of about 90 research papers published in international conferences and international journals.
Dolphin might also communicate with an existing instance through D-Bus, opening a window on your real desktop. To avoid this, use an isolated D-Bus session:
Instead of repeating these environment variables, add the following function to your.bashrcor.zshrc:
1
2
3
4
5
6
7
8
9
xvfb-wayland(){
env-uWAYLAND_DISPLAY-uXDG_SESSION_TYPE\
GDK_BACKEND=x11\
QT_QPA_PLATFORM=xcb\
xvfb-run-a\
--server-args="-screen 0 1920x1080x24"\
"$@"
}
Now you can simply run:
1
2
xvfb-wayland./mvnwverify
or:
1
2
xvfb-waylanddbus-run-session--dolphin--new-window
Conclusion
When running GUI applications or automated UI tests under KDE Wayland, remember thatxvfb-runalone might not be sufficient.
The key is toexplicitly select the X11 backendusingGDK_BACKEND=x11for GTK/SWT orQT_QPA_PLATFORM=xcbfor Qt, while removing the Wayland environment variables.
This allows GUI tests to run on a virtual display without interfering with your regular Wayland desktop session.
Changes queued for next boot. Run "systemctl reboot" to start a reboot
Note that you must reboot when you layer packages.
Quoting from the documentation:
Using package layering creates a new deployment, or bootable filesystem root. It does not affect your current root. This preserves rollback and the transactional model, but means that the system must be rebooted after a package has been layered or updated. You can alternatively use rpm-ostree install --apply-live <package-name> to also temporarily apply the change directly to your currently booted deployment. It’s generally expected that you use package layering sparingly, and use Flatpak and Toolbx whenever possible.
After rebooting, we can verify that ZSH is correctly installed and it’s also reported as part of the current image:
gccis required fortree-sitter-cliandneoviminstallation via Homebrew.
the two gnome applications are not available as flatpaks
I prefer having the JDK (my most used application being Java, my main programming language) as a system package, especially to have Eclipse pick it automatically
I’m reporting on my first experiments with Garuda Linux (Arch-based), the latest release, “Temeraire” (260819), in the Mokka edition. I’m testing that in a virtual machine.
I can anticipate thatI love the aesthetic of this distro, especially in thisMokka edition, which is more sober than the “dragonized” version.
The installation
The installation is rather smooth, especially if you’re used to Calamares-based installers.
Let’s start the installation.
One thing I also noted in the past is that the black font is not easily readable in the combo boxes during the installation dialog. It turns white when selected, then returns to black.
The installer did not detect my location (Italy), which is strange because other Calamares-based installers have never had this issue.
I had to adjust that manually:
Similarly, for the keyboard layout (which I had already configured as Italian in the live environment), I had to set it manually.
Since this is a virtual machine, I go with “Erase disk”, and also enable swap with hibernation. Note that it only supports BTRFS! As expected, it also supports system encryption.
After inserting the user information, we’re ready to start:
Let’s enjoy a few slides during the installation, telling us what Garuda provides.
The installation took only a couple of minutes. I seem to understand that it does not download anything else from the Internet. After all, unlikeEndeavourOSandCachyOS, you have an ISO for each edition (DE or WM).
The installed system
Let’s reboot.
I love the aesthetic look of Garuda from the very beginning 🙂
Note that the setup assistant needs to update the system (as I said above, the installer doesn’t seem to download from the Internet). The time you saved during the installation has to be paid during the update 😉
By the way, Garuda providesChaotic-AUR! (i.e., “Semi-automated binary repository for AUR packages”). One thing I personally haven’t tried yet.
Global menu like in macOS: if you’re not used to that, it’ll take some time. You might get the feeling that applications have no menu bar at all 😉
Similarly,window controls are on the leftrather than the right (though this can be changed in KDE settings).
We can also see that snapper and automatic snapshots are already configured by looking at the end of the update output:
Pressing ENTER leads us to the Setup Assistant:
I’m not planning to install anything at this stage, but it’s interesting to have such a tool.
Then, we get to the Garuda Toolbox, which also tells us to reboot.
Note that the kernel is “linux-garuda”, which is based on the CachyOS one.
There are many interesting tools in the Garuda Toolbox.
Evenhaving all the configuration files available in one place, ready to edit, is really helpful.
I won’t talk more about the Garuda Toolbox, but it’s a very useful tool! I suggest you explore that.
Let’s see a few other things and configurations.
Krunner is configured to appear in the center of the screen (I like it, though I typically leave it on the top, its default position):
Desktop effects everywhere: blur, wobbly windows, a magic lamp for minimizing a window, cover flow for the task switcher, etc. I love these effects!
Note that the background is blurred when a window is focused.
I’ve already noted the use ofSnapper; the “Snapper Tool” in the dock is not Btrfs Assistant, as I thought, but a simpler one. However, Btrfs Assistant is also installed by default, together with Btrfs maintenance.
Let’s open Konsole, and we get the glorious fastfetch, also telling us that the default shell is fish (I’ll have to try fish someday):
Nice icons, theme, and fonts!
The partitioning, especially from the BTRFS point of view, is the standard one:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
sudo lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sr0 11:0 1 1024M 1 rom
zram0 253:0 0 15,5G 0 disk [SWAP]
vda 254:0 0 100G 0 disk
├─vda1 254:1 0 300M 0 part /boot/efi
├─vda2 254:2 0 82,6G 0 part /var/tmp
│ /var/cache
│ /var/log
│ /srv
│ /home
│ /root
│ /
└─vda3 254:3 0 17,1G 0 part [SWAP]
It’s nice to havezramconfigured by default as well.
In this post, I show how I installedCachyOSLinux (Arch-based) on a Geekcom IT13 Mini PC.
These are the main specs of the Mini PC:
Processors: 16 × 13th Gen Intel® Core™ i7-13620H Memory: 32 GiB of RAM (31.1 GiB usable) Graphics Processor: Intel® Graphics
I’m installing CachyOS “cachyos-desktop-linux-260628.iso”; I downloaded the ISO and copied it into myVentoyUSB stick.
The installation procedure
The installation procedure is rather easy and smooth, especially if you’re used to a Calamares-based installer (e.g., the one also used byEndeavourOS).
Before starting the installer from the Welcome dialog, I changed the keyboard layout, using the standard KDE System Settings element:
By the way, the scaling was automatically set to 130%; that’s quite a strange setting (in the past, I was using 125% on this computer). However, everything looks great. The same scaling will persist after installation, and I think I’ll keep it.
I have Windows on this computer (which I never use, but for the moment I’ll keep it). I had previously created another EFI partition because the one that came with Windows is too small.
So I just need to select it and set the correct mount point:
Then, I mount additional existing partitions to the mount points I want:
I’m removing the existing Linux distributions I had installed on this computer (EndeavourOS and Arch):
Then, I create the main partition, BTRFS. Note that Calamares allows you to specify that a partition is put at the end of the disk (if I remember correctly, other installers don’t allow you to do that):
When I go on, I get the usual warning about a too-small EFI partition. However, I know there’s enough room, and I go on.
I select KDE Plasma (by the way, CachyOS provides several desktop environments!):
I select the printing support packages, and I keep the default ones.
You might want to have a look at the default packages:
User details as usual:
A final look at the partitioning scheme:
Let’s start and look at a few slides during the installation.
As you might know, CachyOS aims to be a performance-based distro, with optimized compiled packages and kernels. For my computer, it uses the “v3” optimization:
Done!
Let’s restart!
Tweak boot options
Unfortunately, on this mini PC, installing a Linux distribution does not automatically set its GRUB entry as the default. If you had a previous installation, its GRUB will still be used. If, as in this example, you remove previous distributions, you get an error when booting from GRUB because it cannot find anything.
We have to fix it in the UEFI settings: when booting, press F7to access the boot menu.
You see that “cachyos” is the last one.
Let’s select “Enter Setup”:
“Fixed Boot Order Priorities” does not let you change the order, only see it:
We must use “UEFI NVME Drive BBS Priorieties”:
Select the first option:
Select the entry that must become the first option (yes, quite confusing!):
And now we’re done:
Now, we finally get the CachyOS GRUB menu!
Stay tuned for the upcoming blog post on the installed system!
After installing macOS Tahoe, two additions immediately stood out to me: proper battery charge limits and a much more useful Spotlight.
A real battery charge limit—even on my M1 Mac
macOS can now limit charging to80%, 85%, 90%, 95%, or 100%directly from the Battery settings.
I normally use my MacBook connected to power for long periods, so being able to choose an 80% limit should help reduce unnecessary battery aging. I especially appreciate that Apple has made this available even on my older M1 Mac.
When this is set, you can see that charging is paused if above 80%, and you have the option to explicitly charge it to full:
If it’s below 80%, it will charge only up to 80%:
Optimized Battery Charging is still available, so I can either let macOS learn my routine or set a fixed limit myself.
You can also set the “Low Power” mode:
See the battery icon turning yellow when set.
On a MacBook Pro, you also have more choices concerning the Energy Mode:
Spotlight finally has useful filtering shortcuts
Spotlight has also become much more practical. Searches can now be restricted immediately with keyboard shortcuts:
⌘ 1for applications
⌘ 2for files
⌘ 3for actions
⌘ 4for clipboard contents
The/key can be used to filter the current search, while the Up Arrow opens the search history.
This makes Spotlight feel less like a simple application launcher and more like a proper keyboard-driven command center.
Clipboard search is optional, which is sensible given that copied content may contain sensitive information.
These are not necessarily the flashiest changes in macOS Tahoe, but they are exactly the kind of small, practical improvements that make a difference in everyday use.
I usechezmoito manage my dotfiles, including a few small scripts that install development tools in my home directory.
One of these scripts installs Apache Maven. I keep it as arun_onchange_after_script so that chezmoi runs it only when the script changes. This is especially convenient for versioned tools: when I want to upgrade Maven, I change the version number in the script, and the nextchezmoi applyinstalls the new version.
The script is called:
1
2
run_onchange_after_20-install-maven.sh
Here is the complete script.
Shell
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
#!/usr/bin/env sh
set-eu
# Change this value to make chezmoi run this script again.
[-x"${extracted_dir}/bin/mvn"]||die"Extracted Maven archive is invalid."
rm-rf"$TARGET_DIR"
mv"$extracted_dir""$TARGET_DIR"
log"Installed Maven ${MAVEN_VERSION} at ${TARGET_DIR}."
fi
if[-L"$CURRENT_LINK"]||[!-e"$CURRENT_LINK"];then
ln-sfn"$TARGET_DIR""$CURRENT_LINK"
else
die"${CURRENT_LINK} exists and is not a symlink."
fi
create_bin_linkmvn
create_bin_linkmvnDebug
log"Maven ${MAVEN_VERSION} is available at: ${CURRENT_LINK}/bin/mvn"
case":${PATH:-}:"in
*":${BIN_ROOT}:"*);;
*)
log"Add this to your shell config if needed:"
log" export PATH=\"${BIN_ROOT}:\$PATH\""
;;
esac
What this script does
The script installs a specific Maven version into my home directory, without requiring root privileges and without relying on a distribution package manager.
The versioned installation lives under~/.local/opt/apache-maven-<version>, while~/.local/opt/mavenis a stable symbolic link to the currently selected Maven version.
This gives me two useful properties at the same time: I can keep explicit versioned installations, but I can also refer to Maven through a stable path.
Whyrun_onchange_after_
chezmoi treats scripts with names such asrun_onchange_after_20-install-maven.shspecially.
Therun_onchange_part means the script is executed when its contents change. Theafterpart means it runs after chezmoi has applied the rest of the dotfiles.
That is exactly what I want here. Maven does not need to be downloaded on everychezmoi apply. It only needs to be installed when I change something relevant in the script, such as the Maven version.
To upgrade Maven, I change this line:
1
2
MAVEN_VERSION="3.9.16"
Then I run:
1
2
chezmoiapply
Since the script content changed, chezmoi runs it again and installs the new Maven version.
Why install under~/.local
I prefer installing this kind of tool under my home directory:
1
2
~/.local/opt
and exposing commands through:
1
2
~/.local/bin
This avoids usingsudo, keeps the installation independent from the operating system package manager, and makes the setup easier to reproduce across machines.
It also avoids interfering with any Maven version installed system-wide. The Maven installed by this script is simply the one that appears first in myPATH.
Downloading from Apache mirrors
The script constructs the Maven download URL based on the configured version. For current Maven releases, it downloads from the main Apache download infrastructure.
There is also a fallback to the Apache archive. This matters because older versions are eventually removed from the main mirrors. Since dotfiles often pin specific versions for a long time, falling back to the archive makes the script more robust.
This is useful when setting up a new machine months later: even if the pinned Maven version is no longer on the primary mirror, the script can still find it in the Apache archive.
Verifying the archive
The script downloads both the Maven archive and the corresponding SHA-512 checksum file.
Before extracting Maven, it computes the local SHA-512 digest of the downloaded archive and compares it with the published checksum. If the two values do not match, the script stops immediately.
The checksum parsing is intentionally tolerant: instead of depending on one exact checksum-file format, the script scans the file for a 128-character hexadecimal token, which corresponds to a SHA-512 digest.
For computing the local checksum, the script supports several common tools:
sha512sum
shasum
openssl
This makes the script usable on different Unix-like systems without assuming one specific checksum command.
Idempotency
The script is safe to run more than once.
If the requested Maven version is already installed and contains an executablemvn, the script does not download or extract it again. It still refreshes the stable symlink and the command links, but it avoids unnecessary network access.
When installation is needed, everything is done first in a temporary directory. The archive is downloaded there, the checksum is verified there, and Maven is extracted there. Only after the extracted archive looks valid is it moved into the final installation directory.
That keeps partially downloaded or invalid archives away from the final destination.
Stable symlinks
The script creates a stable Maven symlink:
1
2
~/.local/opt/maven
pointing to the selected versioned installation:
1
2
~/.local/opt/apache-maven-3.9.16
Then it creates command symlinks in~/.local/bin:
1
2
3
~/.local/bin/mvn
~/.local/bin/mvnDebug
These point through the stable Maven symlink instead of directly to the versioned directory.
That means the command links do not need to change structurally when Maven is upgraded. Themavensymlink changes, andmvnfollows it.
The script is also conservative: it overwrites existing symlinks, but it does not overwrite existing non-symlink files. If a real file or directory already exists where the script wants to create a symlink, the script either keeps it or stops with an error.
PATH handling
At the end, the script checks whether~/.local/binis already inPATH.
If it is not, the script does not automatically modify shell startup files. It simply prints a reminder to add:
1
2
exportPATH="$HOME/.local/bin:$PATH"
I prefer this because installation scripts should not unexpectedly edit shell configuration files. The dotfiles themselves are the right place to managePATH.
Why not use the package manager?
Installing Maven from the system package manager is perfectly fine in many cases.
For my dotfiles, however, I prefer this script because it gives me:
a specific upstream Maven version;
the same version across different machines;
a user-local installation;
no dependency on distribution-specific package names;
a simple upgrade mechanism through chezmoi;
checksum verification before installation.
This approach is not meant to replace the package manager for everything. It is just a good fit for development tools where I care about the exact upstream version.
Final result
After running:
1
2
chezmoiapply
Maven is available as:
1
2
mvn--version
and the installation is fully contained under my home directory.
The important paths are:
1
2
3
4
~/.local/opt/apache-maven-3.9.16
~/.local/opt/maven
~/.local/bin/mvn
This keeps the setup explicit, reproducible, and easy to update across machines.
Here’s an example updating the dotfiles on a machine after updating the Maven version:
I report my first experiences with LM Studio in (Arch) Linux.
LM Studio is a desktop application that allows you to discover, download, and run Large Language Models (LLMs) entirely on your own computers, offline.
This is the hardware and system I’m testing it (you see, no GPU with VRAM):
In the past, I had several problems usingarchinstallfor installing Arch Linux in a dual boot with another existing Linux installation. In fact, I gave up using archinstall andcreated my own script for installing Arch.
In particular, I experienced these two problems:
Archinstall failed installing Arch if the disk already contained a BTRFS partition
The “/boot/efi/” mount point could not be used: you had to use “/boot” (since all my other Linux installations use “/boot/efi”, which required a few tweaks that I was not willing to spend time on)
I tried once more with the July 2026 version, and both problems are finally gone (though, for the second one, there are a few things to know, as shown in the rest of this blog post).
Besides experimenting with Archinstall for dual boot with another Linux installation, I’ll also take the chance to quickly review a few parts of the installation procedure.
I experimented with the process on a KVM virtual machine, where I had already installed EndeavourOS, leaving some space for another installation.
Let’s keep an eye on the current state of “/boot/efi” and see later how Archinstall handles it.
And here’s the UEFI entries; the existing EndeavourOS installation is the “UEFI Misc Device”.
Let’s start the installation by booting the Arch Linux July 2026 ISO and running the Archinstall script:
The crucial part is disk partitioning, where we must select “Manual Partitioning”
Select the existing UEFI partition
And assign the “/boot/efi” mount point:
Then, select the empty partition, and create a new BTRFS partition:
Now, the sad part: I’m used to EndeavourOS or other Calamares-based installers that automatically create the default subvolumes when you create a BTRFS partition for the “/” mount point. Instead, in Archinstall, you have to deal with the subvolumes yourself:
Following the same process four times, I created the standard subvolumes (I skipped the ones for “/var/lib/portables” and “machines, which EndeavourOS creates, since I don’t care about them):
This is the final layout:
Now, select GRUB:
Here’s the crucial part: “Install to removable location”, enabled by default. If you press ENTER, you get more details:
The text explains a few things and tells you it is safe to leave it on.
However, if you do leave it on, then Archinstall will overwrite the NVRAM entry for existing Linux installations.
I triedboth options in two different virtual machines; let’s see what happens:
Select NO
With this option, Arch will be the default boot option in the UEFI; however, existing entries can still be selected from the UEFI menu.
So, let’s select NO, and here’s what that entry reports:
Let’s conclude the installation and reboot.
Here’s the GRUB from Arch; let’s enter the UEFI settings
“GRUB” is Arch Linux, and “UEFI Misc Device”, if you look at the beginning of the blog post, is the existing EndeavourOS:
In fact, if we select it and press ENTER, we get to the EndeavourOS GRUB menu:
And here’s how “/boot/efi” has been modified:
Select YES
Let’s instead select YES (as I said, this is a parallel experiment on a different virtual machine, with the same existing EndeavourOS installation).
Of course, we have the Arch GRUB:
And the “/boot/efi/” still has the previously existing EndeaavourOS efi file.
However, if we enter the UEFI settings:
We no longer have an entry for EndeavourOS. This time, “UEFI Misc Device” is the Arch entry, not the EndeavourOS anymore.
However, we can manually re-add the EndeavourOS entry, because its EFI file is still there.
The procedure depends on the UEFI Firmware settings; in this case, we use the settings provided by “Virtual Machine Manager” Tiano Firmware settings:
We have to navigate to the EndeavourOS EFI file:
And now we have the EndeavourOS entry back (this time, with its real name):
Final thoughts
Things have improved, and Archinstall is probably usable for dual-booting now. I’ll try that on real hardware.
However, I still find it’s still far from being as useful as Calamares-based installers of EndeavourOS, CachyOS, or Garuda, to name a few.
I use FedoraSilverbluewithGNOME, and I have LibreOffice installed as a Flatpak.
Recently, I hit a strange problem: when searching for an office document from the GNOME Dash — for example, an.odtor.odsfile in my Dropbox folder — and selecting it, LibreOffice appeared to start, but then failed with an error saying that a file like this did not exist:
The problem only happened when opening documents from theGNOME Dash search results.
The mysterious/run/user/1000/docpath
When GNOME opened the file from the Dash, LibreOffice complained about a path like this:
1
2
/run/user/1000/doc/149071dc/myfile.odt
This is not a normal temporary directory.
It is part of the Flatpak / XDG document portal mechanism. The document portal exposes selected host files to sandboxed applications through a FUSE mount under:
1
2
/run/user/$UID/doc
The directory name that looks like a hash is a document portal ID.
In my case:
1
2
149071dc
was the document ID.
The file under/run/user/1000/doc/...was not a copy. It was a portal-backed view of the original file. That explains why deleting it also deleted the original document.
but the usual.chezmoiscripts/run_before_*hooks run too late to install it for thefirstapply
I wanted a solution that was:
automatic
shell-based
version-pinned
rerun only when the installer script changes
This post shows the setup I ended up with.
The problem
At first glance, it seems natural to put an installer script into.chezmoiscripts, for example, as arun_onchange_before_*script.
That helps with normal lifecycle management, but itdoes notsolve the initial bootstrap.
Why? Becausechezmoineeds to compute the target state before it runs those scripts, andmodify_files participate in that computation. If those files usechezmoi_modify_manager, then the binary must already existbeforechezmoi applyreaches the script phase.
So the core issue is:
chezmoi_modify_managermust be installed beforechezmoi applystarts doing the work that depends on it.
The approach
The solution is to split the problem into two:
Put the installer in.chezmoiscriptsas arun_onchange_before_*script, so the script is tracked bychezmoiand reruns when its contents change.
Wrapchezmoiwith a small shell function that manually runs that installer scriptbeforedelegating to the realchezmoi apply.
That gives us the best of both worlds:
properchezmoi-managed script in the source repo
successful first bootstrap
automatic reinstall when the installer changes, such as when bumping the pinned version
The script is version-pinned, architecture-aware, and idempotent. It also keeps a tiny version stamp, so it can skip work when the correct version is already installed.
The application under test is an Eclipse-based application, so at first I expected the failure to be caused by some SWTBot timing issue, focus issue, or maybe a regression in my own code.
However, the screenshot captured by the failed test showed something completely unrelated to my application:
That is not Eclipse. That is macOS Setup Assistant.
More specifically, it was the macOS Analytics screen asking whether to share analytics data with Apple and app developers. Since SWTBot drives the UI that currently has focus, this dialog was stealing focus from Eclipse and making the test interact with the wrong window.
The first workaround
My first attempt was to dismiss the Analytics dialog before starting the SWTBot tests:
YAML
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
- name: Dismiss macOS Analytics setup dialog
if: runner.os == 'macOS'
shell: bash
run: |
foriin{1..30};do
ifpgrep-x"Setup Assistant">/dev/null;then
echo"Found macOS Setup Assistant; trying to dismiss it"
osascript<<'APPLESCRIPT'||true
tellapplication"System Events"
ifexistsprocess"Setup Assistant"then
tellprocess"Setup Assistant"
setfrontmosttotrue
delay0.2
try
clickbutton"Continue"ofwindow1
onerror
keycode36
endtry
endtell
endif
endtell
APPLESCRIPT
sleep2
pgrep-x"Setup Assistant">/dev/null||exit0
fi
sleep1
done
This looked reasonable, but then the failure changed.
The new screenshot showed another Setup Assistant page:
This time it was the “Welcome to Mac” screen.
So the script was managing to click something, but Setup Assistant was still not completely gone. SWTBot was still losing focus before the actual Eclipse application could be tested.
The final workaround
The most robust fix was to avoid heredocs entirely and pass the AppleScript using repeatedosascript -earguments.
Here is the workflow step I now use:
YAML
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
- name: Remove macOS Setup Assistant
if: runner.os == 'macOS'
shell: bash
run: |
foriin{1..10};do
if!pgrep-x"Setup Assistant">/dev/null;then
echo"Setup Assistant is not running"
exit0
fi
echo"Setup Assistant is running; trying to dismiss it"
osascript\
-e'tell application "System Events"'\
-e'if exists process "Setup Assistant" then'\
-e'tell process "Setup Assistant"'\
-e'set frontmost to true'\
-e'delay 0.2'\
-e'try'\
-e'perform action "AXPress" of button "Continue" of window 1'\
-e'end try'\
-e'delay 0.5'\
-e'end tell'\
-e'key code 36'\
-e'end if'\
-e'end tell'>/dev/null2>&1||true
sleep2
done
echo"Setup Assistant did not go away; killing it"
pkill-9-x"Setup Assistant"||true
sleep2
ifpgrep-x"Setup Assistant">/dev/null;then
echo"::error::Setup Assistant is still running"
exit1
fi
This does three things:
It checks whetherSetup Assistantis running.
It tries to press the visible Continue button.
If Setup Assistant still refuses to disappear, it kills the process before the UI tests start.
After adding this step before launching Eclipse, the SWTBot tests started passing again.
Why this matters for SWTBot
SWTBot tests are particularly sensitive to focus problems.
They do not just test some isolated backend logic. They drive a real UI. If another native macOS window appears in front of the Eclipse workbench, the test can fail in confusing ways:
1
2
3
4
WidgetNotFoundException
TimeoutException
Couldnotfindshell
Couldnotfindbutton
The actual problem may have nothing to do with SWTBot or Eclipse. The test may simply be interacting with the wrong application.
That is why screenshots from failed UI tests are invaluable. Without the screenshot, I would probably have spent a lot more time debugging Eclipse, SWTBot, or my own application.
Sometimes a command installed with Homebrew needs to be executed as root. A good example isnethogs, which needs elevated privileges to inspect network traffic.
The problem is that this often fails:
1
2
sudonethogs
even though this works:
1
2
nethogs
The reason is thatsudousually runs with a different, restrictedPATH. Your normal shell can find Homebrew commands, butsudomay not know where Homebrew installed them.
On Linux, Homebrew commands may live somewhere like:
1
2
3
/home/linuxbrew/.linuxbrew/bin
/home/linuxbrew/.linuxbrew/sbin
On macOS, they are commonly under:
1
2
/opt/homebrew
on Apple Silicon, or:
1
2
/usr/local
on Intel Macs.
The simple one-command solution
A quick workaround is to resolve the command path before callingsudo:
1
2
sudo"$(which nethogs)"
This works becausewhich nethogsis evaluated by your normal shell, using your normalPATH, beforesudoruns.
So instead of askingsudoto findnethogs, you give it the full path directly.
A shell function for one command
You can wrap that in a function:
Shell
1
2
3
nethogs(){
sudo"$(which nethogs)""$@"
}
This lets you run:
1
2
3
4
nethogs
nethogseth0
nethogs-d5
and still preserve arguments correctly.
A generalbrew-sudohelper
A better cross-platform approach is to define a small helper that asks Homebrew for its prefix, checks bothbinandsbin, and then runs the matching executable withsudo.
Shell
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
brew-sudo(){
if["$#"-eq0];then
echo"usage: brew-sudo <command> [args...]">&2
return2
fi
cmd="$1"
shift
prefix="$(brew --prefix)"||return
fordirinbinsbin;do
exe="$prefix/$dir/$cmd"
if[-x"$exe"];then
sudo"$exe""$@"
return$?
fi
done
echo"brew-sudo: $cmd not found in $prefix/bin or $prefix/sbin">&2
return127
}
Now you can run Homebrew-installed commands with root privileges like this:
1
2
3
4
brew-sudonethogs
brew-sudonethogseth0
brew-sudosome-command--some-option
This works across Linux and macOS becausebrew --prefixreturns the correct Homebrew prefix for the current system.
Defining command-specific wrappers
You can then define convenient wrappers in terms ofbrew-sudo:
Shell
1
2
3
nethogs(){
brew-sudonethogs"$@"
}
This gives you the best of both worlds:
1
2
3
4
nethogs
nethogseth0
nethogs-d5
while internally resolving to something like:
1
2
sudo/home/linuxbrew/.linuxbrew/sbin/nethogs"$@"
on Linux, or the corresponding Homebrew path on macOS.
Full version
Put this in a shell file sourced by bothbashandzsh, or copy it into both~/.bashrcand~/.zshrc:
Shell
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
brew-sudo(){
if["$#"-eq0];then
echo"usage: brew-sudo <command> [args...]">&2
return2
fi
cmd="$1"
shift
prefix="$(brew --prefix)"||return
fordirinbinsbin;do
exe="$prefix/$dir/$cmd"
if[-x"$exe"];then
sudo"$exe""$@"
return$?
fi
done
echo"brew-sudo: $cmd not found in $prefix/bin or $prefix/sbin">&2
return127
}
nethogs(){
brew-sudonethogs"$@"
}
A note onsudoand Homebrew
This approach does NOT runbrewitself withsudo. It only usesbrew --prefixto locate Homebrew’s installation directory, then runs a specific Homebrew-installed executable withsudo.
That distinction matters: runningbrew installorbrew upgradewithsudois generally the wrong approach, but running a tool likenethogswithsudois appropriate when the tool itself needs root privileges.
Alternative: adding Homebrew to/etc/sudoers
Another possible solution is to teachsudoabout Homebrew’s executable directories.
On many systems,sudouses a restricted path configured in/etc/sudoers, often through a setting calledsecure_path. You can inspect and edit it with:
It does not give users newsudopermissions by itself. A user still needs to be allowed to run commands withsudoin the first place. But it does make Homebrew-installed commands part of sudo’s command lookup path.
That can be undesirable because Homebrew prefixes are often writable by the normal user, or by users in an admin group. In general, root’sPATHshould avoid directories that non-root users can modify. Otherwise, it becomes easier to run a user-controlled executable as root accidentally.
For that reason, I prefer the wrapper approach shown above.
That works well for the very first setup, because my SSH keys are not installed yet.
After the firstchezmoi apply, though, my SSH keys are finally in place, and I want the dotfiles repository itself to switch from HTTPS to SSH automatically.
This sounds simple, but there is a small gotcha.
The goal
I wantedchezmoi applyto do this at the end of the first run:
detect that the repo remote is using HTTPS
convert it to the SSH form
updateoriginautomatically
For example:
fromhttps://github.com/username/dotfiles.git
togit@github.com:username/dotfiles.git
My first attempt
My first version used arun_once_after_...script that calledchezmoi source-pathto find the source repo:
The problem is that the script is being runbychezmoi apply.
So if the script itself runs anotherchezmoicommand, the second process tries to acquire the same persistent state lock that the originalchezmoi applyalready holds.
In other words:
chezmoi applystarts
it runs your script
your script runschezmoi source-path
the nestedchezmoiprocess waits on the lock
eventually it times out
The fix
The solution is to avoid callingchezmoiinside the script.
Instead, make the script atemplateand use{{ .chezmoi.sourceDir }}to inject the source directory path when chezmoi renders the script.
On Atomic Desktops, you can keep using your computer while applying OS updates as they are downloaded and installed in the background. Once an update has been installed, you can reboot your computer to start using the new version. You will not have to wait for the update to be installed either during shutdown or boot up.
On Fedora Silverblue and Fedora Kinoite, OS updates are downloaded automatically and you will be notified when updates are ready to be applied via a reboot. This behavior can be changed in the settings.
On a fresh installation, these are the details of the installed system:
If we open the Gnome Software, we can see that updates are already detected:
Actually, the system is already downloading the updates (and applying them on a new image); after a while, you can simply restart:
After the reboot, the updated image will take effect:
In particular, just rebooting will lead you to a possibly already downloaded and updated image.
Automatic update behavior can be seen in the Gnome Software preferences:
From the command line, you can check available updated images:
GPGSignature: Valid signature by C6E7F081CF80E13146676E88829B606631645531
The “status” command also shows when the new image is being downloaded; for example, after a fresh installation, a new upgrade will be automatically checked and downloaded:
When setting upSwayas your Wayland compositor, you might want to organize yourWaybarconfiguration in a non-standard location — for example, keeping a dedicated~/.config/waybar/sway/directory to separate your Sway-specific bar configuration from others.
This seemingly simple task comes with a couple of subtle pitfalls worth knowing about.
The~Expansion Problem
The most natural approach would be to launch Waybar directly from thebarblock in your Sway config:
Unfortunately, thisdoes not work. Theswaybar_commanddirective does not perform shell expansions, so~is passed literally to the command instead of being expanded to your home directory. Waybar will fail to find the configuration file.
However, this approach has its own drawback: Waybar launched viaexecis no longer managed by Sway’sbarsubsystem. This means that Sway bar commands — such asswaymsg bar hidden_state toggleto show/hide the bar —will not work.
The Solution: A Wrapper Script
The cleanest solution is to write a small wrapper script that handles the expansion and launches Waybar with the desired configuration:
Now Waybar is properly managed by Sway’s bar subsystem, and the script handles path expansion.
The PATH Problem
There is one more subtle issue: the script lives in~/.local/bin/, which maynot be inPATHwhen Sway starts. Sway is typically launched from a display manager or TTY, where the environment is minimal and does not source your shell’s configuration files (e.g.,~/.bashrcor~/.zshrc).
To ensure~/.local/binis inPATHfor Sway and all processes it spawns, add it in your login shell profile:
1
2
exportPATH="$HOME/.local/bin:$PATH"
Your display manager or TTY login will source this file, making the script discoverable when Sway starts.
Fedora Silverblue is Fedora’satomic, GNOME-based desktopbuilt around animage-based, mostly read-only systemrather than a traditional mutable Linux install.
As anatomic desktop: the base OS is image-based, updates are applied as a new deployment, and you switch to it on reboot. That gives you aneasy rollbackif an update goes wrong.
It is designed toseparate apps from the host OS: GUI apps are primarily installed as Flatpaks, command-line/dev tooling is commonly run in Toolbx containers, and traditional RPMs can still be added through therpm-ostree layeringwhen needed.
The main upside isstability and reproducibility: Fedora says Atomic Desktops are intended to be more stable, easier to test, and well-suited to containerized apps and development.
Thus, it is rather different from other standard “mutable” Linux distros, especially when it comes to installing software.
I’m starting a series of blog posts on Fedora Silverblue.
At the moment, I’m NOT considering using it as my daily driver (which, for now, isArch, specificallyEndeavourOS).
The installation process
The installation procedure is the typical Fedora one:
It detected my language (though I then switched to English):
Then, I switched to the Italian keyboard layout:
I checked the time, and it was already correct; I also checked the Internet time synchronization:
Time to deal with disk partitioning (“Installation Destination”).
Since I’m testing this on a virtual machine, I’ll stick with the automatic partitioning.
And we can now start with the installation:
The “Writing objects” text stays there for a long time.
Then, the rest of the installation steps are performed, including the installation of apps:
Then, the progress bar basically goes directly to the end. The installation completed in a few minutes:
First boot
During the first boot, you configure a few things (most of them, taken from the installation process, but to be confirmed):
I’ll skip the GNOME tour.
The installed system
Concerning installed applications, it’s rather minimal:
You have a terminal (not the Gnome terminal, but “ptyxis) and Firefox:
Let’s see the layout of the partitions:
1
2
3
4
5
6
7
8
9
10
11
12
bettini@fedora:~$ sudo lsblk
NAME MAJ:MIN RM SIZE RO TYPE MOUNTPOINTS
sr0 11:0 1 1024M 0 rom
zram0 251:0 0 7.7G 0 disk [SWAP]
vda 253:0 0 80G 0 disk
├─vda1 253:1 0 600M 0 part /boot/efi
├─vda2 253:2 0 2G 0 part /boot
└─vda3 253:3 0 77.4G 0 part /var/home
/var
/sysroot/ostree/deploy/fedora/var
/sysroot
/etc
Shell
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
bettini@fedora:~$cat/etc/fstab
#
# /etc/fstab
# Created by anaconda on Wed Apr 8 16:52:13 2026
#
# Accessible filesystems, by reference, are maintained under '/dev/disk/'.
# See man pages fstab(5), findfs(8), mount(8) and/or blkid(8) for more info.
#
# After editing this file, run 'systemctl daemon-reload' to update systemd
If you write LaTeX in Neovim using theLazyVimdistribution, you already get a fantastic editing experience thanks to VimTeX and texlab. But there’s one thing that often trips people up:how do you quickly wrap selected text in\emph{…},\textbf{…}, or other LaTeX commands?
The answer ismini.surround— and with a small buffer-local configuration, it becomes a LaTeX wrapping powerhouse.
What mini.surround Gives You (Out of the Box)
LazyVim ships with themini.surroundextra, which you can enable in yourlazy.lua(or wherever you manage extras):
For example, visual-select a word and pressgsa"to wrap it in double quotes, orgsa)for parentheses. Great — but what about LaTeX-specific commands?
The Problem with LaTeX Commands
VimTeX gives you text objects, motions, completion, and much more — but it doesn’t ship a built-in “surround this selection with\emph{…}” feature. That’s wheremini.surround‘scustom surroundingscome in.
We can teachmini.surroundto understand LaTeX commands by defining custom surroundings in a filetype-specific Lua file.
Setting Up Custom LaTeX Surroundings
Create (or edit) the file~/.config/nvim/after/ftplugin/tex.lua. This file is automatically sourced by Neovim whenever you open a.texfile.
Why ftplugin?Files in this directory are loadedafterall plugin configuration, and only for the matching filetype. This means our settings are buffer-local and don’t interfere with any other filetype.
How It Works
Thecmd_surroundhelper function does two things:
input: A Lua pattern that matches\cmd{...}so thatgsdandgsrknow what tofind and remove.
output: The left (\cmd{) and right (}) strings used whenaddinga surrounding.
We then assign short, memorable single-character IDs to each command.
Using the Surroundings
Here’s what you can do in any.texbuffer:
Adding a Surrounding
Visual-select some text, then:
Keymap
Result
gsae
\emph{selected text}
gsab
\textbf{selected text}
gsai
\textit{selected text}
gsat
\texttt{selected text}
gsau
\underline{selected text}
gsas
\textsc{selected text}
gsaq
(add opening and closing LaTeX quotations, i.e., two backticks and ”)
You can also usegsain normal mode with a motion:gsaeiwwraps the current word in\emph{…}.
You visual-select “very important” and pressgsab. You get:
TeX
1
Thisis\textbf{veryimportant}information.
Now you decide that emphasis is better. With the cursor inside the\textbf{…}, pressgsrbe:
TeX
1
Thisis\emph{veryimportant}information.
And if you want to remove the markup entirely:gsde:
TeX
1
Thisisveryimportantinformation.
Extending with Your Own Commands
The pattern is easy to extend. Just add more entries tocfg.custom_surroundings:
Lua
1
2
3
4
5
6
7
8
-- enquote (csquotes package)
cfg.custom_surroundings.Q=cmd_surround("enquote")
-- colored text
cfg.custom_surroundings.r={
input={"\\textcolor{[^}]*}{().-()}"},
output={left="\\textcolor{red}{",right="}"},
}
Pick single characters that are easy to remember and don’t conflict with built-in mini.surround ids (avoid(,),[,],{,},',",`).
A Note on Limitations
Theinputpatterns use Lua’s pattern matching, whichcannot handle nested braces. For example,\emph{foo {bar} baz}may not be matched correctly bygsdorgsr. For the vast majority of LaTeX writing, this is not an issue — but it’s worth keeping in mind if you work heavily with nested commands.
If you use aWaylandcompositor likeSwayorHyprland,makois a great lightweight notification daemon. Many distros make it “start automatically” via asystemd user service, so you don’t need to addexec makoto your compositor config.
I’m experimenting with a setup with KDE, Sway, and Hyprland installed on the same machine and used by the same user, and there’s a catch:KDEon Wayland is also a Wayland session, so the same auto-start logic can kick in there too — and you end up with mako running in Plasma when you don’t want it.
This post shows a clean fix:keep mako auto-starting in Sway/Hyprland, but skip it in KDE, using asystemd drop-in overridethat lives nicely in your dotfiles (e.g., with chezmoi).
Why mako starts in KDE
On many systems, the provided user unit checks only whether you’re ina Wayland session:
1
2
ExecCondition=/bin/sh-c[-n"$WAYLAND_DISPLAY"]
KDE Wayland setsWAYLAND_DISPLAYtoo, so mako passes the check and runs.
The fix: restrict the systemd unit to Sway/Hyprland
On another machine, once mako is installed, that drop-in will be picked up automatically. The only thing to remember is thatsystemd reads unit changes after a reload(or next login), so if you want it to take effect immediately afterchezmoi apply, run:
1
2
3
systemctl--userdaemon-reload
systemctl--usertry-restartmako.service
(try-restartis nice because it won’t error if mako isn’t running.)
Bonus note: D-Bus activation
Depending on your distro and setup, mako can also be started via D-Bus when a request for notifications is made. If you find mako still appears in KDE even when the unit is skipped, check whether it’s being D-Bus activated — and then either: – rely on a KDE-native notification daemon in Plasma, or – mask the D-Bus service fororg.freedesktop.Notificationsfor KDE sessions only.
If you useKDEandSway(orHyprland) on the same machine with the same user (something I’m experimenting with), when you launch Chrome and log in with your user in KDE, and then switch to Sway, you’ll see that your account is marked as “Paused”: you have to log in again. The same holds the other way round.
That’s because in KDE, Chrome stores the credentials in KWallet, while Sway does not.
To fix this annoying problem, you have to ensure to run Chrome in Sway with the option “–password-store=kwallet6”.
To do that, you can either manually launch Chrome with that option or create the file “~/.local/share/applications/google-chrome.desktop” starting from the default file (in Arch it’s “/usr/share/applications/google-chrome.desktop”) and ensure the occurrences of the “Exec” line have that option, i.e.,
The desktop file in your home folder will have precedence over the default one.
However, while KDE automatically unlocks the KWallet when you log in, Sway does not. The first time you launch Chrome from a Sway session, you’re asked to open the wallet with your login password:
To let KWallet use your login credentials automatically (as KDE does, thanks to “/etc/xdg/autostart/pam_kwallet_init.desktop”), you need to tell Sway to start the corresponding PAM module.
That’s usually enough to avoid the post-login password prompt,provided PAM is already set up correctly(see the next section).
Important:pam_kwallet_initonly works if PAM captured your password
pam_kwallet_initdoesnotmagically know your login password. It relies on the PAM module (pam_kwallet5.so) having captured it during login and made it available for the session handoff.
So:
If you start Sway via a display manager/session that already haspam_kwallet5.soin its PAM stack, then running/usr/lib/pam_kwallet_initIn Sway, the wallet should unlock automatically.
If you start Sway via a path thatdoesn’t run the kwallet PAM module (common when starting from TTY, or via some greeters, depending on config), thenpam_kwallet_initwon’t have credentials to use, and you’ll still be prompted.
I’ll show how I installed Linux (EndeavourOS, i.e., Arch) on a Dell Pro Max Tower T2.
This is quite a powerful computer! Here are a few screenshots taken from Windows 11:
Before installing Linux on this computer, I had to change the SSD SATA mode from RAID to AHCI, as documented in aprevious blog post. Otherwise, Linux will not detect any SSD.
Prepare the disk with “Disk Management”.
Current situation:
I will not wipe the whole disk because I want to use Windows as well. I won’t touch the other recovery and health partitions either.
Right-click on “C:” and choose “Shrink Volume…”. About 200Gb should be enough for Windows on this computer. Unfortunately, the UI of this dialog is not the best one: you have to compute how much space to remove from the current partition and check whether the “Total size after shrink” is what you want.
I’m also deleting the “D:” volume (I’ll use it for additional partitions both on Linux and maybe on Windows).
Here’s the final result:
Let’s reboot the computer and turn off secure boot. Press F2 when the computer is turning on to enter the BIOS.
Very nice looking:
NOTE: You can use the mouse to navigate the BIOS. In my case, the computer is connected to a KVM switch for keyboard and mouse. When in the BIOS, the mouse just moves vertically. I had to plug the mouse directly into the USB port of the computer to use it inside the BIOS.
Select “Boot Configuration” where you see the “Boot Sequence” (that’s useful in the future to change the boot order or delete old entries). Scroll down til you get to secure boot and disable it:
Let’s apply changes and exit.
I downloaded the EndeavourOS ISO Mercury Neo 2025.03.19, put it into a Ventoy USB stick.
It looks like this PC can boot from USB only from the first port from the bottom (at least in the front: I haven’t tried the ports on the back):
When the computer starts, press F12 for the temporary boot menu. Select the USB stick. Then you get the Ventoy menu where you select the EndeavourOS distribution. I’ll use grub2 mode.
After several weeks, I can confirm that Linux works like a charm on this powerful computer! 🙂
We use cookies on our website to give you the most relevant experience by remembering your preferences and repeat visits. By clicking “Accept All”, you consent to the use of ALL the cookies. However, you may visit "Cookie Settings" to provide a controlled consent.
This website uses cookies to improve your experience while you navigate through the website. Out of these, the cookies that are categorized as necessary are stored on your browser as they are essential for the working of basic functionalities of the website. We also use third-party cookies that help us analyze and understand how you use this website. These cookies will be stored in your browser only with your consent. You also have the option to opt-out of these cookies. But opting out of some of these cookies may affect your browsing experience.
Necessary cookies are absolutely essential for the website to function properly. These cookies ensure basic functionalities and security features of the website, anonymously.
Cookie
Duration
Description
cookielawinfo-checkbox-analytics
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Analytics".
cookielawinfo-checkbox-functional
11 months
The cookie is set by GDPR cookie consent to record the user consent for the cookies in the category "Functional".
cookielawinfo-checkbox-necessary
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookies is used to store the user consent for the cookies in the category "Necessary".
cookielawinfo-checkbox-others
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Other.
cookielawinfo-checkbox-performance
11 months
This cookie is set by GDPR Cookie Consent plugin. The cookie is used to store the user consent for the cookies in the category "Performance".
viewed_cookie_policy
11 months
The cookie is set by the GDPR Cookie Consent plugin and is used to store whether or not user has consented to the use of cookies. It does not store any personal data.
Functional cookies help to perform certain functionalities like sharing the content of the website on social media platforms, collect feedbacks, and other third-party features.
Performance cookies are used to understand and analyze the key performance indexes of the website which helps in delivering a better user experience for the visitors.
Analytical cookies are used to understand how visitors interact with the website. These cookies help provide information on metrics the number of visitors, bounce rate, traffic source, etc.
Advertisement cookies are used to provide visitors with relevant ads and marketing campaigns. These cookies track visitors across websites and collect information to provide customized ads.