Hi Shlomi,

Thank you for taking the time to look at my script and for sharing the link 
about printf vs echo. I really appreciate the suggestion!

After reviewing the link you shared, I double-checked my script. In KDE's 
configuration, NumLock=0 actually means NumLock is enabled ― this is the 
convention used by KDE/Plasma for this setting.

For context, I've tested this script on Fedora, Arch, and CachyOS, all under 
Wayland sessions with Plasma 6.

Regarding the use of echo in this script: since it's a simple one-time setup 
tool that only writes a few lines to a config file and prints basic progress 
messages, I think using echo here is acceptable for this case. The script uses 
set -e to catch errors, and the tee/bash -c operations handle file writes 
safely.

That said, I do appreciate the suggestion and will keep printf in mind for 
future scripts that need more robust output handling. If you have any other 
feedback or ideas for improvement, I'd be very glad to hear them!

Thanks again for your time.

Best regards,
lian hua
________________________________
发件人: Shlomi Fish <[email protected]>
发送时间: 2026年8月29日 11:47
收件人: lian hua <[email protected]>
抄送: [email protected] <[email protected]>
主题: Re: [kde-community] Auto-enable NumLock for Plasma Login Manager

On Fri, 28 Aug 2026 14:53:11 +0000
lian hua <[email protected]> wrote:

> Hello KDE Community,
>
> I'd like to introduce a small project I've been working on called plm-numlock.
>
> The Plasma Login Manager (PLM) doesn’t automatically turn on the NumLock key
> on the login screen by default. Even after I tried changing the config files
> following the official Arch wiki docs, it didn’t work. This script can fix
> the problem and turn on NumLock automatically, so users don’t have to press
> the key manually every time they log in.
>
> I've already tested this project on Fedora, Arch, and CachyOS. You can find
> it on GitHub:https://github.com/bailuocf/plm-numlock.
>
> The README is available in both English and Simplified Chinese.
>
> I would really appreciate any feedback, suggestions, or testing from the
> community. In particular, I look forward to hearing from KDE Plasma
> developers �C if this tool proves useful, I'd be interested in discussing
> whether it could be considered for inclusion in future Plasma releases.
>
> Please feel free to reply directly to this email or open an issue on GitHub.
> Thank you for your time and consideration.

hi lian,

thanks.

see
https://unix.stackexchange.com/questions/58310/difference-between-printf-and-echo-in-bash

--

Shlomi Fish       https://www.shlomifish.org/
Star Trek: “We, the Living Dead” - https://shlom.in/st-wtld

*Harry*: Yes, it is obvious that this pig is the most beautiful person for
miles.
*Miss Piggy*: Indeed. Candice Swanepoel ain’t got nothing on… Moi!
    ― https://is.gd/zsmond

Please reply to list if it's a mailing list post - https://shlom.in/reply .

Reply via email to