From ffc955d58e838420f79896a6cf37272eb22dd93b Mon Sep 17 00:00:00 2001 From: Aaron Rainbolt Date: Thu, 21 Mar 2024 16:26:13 -0500 Subject: [PATCH] Fix LUKS passphrase prompt for non-US keyboard layouts, undo an accidental change to Kubuntu --- common/fixconkeys-part1 | 3 +++ common/fixconkeys-part2 | 5 +++++ .../modules/shellprocess_fixconkeys_part1.conf | 5 +++++ .../modules/shellprocess_fixconkeys_part2.conf | 5 +++++ debian/changelog | 8 ++++++++ debian/rules | 3 +++ kubuntu/settings.conf | 17 ++++++++--------- lubuntu/settings.conf | 8 ++++++++ ubuntuunity/settings.conf | 8 ++++++++ 9 files changed, 53 insertions(+), 9 deletions(-) create mode 100755 common/fixconkeys-part1 create mode 100755 common/fixconkeys-part2 create mode 100644 common/modules/shellprocess_fixconkeys_part1.conf create mode 100644 common/modules/shellprocess_fixconkeys_part2.conf diff --git a/common/fixconkeys-part1 b/common/fixconkeys-part1 new file mode 100755 index 0000000..283a10e --- /dev/null +++ b/common/fixconkeys-part1 @@ -0,0 +1,3 @@ +#!/bin/bash +setxkbmap -query | awk '/layout/{ print $2 }' > /dev/shm/fixconkeys-layout +cp /usr/libexec/fixconkeys-part2 ${1}/usr/libexec/fixconkeys-part2 diff --git a/common/fixconkeys-part2 b/common/fixconkeys-part2 new file mode 100755 index 0000000..6fca6fe --- /dev/null +++ b/common/fixconkeys-part2 @@ -0,0 +1,5 @@ +#!/bin/bash +loadkeys "$(cat /dev/shm/fixconkeys-layout)" +setupcon --save-only +update-initramfs -c -k all +rm /usr/libexec/fixconkeys-part2 diff --git a/common/modules/shellprocess_fixconkeys_part1.conf b/common/modules/shellprocess_fixconkeys_part1.conf new file mode 100644 index 0000000..9e6a293 --- /dev/null +++ b/common/modules/shellprocess_fixconkeys_part1.conf @@ -0,0 +1,5 @@ +--- +dontChroot: true +timeout: 30 +script: + - /usr/libexec/fixconkeys-part1 ${ROOT} diff --git a/common/modules/shellprocess_fixconkeys_part2.conf b/common/modules/shellprocess_fixconkeys_part2.conf new file mode 100644 index 0000000..5d3b3b1 --- /dev/null +++ b/common/modules/shellprocess_fixconkeys_part2.conf @@ -0,0 +1,5 @@ +--- +dontChroot: false +timeout: 30 +script: + - /usr/libexec/fixconkeys-part2 diff --git a/debian/changelog b/debian/changelog index 9daa76c..27b615a 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,11 @@ +calamares-settings-ubuntu (1:24.04.20) noble; urgency=medium + + * Fix LUKS passphrase unlocker for non-US keyboard layouts. + * Disable pkgselect module on Kubuntu, it's not ready for use and wasn't + intentionally enabled. + + -- Aaron Rainbolt Thu, 21 Mar 2024 13:32:53 -0500 + calamares-settings-ubuntu (1:24.04.19) noble; urgency=medium * Add Ubuntu Unity configuration. (LP: #2055799) diff --git a/debian/rules b/debian/rules index 6e7a079..0f09b7a 100755 --- a/debian/rules +++ b/debian/rules @@ -33,3 +33,6 @@ override_dh_missing: chmod 644 $(MODULES_DIR)/pkgselect/module.desc mkdir -pv debian/calamares-settings-ubuntu-common/usr/bin/ cp -v common/snap_install debian/calamares-settings-ubuntu-common/usr/bin/calamares_snap_install + mkdir -pv debian/calamares-settings-ubuntu-common/usr/libexec/ + cp -v common/fixconkeys-part1 debian/calamares-settings-ubuntu-common/usr/libexec/fixconkeys-part1 + cp -v common/fixconkeys-part2 debian/calamares-settings-ubuntu-common/usr/libexec/fixconkeys-part2 diff --git a/kubuntu/settings.conf b/kubuntu/settings.conf index c61b377..6058535 100644 --- a/kubuntu/settings.conf +++ b/kubuntu/settings.conf @@ -20,22 +20,21 @@ instances: - id: add386arch module: shellprocess config: shellprocess_add386arch.conf -- id: pkgselect_action - module: contextualprocess - config: pkgselect_context.conf -- id: pkgselect_snap_action - module: contextualprocess - config: pkgselect_snap_context.conf - id: oemprep module: shellprocess config: shellprocess_oemprep.conf +- id: fixconkeys_part1 + module: shellprocess + config: shellprocess_fixconkeys_part1.conf +- id: fixconkeys_part2 + module: shellprocess + config: shellprocess_fixconkeys_part2.conf sequence: - show: - welcome - locale - keyboard - - pkgselect - partition - users - summary @@ -63,9 +62,9 @@ sequence: - contextualprocess@after_bootloader - automirror - shellprocess@add386arch + - shellprocess@fixconkeys_part1 + - shellprocess@fixconkeys_part2 - packages - - contextualprocess@pkgselect_action - - contextualprocess@pkgselect_snap_action - shellprocess@logs - umount - show: diff --git a/lubuntu/settings.conf b/lubuntu/settings.conf index 6f88b56..1696bc6 100644 --- a/lubuntu/settings.conf +++ b/lubuntu/settings.conf @@ -29,6 +29,12 @@ instances: - id: oemprep module: shellprocess config: shellprocess_oemprep.conf +- id: fixconkeys_part1 + module: shellprocess + config: shellprocess_fixconkeys_part1.conf +- id: fixconkeys_part2 + module: shellprocess + config: shellprocess_fixconkeys_part2.conf sequence: - show: @@ -63,6 +69,8 @@ sequence: - contextualprocess@after_bootloader - automirror - shellprocess@add386arch + - shellprocess@fixconkeys_part1 + - shellprocess@fixconkeys_part2 - packages - contextualprocess@pkgselect_action - contextualprocess@pkgselect_snap_action diff --git a/ubuntuunity/settings.conf b/ubuntuunity/settings.conf index 2bc113c..5b63c2a 100644 --- a/ubuntuunity/settings.conf +++ b/ubuntuunity/settings.conf @@ -23,6 +23,12 @@ instances: - id: oemprep module: shellprocess config: shellprocess_oemprep.conf +- id: fixconkeys_part1 + module: shellprocess + config: shellprocess_fixconkeys_part1.conf +- id: fixconkeys_part2 + module: shellprocess + config: shellprocess_fixconkeys_part2.conf sequence: - show: @@ -56,6 +62,8 @@ sequence: - contextualprocess@after_bootloader - automirror - shellprocess@add386arch + - shellprocess@fixconkeys_part1 + - shellprocess@fixconkeys_part2 - packages - shellprocess@logs - umount