Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »
Q&A

General Q&A about Linux and Unix-like operating systems

Filters (None)
75%
+4 −0
How to run a command on a list of files?

Suppose I have a list of files on standard input. These may be the output of find, cat filelist.txt or something else. How can I run a command on each file in turn?

5 answers  ·  posted 11mo ago by matthewsnyder‭  ·  last activity 30d ago by trueframe‭

75%
+4 −0
VISUAL=gvim makes crontab -e open a new crontab instead of a current one

My VISUAL setup interferes with my cron jobs. crontab -l works all right, I see my previous jobs. crontab -e, crontab -e -u user-here - opens GVIM on an empty file checked cron.allow or .deny,...

1 answer  ·  posted 6mo ago by LAFK‭  ·  last activity 6mo ago by Quasímodo‭

66%
+2 −0
How to change the default app for opening directories in Gnome?

I somehow managed to unknowingly change the default app for opening directories on my laptop. E.g. when I use the option open containing folder in a program like Evince, my editor (vscode) opens u...

2 answers  ·  posted 9mo ago by mr Tsjolder‭  ·  last activity 9mo ago by matthewsnyder‭

71%
+3 −0
How to persist keyboard repeat rate and delay for external devices

Problem I want to set a global keyboard rate for both the X session and the console that persists for external keyboards, across plug-ins and removals. To my understanding, Xorg and console sett...

0 answers  ·  posted 1y ago by mcp‭  ·  edited 1y ago by Quasímodo‭

66%
+2 −0
How do I set up my own DNS on my LAN, with delegation of public domains?

I want to have a local DNS server on my home LAN, say at 192.168.1.123. All of my machines will use 192.168.1.123 as their only DNS server when connected to my home network. By default, my DNS ser...

1 answer  ·  posted 10mo ago by matthewsnyder‭  ·  last activity 9mo ago by Canina‭

dns
71%
+3 −0
How can I show hidden files and folders (with leading dot in name) on the desktop (actual desktop, not a window)?

I am using Linux Mint 20.3, with Cinnamon as a window manager. I have a folder named .pytest_cache on my Desktop: $ ls -1A | grep '^\.' .pytest_cache I know that if I open a Nemo window, navi...

0 answers  ·  posted 9mo ago by Karl Knechtel‭  ·  last activity 9mo ago by Mithical‭

60%
+1 −0
How to tile multiple small page PDFs on a single standard size PDF?

Suppose I have a PDF which is 2x3 in. I want to create a PDF with a single page, which has multiple copies of this. For example, if the small pieces are in landscape, and the large page is in portr...

0 answers  ·  posted 7mo ago by matthewsnyder‭

pdf
50%
+0 −0
SSH key added to agent, but keeps asking for password

I have my key added to ssh-agent and they show up in ssh-add -l. When I try to actually SSH to a host that requires the key, I still get prompted for a password. I enter it again and again and it s...

1 answer  ·  posted 9mo ago by matthewsnyder‭  ·  last activity 9mo ago by matthewsnyder‭

50%
+0 −0
How to add a new drive to a BTRFS filesystem?

BTRFS is capable of spanning over multiple drives. How to add one more to an existing filesystem?

1 answer  ·  posted 2mo ago by Iizuki‭  ·  last activity 2mo ago by Iizuki‭

60%
+1 −0
Ergonomic way to search man pages

You often have to read man pages to use Linux/Unix software. However, many man pages are not easy to read. They are very long, not always conveniently arranged, and man does not appear to have any ...

3 answers  ·  posted 8mo ago by matthewsnyder‭  ·  last activity 7mo ago by alx‭

60%
+1 −0
How to open a port in firewalld?

How to open a port when using firewalld as the system firewall?

1 answer  ·  posted 6mo ago by Iizuki‭  ·  last activity 6mo ago by Iizuki‭

50%
+0 −0
How to list the first x files in each directory

MWE With the following tree: l1 └── l2 ├── d0 │   ├── f0 │   ├── f1 │   ├── f2 │   ├── f3 │   ├── f4 │   └── f5 ├── d1 │   ├── f0 │   ├── f1 ...

3 answers  ·  posted 7mo ago by mcp‭  ·  last activity 7mo ago by matthewsnyder‭

66%
+2 −0
Show a timestamp on the right side of prompt when executing a command in ZSH

