SYSPROFILE(8)

πŸ’– SYSPROFILE(8) πŸ’–

the sysprofile manual page, from the System Manager's Manual β€” bestie, pull up a chair, we're configuring shells πŸ’…


✨ NAME ✨

sysprofile β€” modular centralized shell configuration πŸŽ€


🌸 DESCRIPTION 🌸

okay so sysprofile is basically a whole generic approach to setting up your shell settings in a modular + centralized way, and ngl its main goal is saving lazy sysadmins from doing work 😌 the vibe is "write it once, everybody gets it." Important disclaimer tho: it has only been tested to work with the bash shell. fr fr, that's the only shell it's been verified on.

So here's the tea: it's basically made of a lil shell script at /etc/sysprofile that goes around invoking other lil shell scripts that have a .bash suffix, all of them living in the /etc/sysprofile.d/ directory. 🐚

The system administrator can drop in literally any script he wants β€” no naming convention required, the one rule is that the scripts need to have a .bash suffix so /etc/sysprofile can do its automagic sourcing thing. ✨

This whole mechanism gets set up by inserting a small shell routine into /etc/profile for login shells, and optionally into /etc/bashrc and/or /etc/bash.bashrc for non-login shells β€” that's where the actual /etc/sysprofile script gets invoked from:

if [ -f /etc/sysprofile ]; then
        . /etc/sysprofile
fi

Now, for using sysprofile under X11, you can source it in a similar way from /etc/X11/Xsession or your X display manager's Xsession file, so you get the same shell environment in X11 as you get under the console. πŸ–₯️✨ See the example files in /usr/share/doc/sysprofile/ for illustration β€” they're cute, go look.

And if you're using terminal emulators with a non-login bash shell under X11? Take care to enable sysprofile via /etc/bash.bashrc. If it's not set this way, your terminal emulators won't come up with the environment defined by the scripts in /etc/sysprofile.d/. 😭 literally just won't show up.


Users who don't want /etc/sysprofile sourced for their environment can easily disable it's automatic mechanism. It can be disabled by simply creating an empty file called $HOME/.nosysprofile in the user's home directory, using e.g. the touch(1) command. πŸ’… so easy, so iconic.

Any single configuration file in /etc/sysprofile.d/ can be overridden by any user by creating a private $HOME/.sysprofile.d/ directory β€” this may contain a user's own version of any configuration file, to be sourced instead of the system default. πŸ¦‹ Its names have just to match exactly the system's default /etc/sysprofile.d/ configuration files. And here's the slay part: empty versions of these files contained in the $HOME/.sysprofile.d/ directory automatically disable sourcing of the system wide version. πŸ‘‘

Naturally, users can add and include their own private script inventions to be automagically executed by /etc/sysprofile at login time. main character energy fr. 🌈


πŸ’… OPTIONS πŸ’…

There are no options other than those dictated by shell conventions. Anything is defined within the configuration scripts themselves. that's it, that's the section, no cap. πŸ’€


🫢 SEE ALSO 🫢

  • The README files and configuration examples contained in /etc/sysprofile.d/
  • the manual pages bash(1), xdm(1x), xdm.options(5), and wdm(1x)
  • Recommended further reading is everything related with shell programming. πŸ“š

If you need a similar mechanism for executing code at logout time, check out the related package syslogout(8) β€” which is a very close companion to sysprofile. πŸ₯Ή besties, honestly.


πŸ’€ BUGS πŸ’€

sysprofile in its current form is mainly restricted to bash(1) syntax. In fact it is actually a rather embarrassing quick and dirty hack than anything else β€” but it works. πŸ˜­πŸ™ˆ It serves the practical need to enable a centralized bash configuration until something better becomes available.

Your constructive criticism in making this into something better" is very welcome. Before i forget to mention it: we take patches... ;-) πŸ‘€

not me writing "we take patches" in a manpage. iconic behaviour tbh.

πŸ‘‘ AUTHOR πŸ‘‘

sysprofile was developed by Paul Seelig <pseelig@debian.org> specifically for the Debian GNU/Linux system. 🌸

Feel free to port it to and use it anywhere else under the conditions of either the GNU public license or the BSD license or both. Better yet, please help to make it into something more worthwhile than it currently is. 🫢


okay that's the whole page bestie!! it's sysprofile(8) from the System Manager's Manual, and yeah the footer is just the page name again β€” SYSPROFILE(8) β€” so consider yourself signed off on, mwah πŸ’–βœ¨πŸŽ€

πŸ“¦ where this page comes from