EnvVars available in Cinnamon lock screen message? [solved]

Please post suggestions for improvement of Cinnamon on:
https://github.com/linuxmint/Cinnamon
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
lazarus

EnvVars available in Cinnamon lock screen message? [solved]

Post by lazarus »

LM18.3 Cinnamon x64

In another lifetime (early RedHat days, I think. Maybe Minix, probably not) I could customise the LogIn screen's welcome message using a variety of escape codes & EnvVars. (Just to clarify: I'm talking about a msg displayed statically on the LogIn screen, not the motd or welcome msg displayed once a user logged in!)

Things like %n for host name or %t for system time, etc., as well as a similar set for formatting. CR's, NL's etc. It may even have been more like $HOSTNAME or $TIME but I don't rightly remember... too long ago. :oops:

So although it couldn't display a pretty backdrop or a real-time clock it could be set up to display more or less what we use Conky to do now, except on the LogIn screen. (From vague memory, rather than a text string I was redirecting from a file, but that's beside the point.)

Anyways... is it still possible to do this sort of jiggery-pokery on the LogIn and/or Lock Screen? If so, could someone point me at a list of what esc codes are available?

Ummm... come to that, where does Menu>Administration>LogIn Window (cinnamon) actually save the welcome text? It's not where I would expect, /etc/issue, nor in the /etc/lightdm dir tree.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
smurphos
Level 18
Level 18
Posts: 8498
Joined: Fri Sep 05, 2014 12:18 am
Location: Irish Brit in Portugal
Contact:

Re: EnvVars available in Cinnamon lock screen message?

Post by smurphos »

:?: I don't have any option to set a message in Login-Window (18.3 and 19 with default slick-greeter / lightDM combo).

The slick-greeter settings where different from default are in /etc/lightdm/slick-greeter.conf

The old MDM login screen (default prior to 18.2, may still be installed in 18.3 if it's an upgraded system) does have options for welcome messages... /etc/mdm/mdm.conf is were the settings are stored. It accepts environment variables.

The lock screen message you can set programmatically - e.g. I populate mine with fortunes via a script. Not sure if it accepts environment variables.

Code: Select all

MESSAGE=$(fortune -asn80)
gsettings set org.cinnamon.desktop.screensaver default-message "$MESSAGE"
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.
lazarus

Re: EnvVars available in Cinnamon lock screen message?

Post by lazarus »

smurphos wrote: Wed Aug 08, 2018 2:27 am :?: I don't have any option to set a message in Login-Window (18.3 and 19 with default slick-greeter / lightDM combo).
You're quite right. That's where the Login-Window backdrop image is set - which does display correctly - not the message.

My bad... it has been one of those weeks where I can't open mouth without inserting foot.
The old MDM login screen (default prior to 18.2, may still be installed in 18.3 if it's an upgraded system) does have options for welcome messages... /etc/mdm/mdm.conf is were the settings are stored. It accepts environment variables.
Yeah. I think that's where I was confusing myself. I was running LM18.1 & mdm, I did a fresh install of LM18.3 & lightdm.

It's almost funny; I have no problems with the core of the OS, but when it comes to the desktops & GUI? :x Considering the differences between distros and my... outdated knowledge, I'm beginning to feel like the old mechanic who could repair most cars from an old WW2 jeep through to a modern Lambourghini but can lose hours just finding where they put the @#%#$% start button on this thing!
The lock screen message you can set programmatically - e.g. I populate mine with fortunes via a script. Not sure if it accepts environment variables.

Code: Select all

MESSAGE=$(fortune -asn80)
gsettings set org.cinnamon.desktop.screensaver default-message "$MESSAGE"
Nice! That could be made to work. I'd like a simple listing of # of users currently logged, important error flags, etc., so a glance at a vacant terminal will tell me whether I need to log in. That should be relatively straight-forward message to generate in lieu of a fortune and could probably be incorporated with those lock screen scripts you came up with, so the msg only displays when no-one is logged in.

Thanks again, Smurphos. You've certainly made my day. Again. ;)
Locked

Return to “Cinnamon”