How to configure ZSH shell to print a timestamp on the right hand side of the prompt line when executing a command? I don't want to display the time prior to executing a command. Here's about how ...

1 answer  ·  posted 4mo ago by Iizuki‭  ·  last activity 4mo ago by Iizuki‭

zsh
71%
+3 −0
How to count the lines of a file?

How to get the number of lines in a file? I.e. for a file like this: Line one Line 2 Final line I would like to do something like this: $ count-lines /path/to/the/file/above 3

2 answers  ·  posted 3mo ago by Iizuki‭  ·  last activity 20d ago by Michael‭

66%
+2 −0
Highlight regions in an image with CLI

I have an image (a photo) and I want to highlight certain parts of this. I want to do this from the CLI. I am planning to store the pixel coordinates of polygon vertices in a file, and when I run ...

2 answers  ·  posted 8mo ago by matthewsnyder‭  ·  last activity 8mo ago by samcarter‭

71%
+3 −0
How to invert command exit code?

How to apply a logical not to a shell command, e.g. in a Bash script? So if the command exited with 0 (success) I would like it to be changed to a non-zero value, and if it exited with a non-zero ...

2 answers  ·  posted 6mo ago by Iizuki‭  ·  last activity 2d ago by trueframe‭

60%
+1 −0
What does Gnome Disks "erase" do?

When formatting drives with Gnome Disks, there is an option to "Erase". The help text says this takes longer, but "completely" erases data. What exactly does this option do? Is there a CLI equival...

1 answer  ·  posted 9mo ago by matthewsnyder‭  ·  last activity 9mo ago by mr Tsjolder‭

50%
+0 −0
How do you terminate a DHCP lease in OpenWrt?

I am testing some DHCP stuff, and I want to manually end a lease so I don't have to wait hours for them to expire. How can I do this with OpenWrt?

1 answer  ·  posted 8mo ago by matthewsnyder‭  ·  last activity 8mo ago by matthewsnyder‭

60%
+1 −0
Can you put systemd units under a custom path?

The systemd manual gives a list of path where systemd looks for unit files. However, I want to isolate my units in a path of my own choosing. Is it possible to configure systemd to add some path t...

1 answer  ·  posted 5mo ago by matthewsnyder‭  ·  edited 1mo ago by matthewsnyder‭

66%
+2 −0
How do I make media keys work with PipeWire?

My keyboard has keys for mute, volume up, volume down. In i3wm, I used to have these bound with: bindsym XF86AudioRaiseVolume exec --no-startup-id pulsemixer --change-volume +10 --max-volume 100 ...

1 answer  ·  posted 10mo ago by matthewsnyder‭  ·  last activity 9mo ago by Mithical‭

80%
+6 −0
Looking for a way to sync dotfile content between different machines without introducing security issues

I switch between three computers and have never been able to keep my dotfiles in sync. I cannot put them into source control because they contain sensitive data. So, my question is: how do I share ...

3 answers  ·  posted 6mo ago by paulsweatte‭  ·  last activity 5mo ago by matthewsnyder‭

60%
+1 −0
In i3wm when moving windows, how do I also switch to the workspace if it's active?

Let's say I have workspaces 1, 2, 3 on screen A and 4, 5 on screen B. Currently workspaces 1 and 4 are active. With my current config, moving a window to another workspace never activates it. How...

0 answers  ·  posted 5mo ago by matthewsnyder‭

50%
+0 −0
What is Kmail running in the background?

When I run Kmail on i3, and then close it, it appears to continue running some stuff in the background. For example, I periodically get notifications about new mail from dunst, even though I have c...

0 answers  ·  posted 3mo ago by matthewsnyder‭

60%
+1 −0
Why is there a mono version of Inconsolata?

After installing the InconsolataGo font from the Arch package extra/ttf-inconsolata-go-nerd, I see there is an Inconsolata Nerd Font, Regular and an Inconsolata Nerd Font Mono, Regular. Both are mo...

0 answers  ·  posted 11mo ago by matthewsnyder‭

75%
+4 −0
Documentation for double asterisk glob expansion

