this post was submitted on 03 Jan 2025
373 points (97.9% liked)

Linux

48903 readers
968 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

Which Linux command or utility is simple, powerful, and surprisingly unknown to many people or used less often?

This could be a command or a piece of software or an application.

For example I'm surprised to find that many people are unaware of Caddy, a very simple web server that can make setting up a reverse proxy incredibly easy.

Another example is fzf. Many people overlook this, a fast command-line fuzzy finder. It’s versatile for searching files, directories, or even shell history with minimal effort.

you are viewing a single comment's thread
view the rest of the comments
[–] jaxiiruff@lemmy.zip 2 points 5 days ago (5 children)

Cant remember exactly but it had something to do with a file relating to sudo and it only was allowed to be edited with a vim style editor.

[–] johant@lemmy.ml 1 points 2 days ago

The EDITOR or VISUAL environment variables are usually read by command line tools to launch your preferred editor. You could set VISUAL to nano before launching visudo and you would be editing the sudoers file in nano.

[–] hersh@literature.cafe 8 points 5 days ago (1 children)

There's a separate command called visudo for this purpose.

You CAN use any ol' text editor but visudo has built-in validation specific to the sudoers file. This is helpful because sudoers syntax is unique and arcane, and errors are potentially quite harmful.

[–] freeman@sh.itjust.works 11 points 5 days ago

But visudo can use any editor if you set SUDO_EDITOR or EDITOR variables. If you don't want to use vi(m) you should probably set EDITOR in your .bashrc and visudo and probably other programs will use your editor of choice.

[–] JPAKx4@lemmy.blahaj.zone 2 points 5 days ago

There may be certain times where it's all that's available, I think I remember having to edit fstab in some recovery state in vi

[–] Jumuta@sh.itjust.works 1 points 5 days ago

/etc/sudoers?

you can just edit that with nano or whatever, the visudo thing they tell you to use is goofy and I don't like it