Search
Unix filters are quite handy. First of all, you can get an index of any manual page with a simple grep(1): $ man pacman | grep '^[^ ]' PACMAN(8) Pacman Manual ...
Instead of having new stdout lines overwrite the previous one, it seems better to specify that old stdout lines should be overwritten by anything that comes after them. This has the benefit that s...
Use nohup(1), and redirect stdout and stderr to /dev/null The following works as expected, not having to wait until the PDF is generated. #!/bin/sh test "$1" = "refs/heads/main" || exit 0; ...
Here's my approach: find l1 -type d \ | while read d; do find $d -maxdepth 1 -type f \ | head -n3; done; If your middle directories also contain files, it will also show them (of course, ...
This answer is not directly usable under Arch, since I don't know the tools there. I show you a way to do it on Debian, which may inspire you to find a similar way in Arch. With apt-file(1), you ...
To make your example work, you should add Type=oneshot and RemainAfterExit=true to the [Service] section. This way the unit won't be considered active until the curl has actually succeeded, and ei...
There's three parts to this: Find all directories (in your case, sounds like you want depth=3 only) Print the top 3 files in a single directory Apply 2 to each in 1 1 should be a separate q...
You add a port to the public zone like so: # firewall-cmd --zone=public --add-port=8080/tcp Firewalld knows already many of the commonly used ports, so you might just use the service name inste...
Inxi has a -x, -xx, -xxx for extra details. I'd try sudo inxi -G -xxx though if it WILL report VRAM is another matter. My help says: -G Device serial number, class ID; Xorg Screen size, diag; ...
Is there a way in Ubuntu (22.04) to run a given bash command for a given Key combination in Gnome (42.9)? This Ubuntu is running in Hyper-V on a Win10 host. (I would like to run the setxkbmap us a...
It seems like Gnome requires xdg-desktop-portal-gnome. that has been removed to be installed. It turns out that things used to work due to a fallback path that has been removed now. Installing t...
What switches do I need to add to see my video RAM (VRAM) with inxi? inxi -G shows my video card model and other info, but not video RAM.
I'll post this as an example of what I'm looking to do. The following script: import sys a = sys.stdin.read() b = a.strip() c = map(lambda s: s.strip(), b.splitlines()) for s in c: p...
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...
Answering your question as written, this is a hardware-specific question. Since solid-state storage chips typically keep the details of which cells are being used to write data hidden from the OS, ...
After some digging, I was able to figure out the problem. I actually have multiple keys. In Kwallet, I noticed that one of them has the wrong passphrase. So looks like I put the passphrase of Key X...
SSH agent prints some envar commands for sourcing in a shell. However, these are bash-style, and I use fish. Fish barfs at the bash syntax. How can I fix it?
There are three options. I will list them from least practical to most, because I don't want people to stop reading halfway through :) Parse ssh-agent output with your custom script and re-print...
Vim has multiple "registers", which in modern parlance is multiple internal clipboards. By default, yank sends to an anonymous register, which is separate from the clipboard. However, you can make...
How do you securely erase data from a thumb (USB/flash) drive? With traditional (magnetic/spinny) hard drives, it used to be that you could use various tools to simply overwrite with random data, ...
There is not a way to do this from the Web UI (LuCI). Instead: SSH into the router Delete the corresponding line from /tmp/dhcp.leases However, note that this is not enough to get a new IP. ...
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?
I am trying to run a DNS server on my LAN. I set it up where: Dnsmasq is the "initial" server that clients see Dnsmasq resolves internal domains, and handles overrides (such as if I want to blo...
$ echo "4c 6f 72 65 6d 20 69 70 73 75 6d 20 64 6f 6c 6f 72 20 73 69 74 20 61 6d 65 74 2c 20 63 6f 6e 73 65 63 74 65 74 75 72 20 61 64 69 70 69 73 63 69 6e 67 20 65 6c 69 74 2c" | xxd -r orem ipsum...
When I enter the login password incorrectly 3 times, my computer locks me out from attempting a login for 10 minutes. How can I change the timeout?