lchsh(1)

✨ NAME ✨

lchsh β€” change your login shell, bestie πŸ’…

It's like chsh but with an l in front, and it's from the libuser squad. Welcome to the lchsh(1) page, general commands manual edition πŸŽ€


🌸 SYNOPSIS 🌸

lchsh [OPTION]... [user]

That's it. Options, then maybe a user. Simple. Iconic. πŸ¦‹


πŸ’– DESCRIPTION πŸ’–

Okay so here's the tea: lchsh displays the login shell of a user and lets you change it. That's the whole vibe. Shell glow-up service, no cap. ✨

Now, the user argument β€” if you don't hand it over, it just uses the username of whoever's running the command. The invoking user. That's you, babe. 🫢

But listen β€” the user argument is straight-up ignored if lchsh is run set-uid to a different user. So don't think you're being sneaky. The program knows. πŸ‘€

And here's a lil detail that trips people up: at the "New Shell" prompt, if you just press Enter and give it an empty string? That's not "cancel", that's not "error", that's accepting the current value. You're saying "yeah, keep it, it's cute". πŸ’š


πŸ‘‘ OPTIONS πŸ‘‘

  • -i, --interactive β€” makes it ask all the questions when it's connecting to the user database, even if libuser's config already has default answers set up. Like, yes, I want to be asked, thank you. Main character energy. πŸ™ˆ

⭐ EXIT STATUS ⭐

  • 0 β€” success, we ate, everything's fine πŸ’–
  • 1 β€” error, we did not eat 😭

That's the whole scale. Binary. No in-between. Periodt.


πŸ’€ BUGS πŸ’€

lchsh ignores /etc/shells.

Yep. Fr fr. It just does not care. If you were expecting it to check whether your shiny new shell is actually a legit listed shell before letting you set it β€” nope! It's giving "no thoughts, head empty". So be careful out there, bestie. πŸ“


This page comes to you from the libuser crew, dated Sep 20 2004 β€” yes, a vintage icon, still serving looks. 🧚 Stay slay, change those shells responsibly, and remember: empty string means keep the current one. Byeeee πŸ’œπŸŒˆ