Silver init doesn't recognize login shells [stable-20.10 ARM edition]

I’m using stable-20.10, ARM, Sway Edition. I noticed that when I log in as a normal user on a text console, the silver utility crashes with an error message to the effect of

thread 'main' panicked at 'unknown $SILVER_SHELL: "-bash". Supported shells...

This is because silver does not recognize the extremely old Unix convention of setting the first character of a shell’s $0 to - to indicate a login shell. It will also be a problem for remote logins over ssh.

I reported this as a bug to silver upstream: However, I would like to suggest the following workaround in /etc/skel/.bashrc:

-export SILVER_SHELL=$0 # bash, zsh, or fish
+export SILVER_SHELL=${0#-} # bash, zsh, or fish

which strips the problem dash off before silver can see it.

(Is this the right place to report bugs? I have several more and I’ve not been able to find any official bug tracker or guidelines for how to report bugs.)

Hey looks like you have posted in the wrong section.

@appelgriebsch is the maintainer for sway arm edition.

He will be able to help you with your query.

Moving thread to ARM section.

Thanks for the feedback. Will try to incorporate the changes for the upcoming 20.12 release cycle.

Gitlab repo got updated: [sway] small fix for silver init, additional cli packages (37826bb5) · Commits · manjaro-arm / applications / arm-profiles · GitLab.

Change will go into new Sway image release.

1 Like