From 4db7d49d531aa5282f77f5ae10ac10a5a765cdfd Mon Sep 17 00:00:00 2001 From: Aster Boese Date: Sat, 20 Jun 2026 17:58:31 +0200 Subject: [PATCH] treewide: stop calling or recommending doas With the switch to sudo-rs, v26.06 and edge installs do not have doas by default. Along with this, we installed doas on old installs with doas-sudo-shim, so the call to sudo also works there. Therefore, recommending and calling sudo is the correct option here. Signed-off-by: Aster Boese Part-of: --- .../testing/device-apple-mac-aarch64/APKBUILD | 4 +-- .../os-installer-deploy.sh | 26 +++++++++---------- .../kernel-packages/kernel-cmdline.md | 2 +- main/postmarketos-base/APKBUILD | 2 +- .../postmarketos-base.post-upgrade | 4 +-- 5 files changed, 19 insertions(+), 19 deletions(-) diff --git a/device/testing/device-apple-mac-aarch64/APKBUILD b/device/testing/device-apple-mac-aarch64/APKBUILD index fcaf10dd1..9d434060c 100644 --- a/device/testing/device-apple-mac-aarch64/APKBUILD +++ b/device/testing/device-apple-mac-aarch64/APKBUILD @@ -2,7 +2,7 @@ maintainer="Clayton Craft " pkgname=device-apple-mac-aarch64 pkgdesc="Apple M-series Macs" -pkgver=8 +pkgver=9 pkgrel=0 url="https://postmarketos.org" license="MIT" @@ -82,5 +82,5 @@ sha512sums=" f111ddc0484f079af23520dcc9b4d909b55da327aec91545921a4ceafc52b21d88f37fbdb702e51ca1e49440b6afc2011ada8b681c1801f572bddc9cd34c9d9e initramfs_copy_vendorfw.sh 11d5d6af50ed73e7e6940f7d56730f94a1bb42990d5dba9a798522060e7717c410c025b12def0345b4f43c97da268dabcb484c3004d23c1ac39b1eeaaefd2967 initramfs_setup_vendorfw.sh da0da9f07bb6f05d2275fc58c1ef0e3c3895def53dbc8247e73806b6e9ab88f005efae01f9fb8f5f8c7bdcc5f4d734900c634d804ea0f154f511ca0ef7f4c9a1 modules-initfs -7b9a75b2d471be7eef06d4f4b6bff64a2164fd23332311388e1a1962a63b18dfed4d2252a910302313f556c84030ef92cdca4f853f9076874776db070b1c09cc os-installer-deploy.sh +a34b81824d0aa402562d2e578dbe4963486152dbdbaa0cd88df6895f4f2ce7552c619e9fd598d9dfb13401a8abc753ad6643b4118ba70eac1c90854fc3bcf447 os-installer-deploy.sh " diff --git a/device/testing/device-apple-mac-aarch64/os-installer-deploy.sh b/device/testing/device-apple-mac-aarch64/os-installer-deploy.sh index ae8fc27e7..a014b61cd 100644 --- a/device/testing/device-apple-mac-aarch64/os-installer-deploy.sh +++ b/device/testing/device-apple-mac-aarch64/os-installer-deploy.sh @@ -29,22 +29,22 @@ fi cleanup() { # Unmount ESP and image ESP if mounted if mountpoint -q /mnt/esp 2>/dev/null; then - doas umount /mnt/esp + sudo umount /mnt/esp fi if mountpoint -q /mnt/image-esp 2>/dev/null; then - doas umount /mnt/image-esp + sudo umount /mnt/image-esp fi # Detach loop device if [ -n "$LOOP_DEV" ] && [ -e "$LOOP_DEV" ]; then - doas losetup -d "$LOOP_DEV" + sudo losetup -d "$LOOP_DEV" fi } trap cleanup EXIT INT TERM # Set up loop device to access image partitions -LOOP_DEV=$(doas losetup --find --show --partscan "$IMAGE_PATH") +LOOP_DEV=$(sudo losetup --find --show --partscan "$IMAGE_PATH") # TODO: Don't hardcode partition layout assumptions # Currently assuming: p1=ESP/boot, p2=root partition @@ -55,7 +55,7 @@ IMG_ROOT_PART="${LOOP_DEV}p2" # set the ESP's filesystem UUID to the UUID of the image's ESP. This saves us # from having to mount (and optionally decrypt) the image's rootfs to change # fstab... -IMG_ESP_UUID=$(doas blkid -s UUID -o value "$IMG_ESP_PART") +IMG_ESP_UUID=$(sudo blkid -s UUID -o value "$IMG_ESP_PART") if [ -z "$IMG_ESP_UUID" ]; then echo "ERROR: Could not get ESP UUID from image!" exit 1 @@ -64,12 +64,12 @@ fi # Convert FAT32 UUID format (1234-5678) to 8-digit hex vol. ID (12345678) IMG_ESP_VOL_ID=$(echo "$IMG_ESP_UUID" | tr -d '-') echo "Setting target ESP serial to match image: $IMG_ESP_VOL_ID" -doas fatlabel -i "$ESP_PART_DEV" "$IMG_ESP_VOL_ID" +sudo fatlabel -i "$ESP_PART_DEV" "$IMG_ESP_VOL_ID" # Generate repart config and use CopyBlocks for block-level copy, which should # preserve filesystem UUID, and (optional) luks -doas mkdir -p /run/repart.d -doas tee /run/repart.d/70-pmos-root.conf > /dev/null < /dev/null < maintainer="Clayton Craft " pkgname=postmarketos-base -pkgver=63 +pkgver=64 pkgrel=0 pkgdesc="Meta package for minimal postmarketOS base" url="https://postmarketos.org" diff --git a/main/postmarketos-base/postmarketos-base.post-upgrade b/main/postmarketos-base/postmarketos-base.post-upgrade index 98e2ea6eb..cadd39ae3 100644 --- a/main/postmarketos-base/postmarketos-base.post-upgrade +++ b/main/postmarketos-base/postmarketos-base.post-upgrade @@ -21,8 +21,8 @@ if [ -d /bin -a ! -L /bin ] || \ echo "* ERROR: The /usr merge was not attempted due to filesystem" echo "* conflicts. Your installation might have deviated from stock in" echo "* unsupported ways. If you can resolve the conflicts yourself," - echo "* you can try running 'doas merge-usr --dryrun', and if there are" - echo "* no more conflicts, 'doas merge-usr'. Otherwise, feel free to" + echo "* you can try running 'sudo merge-usr --dryrun', and if there are" + echo "* no more conflicts, 'sudo merge-usr'. Otherwise, feel free to" echo "* ask for help commenting in" echo "* https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6389" exit 1