Where can I find documentation on double asterisk in glob expansion? It is discussed in the .gitignore section of Pro Git. It works in ls **/* to list all terminal files. It is supported by py...

2 answers  ·  posted 8mo ago by mcp‭  ·  last activity 8mo ago by Kamil Maciorowski‭

60%
+1 −0
Vim key bindings not working in terminal python interpreter

MWE To reproduce: Add bindkey -v to your ~/.zshrc. Invoke python interpreter: python. Type something into the prompt without hitting ENTER: this = "this" + "that". Press ESC and try any vim ...

1 answer  ·  posted 1y ago by mcp‭  ·  edited 7mo ago by mcp‭

60%
+1 −0
Starts systemd service and follow log

I can start services with systemctl start. I can see logs with systemctl status or journalctl. But by the time I run the second the process has already started. I'd like to start a service and imme...

2 answers  ·  posted 9mo ago by matthewsnyder‭  ·  last activity 8mo ago by AdminBee‭

50%
+0 −0
Do you still need to update archlinux-keyring before pacman -Syu?

For some time pacman used to have a problem where: Occasionally Arch maintainers introduce new GPG keys They start signing packages with the keys Your local pacman doesn't receive these until ...

0 answers  ·  posted 9mo ago by matthewsnyder‭

66%
+2 −0
How to change the keyboard layout with Gnome and Arch linux?

My goal is to use a french AZERTY keyboard layout with Arch linux and Gnome desktop environment but use US English as "OS language". Note that I am also open to a "working" solution on any other d...

2 answers  ·  posted 9mo ago by zetyty‭  ·  edited 9mo ago by matthewsnyder‭

71%
+3 −0
How to get a new IP address from DHCP?

How do I make my computer request a new IP from DHCP? I am using Arch with NetworkManager.

1 answer  ·  posted 8mo ago by matthewsnyder‭  ·  last activity 8mo ago by matthewsnyder‭

66%
+2 −0
Run pipeline in the background from git hook

I'm trying to run a pipeline to update a PDF after every push to the 'main' branch. I want it to be atomic, so it doesn't touch the existing PDF until it has finished, so I need to use sponge(1) (...

1 answer  ·  posted 5mo ago by alx‭  ·  last activity 5mo ago by alx‭

80%
+6 −0
How do I view fonts?

How can I view font files, like .ttf, in Linux? I'd like to see a sample of the font (quick brown fox...) and metadata about it (like exact name).

2 answers  ·  posted 11mo ago by matthewsnyder‭  ·  last activity 11mo ago by andrew.46‭

66%
+2 −0
How to append commands to startx from console

MWE startx && xrandr-invert-colors Problem It seems that anything after startx does not get issued in the resulting X session. I'd like to make a bash function that sets up my monito...

2 answers  ·  posted 1y ago by mcp‭  ·  last activity 1y ago by celtschk‭

60%
+1 −0
How to start MariaDB (or MySQL) server on a WSL using systemctl?

When I try to start MariaDB server (same problem with MySQL) on a fresh Debian 11 install in a Windows Subsystem Linux (WSL) I got the following error: $ sudo systemctl start mariadb System has n...

2 answers  ·  posted 10mo ago by zetyty‭  ·  last activity 10mo ago by matthewsnyder‭

60%
+1 −0
How does the root user locate executables?

A little while ago I was helping someone with running Python in a virtual environment, as root, for some specific purpose. I determined easily enough that this requires explicitly specifying the pa...

1 answer  ·  posted 7mo ago by Karl Knechtel‭  ·  last activity 7mo ago by r~~‭

66%
+2 −0
How to decrease image size from commandline

Problem I'd like to be able to decrease images, particularly jpg and png's, either to a percentage of the original file, or a specified size in bytes. MWE decrease --size=900KB -o image_small....

1 answer  ·  posted 1y ago by mcp‭  ·  edited 1y ago by mcp‭

60%
+1 −0
Rename multiple files which have a variable suffix

I compressed some JPEGs with curtail it messed up the filenames. It was supposed to only add -min at the end but ended up adding a random string after the extension 😠: prs@PC:/DOWNLOADS/Pictures$ ...

3 answers  ·  posted 7mo ago by Pr. Sunflower‭  ·  edited 6mo ago by matthewsnyder‭

60%
+1 −0
How to fix DPI for Spotify

Spotify runs on my computer with higher DPI (bigger UI elements) than I'd like. How can I reduce it?

1 answer  ·  posted 8mo ago by matthewsnyder‭  ·  last activity 8mo ago by matthewsnyder‭

66%
+2 −0
Where does GtkFileChooserDialog store bookmarks?

I have some bookmarked folders in GtkFileChooserDialog. I want to add these to my dotfiles. Where are the bookmarks stored?

1 answer  ·  posted 8mo ago by matthewsnyder‭  ·  last activity 8mo ago by Quasímodo‭

60%
+1 −0
Lynis says my /etc/issue is weak - how to strengthen?

When hardening my system with Lynis I had information about /etc/issue and /etc/issue.net being found weak. Lynis redirects me to Enterprise, which is a paid product and a bit overkill for my home...

1 answer  ·  posted 6mo ago by LAFK‭  ·  last activity 6mo ago by LAFK‭

60%
+1 −0
xrandr rotate not filling external monitor

Problem I can rotate output, but it does not fill screen. Instead it rotates in place so that the right side of the screen goes off the monitor. xrandr --output HDMI-2 --auto --mode 1920x1080 --...

1 answer  ·  posted 1y ago by mcp‭  ·  last activity 1y ago by mcp‭

60%
+1 −0
Who creates subdirs under `/run`?

A system daemon needs to create several files under /run/program-name/ (and possibly other subdirs of that). They are the PID file, and at least one Unix socket file (but maybe more). The FHS spe...

1 answer  ·  posted 1y ago by alx‭  ·  edited 1y ago by alx‭

66%
+2 −0
<!nocheck> meaning in Build-Depends

Trying to understand what exactly <!nocheck> does next to a package in build-depends (for example, Perl). Debian Wiki says: Terms can be negated by using an exclamation mark as a prefix ...

0 answers  ·  posted 1y ago by nteodosio‭

60%
+1 −0
How do I globally configure consistent DPI for GUI apps?

How do I configure my system so that all GUI apps use a consistent DPI, without configuring each app individually?

0 answers  ·  posted 8mo ago by matthewsnyder‭

60%
+1 −0
How to identify and separate standalone applications from libraries in Linux package lists?

I want to generate a list of trending Arch/AUR packages that focuses on user-facing applications rather than background libraries and dependencies. I wrote a script that uses the data from pkgstat...

1 answer  ·  posted 7mo ago by ShadowsRanger‭  ·  last activity 7mo ago by alx‭

60%
+1 −0
Nvidia docker runtime: Failed to create task for container

I installed the Nvidia container toolkit so I can use GPU acceleration in Docker containers. However, I can't get the containers to work: $ sudo docker run --runtime=nvidia nvidia/cuda:12.2.0-base...

1 answer  ·  posted 8mo ago by matthewsnyder‭  ·  last activity 8mo ago by matthewsnyder‭

66%
+2 −0
Getting a Module Error When Running Pytest Even Though the Module is Installed in the Current Virtual Environment

Hello everyone, I am encountering an issue when running pytest in my virtual environment. Although I have installed the required modules in my virtual environment using pip, I am still getting a M...

0 answers  ·  posted 10mo ago by ShadowsRanger‭  ·  edited 10mo ago by ShadowsRanger‭

60%
+1 −0
How to reduce DPI of external monitor using xrandr

Have I have the DPI on my laptop set in .Xresources with Xft.dpi: 192. I am outputting to the external monitor with: xrandr --output HDMI-2 --auto --rotate left --right-of eDP-1 Want I want ...

0 answers  ·  posted 1y ago by mcp‭  ·  last activity 9mo ago by Mithical‭

71%
+3 −0
Internet connection and touchpad not working on Ubuntu 22.04 after a force shut down

After a force shutdown on Ubuntu 22.04, installed on a Lenovo Legion 5, the OS seems to have lost its ability to recognize the built-in touchpad or to connect to the internet. For the backstory......

1 answer  ·  posted 9mo ago by Mithical‭  ·  last activity 9mo ago by matthewsnyder‭

75%
+4 −0
How do I tweak the start parameters of GUI apps?

There are many GUI apps on my computer that show up as eg. items in the start menu. When I launch these, what if I want to control how exactly they are launched, such as setting environment variabl...

1 answer  ·  posted 8mo ago by matthewsnyder‭  ·  last activity 8mo ago by matthewsnyder‭