Conversation
Edited 5 months ago
kas complains about the Linux command line
Show content

the Linux command line really needs a way to proactively warn the user that something is wrong, or something is about to go wrong

instead of suddenly getting I/O errors because the disk is full, or wondering why your service is down (because it crashed), you could get a little red (1) or (2) in your terminal prompt and type notifs to get a warning that “your disk usage is at 90%” or “systemd had to restart this service and here is the error log” or even just “this cron job ran and exited with code 12 and here’s the terminal output”

it also needs some equivalent of tray icons. typing ps aux will deluge you with a fuckton of random system services that I’ve never heard of before, and somewhere buried under all that are the services that I’m interested in. I’d really like a way to ask Linux “hey what non-system-critical software is running right now?”

it also needs a way to ask “hey what non-system-critical software is currently installed?” and “what user-facing software is installed?” so that you can figure out what you installed on that system without getting deluged with a list of ten million C libraries

basically I just think that the Linux command line needs better ways to understand what the state of the system is, once it gets more complex than a Unix mainframe was in the 1980’s. at the moment it feels like you have to proactively check for problems and gotchas before they happen, and that’s just unworkable

5
0
3
re: kas complains about the Linux command line
Show content

@kasdeya so if you have more bandwidth for learning . . . consider looking at custom shell prompts

1
0
1
kas complains about the Linux command line
Show content

@kasdeya how is this not a gui

0
0
0
re: kas complains about the Linux command line
Show content

@kasdeya for your second point, you could filter by processes running as the unprivledged user and then maybe manually filter a few, like your window manager. i usually find htop tree view is sufficient though

for the third point, most package managers have a "list only explicitly installed packages" option which is helpful. you can also look in your applications folder with the .desktop files to see what user-facing apps you have installed, but that'll be mostly gui stuff

the first point i think is a really good idea actually, and probably achievable just by hooking cron and systemd into some sort of notification service, then create a front-end in the prompt

0
0
0
re: kas complains about the Linux command line
Show content

@tempest hm - that’s a good point. I’ve experimented a small bit with adding git info to my shell prompt on Windows and I assume it works similarly on Linux. it might be possible for me to add info about the status of services and other things like that to my prompt

0
0
0
re: kas complains about the Linux command line
Show content

@kasdeya “what user-facing software is installed?”: dpkg -l | grep -v '\slib will get you non-library packages installed, which isn’t quite as good but is at least a start

top can show running processes and organize them by CPU utilization or memory consumption.

for running out of disk space, pre-emptive notifications could be done by having it print out a ‘df’ command in the prompt string, but that’s probably clutter most of the time. Since I am always running low on disk space I just sort of regularly run df to figure out how much space I have left.

0
0
0
re: kas complains about the Linux command line
Show content
@kasdeya Oh also, i have some shell functions set up so that I can tell what my current directory is in various xterm windows, and also to tell if I'm currently SSH'ed into another of my machines or not. In bash, it runs in `$PROMPT_COMMAND` so that it gets proc'ed every time i get a new prompt line.

You could use something like that to put current disk utilization in the title bar of a terminal window if using an X session
1
0
0
re: kas complains about the Linux command line
Show content
@kasdeya here's an example of how mine's set up, it's saved me from accidentally rebooting a remote computer many times when just alt-tabbing into a terminal window to lazily run it. "wyatt-delltower" is the remote host name that I'm SSH'ed into.
0
0
0