the ability to use two Bluetooth dongles simultaneously, each for one device. try that on Microsoft's clown os and see how pressing the gamepad triggers makes the bluetooth headphones chop up the sound 😂
Linux
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
- Posts must be relevant to operating systems running the Linux kernel. GNU/Linux or otherwise.
- No misinformation
- No NSFW content
- No hate speech, bigotry, etc
Related Communities
Community icon by Alpár-Etele Méder, licensed under CC BY 3.0
"yubi [website name]" in Alt+F2 — asks yubikey for a TOTP code for a website and autotypes it into wherever I've got my focus
While I doubt the concept is unique, the script is: a keyboard shortcut will check the clipboard for a YouTube link and then show launcher options for mpv
or yt-dlp
, including launch arguments for lower quality format and audio only. It launches that in a terminal for easier handling when yt-dlp doesn't work properly (much more common if using proxies, but also if a video is age-restricted or deleted).
So when I see a yt link here, I can just copy it, keyboard shortcut and then it's playing in my local video player.
The text editor shortcut on my taskbar runs a sort of autosave script in ~/.drafts. I wanted my text editor to function more like the one on my phone so I can just jot down random thoughts without going through the whole ritual of naming and saving. It creates YYYYMMDD_text in ~/.drafts (or YYYYMMDD_text_1 etc. if it already exists) and launches Pluma, which I also have configured to autosave every 10 minutes.
The other thing extends beyond Linux itself a bit. I like to joke that I have the most secure NT 4 / Windows 95 lookalike ever put together. Aside from the encrypted and hardened Debian base (/boot is also encrypted), I was in part inspired by Apple's parts pairing (yikes!). So my coreboot is configured to only accept my boot disk. If it's swapped out or missing, or if I want to boot something else, it will ask for a password. In the unlikely event my machine gets stolen, the thief must at a minimum reflash the BIOS or replace the motherboard to make it useful again. Idk, it amuses me every time I think about it.
I created my own openSUSE splash screen for KDE because I felt all the existing ones were a bit amateur and I wanted something professional looking. I haven’t published it because I can’t be bothered creating an account. It only took about 15 minutes because I chopped up another one which had clearly chopped up another one.
I have two mice, one for either hand, and use xinput to flip the buttons on JUST the left one. It's actually one of the main things keeping me from moving to Wayland, which doesn't seem to have the same configuration features
LOL I've never seen that before.
Do you use them both at the same time? Or do you switch between them rapidly? (Maybe you could make a taskbar button-toggle if it's the latter!)
- I have bash scripts
light
anddark
that make dbus calls to set my global theme to light or dark mode. I switch between them regularly, and opening system settings and pressing a button is too inconvenient.
Your first one sounds similar to me though - I use activity-aware Firefox to separate my personal and work accounts on my personal and work plasma activities.
I use compose key sequences to save time writing out long email addresses. For example, I have something like this in my ~/.XCompose:
<Multi_key> <b> <o> <s> <at>: "[email protected]" # Email of my very angry boss
So I can just type Compose (right alt on my system), bos@ and get his email address. Less error prone than typing out emails manually.
I'm probably not the only one to use compose strings as a replacement to a text expander, but I don't know anyone else who does this.
I suspect my habit of having an alias userctl="systemctl --user"
is slightly unusual, as is running Firefox, Steam, and some other graphical programs as systemd units is somewhat unusual (e.g. mod4-enter
runs systemd-run --user alacritty
)
But what I'm actually pretty sure is unique is my keyboard layout. I taught myself dvorak a summer some decades ago, but the norwegian dvorak layout has some annoyances, so I've made some tweaks. Used to be a Xmodmap
file, but with the switch to wayland I turned it into a file in /usr/share/X11/xkb/symbols/
.
Part of what I did to teach myself dvorak and touch-typing at the same time was randomize the placement of the keycaps too. It has a side effect of being a kind of security by obscurity layer: I type quickly and confidently, but others who want to use my machines have an "uhh …" reaction.
I have a zellij snd micro config for journaling and writing that makes a completely borderless full screen terminal with no decoration whatsoever and narrows the terminal for micro to the upper half of the middle 1/3 of my screen.
It helps me focus and limiting to the upper half and middle 1/3 makes it easier for my eyes. I get distracted easily and this helps keep my editor from being the source of that.
Mine is probably more of a combo of things to streamline my workflow than anything else.
I use Sways multiple workspaces to segregate my apps into different workspaces for different tasks on startup of that app using the assign function in my Sway config. For example VS Code and one particular Firefox window always goes to Workspace 3.
I use the Layman Sway scripts to force all my normal workspaces to different layouts that is appropriate for that function. So workspace 3 with VS Code and a Firefox window is set in a 75/25 split with VS Code set to always take the bigger share. I can switch the two sides from largest on the left to largest on the right, or swap the apps between the two splits, or make a window full-screen with simple keyboard shortcuts.
Odd workspaces are on my left monitor, even ones on the right. This coupled with per workspace wall paper (all my windows are translucent, not for everybody I know) and particular tasks locked to predefined workspaces means I am never hunting around for something. Even if I did lose something I can use rofi to switch to it. If its an essential app I can use my keyboard shortcut that I use to launch the app, switch to it using swayr by activating the shortcut again.
I have used QMK for my keyboard to reduce the number of keys I must use to activate most of my shortcuts, and move them to my number row and home row using layers, double taps, and holds. I try to layer up the same family of functions on the same key but on different layers, so for example, the VI arrow keys move between windows, resize windows, move windows, depending on which layer I have chosen.
I'm one of at most a handful people in the world with a full disk encrypted Steam Deck and unlocking using the touchscreen.
Until someone implements https://github.com/ublue-os/bazzite/issues/464 in Bazzite.
I have a custom script, which changes the fan profile (in my case between two thinkfan config files) depending whether the dock is connected or not. That one gets triggered whenever it switches the power source (AC
or BAT0
). (AC gets plugged in -> script starts -> check if dock is connected -> if connected run different profile)
It's janky but very helpful when it works :D
I boot on a custom EFI app to control my dualboot (instead of systemd-boot or grub) that asks a service on my proxmox server which OS I'm supposed to boot.
Overkill, but it allows me to control my dual-boot without a keyboard in my computer (because it's a Bluetooth keyboard so I can't really use it in grub anyway)
A custom EFI app? Is that like a handrolled Unified Kernel Image with some Proxmox-specific addons in it? How'd you make it?
No, it's a EFI app I developed in Rust that does a query over multicast UDP and uses the result to select which EFI app (Windows bootloaded (yeah I know...) Or systemd-boot to start Arch)
There's nothing related to proxmox itself, it's just there that I host my LXC with the service that responds to the quey.
That's so cool! I just started studying uefi-rs yesterday but haven't been able to think of good use cases. Thanks for sharing!
Wow, thanks! It was really fun to build
CTRL+SHIFT+L to sync my room lights to the screen using huenicorn. Plan on hooking up openrgb as well when I can be bothered to write a script.
ChatGPT wrote a Python program that does select->Tesseract OCR for me, but it doesn't always work right with two monitors. I'm too stupid to correct it. How have you done yours, what are you using for selecting the area?
pasting from my keybind config
# snippet based on end4 dotfiles -- FIXME edge case where a
# preexisting tmp.png might be overwritten
# English
bind = Super+Shift,T,exec,grim -g "$(slurp $SLURP_ARGS)" "tmp.png" && tesseract -l eng "tmp.png" - | wl-copy && rm "tmp.png"
# Korean
bind = Super+Shift,K,exec,grim -g "$(slurp $SLURP_ARGS)" "tmp.png" && tesseract -l kor "tmp.png" - | wl-copy && rm "tmp.png"
# Japanese
bind = Super+Shift,J,exec,grim -g "$(slurp $SLURP_ARGS)" "tmp.png" && tesseract -l jpn "tmp.png" - | wl-copy && rm "tmp.png"
I just pipe grim and slurp (i.e. select part of the Wayland screen then copy) into a temporary png, tesseract it into the clipboard, then delete the temporary png.
edit: clarified
I'm pretty sure no one else has my shell script that takes a picture, uses imagemagick to copy a scaled down version of it to a special folder, and then build a string that allows me to just middle click paste the image into Rednotebook so it appears correctly.
ooh I should do that for Obsidian instead of having an enormous directory of Pasted Image 202302050124300845012.pngs. =◡=
I use https://github.com/trganda/obsidian-attachment-management to automatically rename and move screenshots, in conjunction with https://github.com/Mara-Li/obsidian-explorer-hider to hide them. It makes pasting screenshots organized, yet completely transparent.
If I can rant a bit...
I used to do my daily journal as plaintext in Vim. I wanted something that was a little more capable and in RedNotebook I almost got it. It stores plaintext markup (I think yaml?), the thing is it has an edit and a display mode, and you can't edit it in display mode. Inserting a picture is pasting a file path to where that picture is stored. If I linked to where the pictures are stored in my ~/Pictures directory, if I ever migrated from Rednotebook or Linux or anything like that, the links to those pictures would break. So I store teh pictures I link in my journal in a subdirectory alongside the journal itself, so the pics should go with it and it should survive a transfer easier.
This is, of course, extremely user unfriendly to do, because it would mean copying pictures, reducing their resolution so they don't take up the entire damn journal window, and then working through RedNotebook's interface to navigate to where I just stored that picture to generate the link.
Or, I wrote a couple lines of Bash that did most of that for me and put the file path link in the primary buffer so I could open my file browser, right click, select Add To Journal, and then middle click in my journal. Felt kind of clever coming up with that one, and I kind of wish A) it was a bit easier and B) we lived more in a world where we did that kind of thing where things interoperated more than trying to silo things.
I also seperate Firefox on different workspaces, but only manually. How is the extension called? Having it automated would save me some seconds every reboot.
Sway (and i3) you can assign windows to workspaces based on any property that is available in the swaymsg tree. It can do parital matches, so for example if you wanted your Lemmy firefox window to always start on workspace 3 you could use:
assign [title="lemmy" app_id="firefox"] workspace number $ws3
Title can use regex so you can do some pretty neat matching if you need it.
edit: based on the other commenter I think I might be missing a simpler declarative way to do this. The following will be kept for posterity though
The main idea is:
- Use Window Titler to add a title. For me, if I want it on workspace 7, I title the window "7". (NOTE: The title will probably appear like [title], see below)
- Make a script that queries the window manager, and then dispatches a movement to the appropriate workspace. In Hyprland that might be
hyprctl -j
which gives
... json blahblah
"title": "[7] What's a unique customization on your Linux machine you think no one else has? - tchncs — Mozilla Firefox"
... json blahblah
but in Sway it might be something similar to using swaymsg. Only titled windows will have the bracket number thing so just regex that part
- Put it in autostart. Because Firefox takes a while to load on my junk machine I
sleep
for like 30 seconds to a minute before all the titles register.
Definitely not nobody but statistically VERY FEW people will have this combination:
- pop!os (fight me!)
- script that limits accumulator charge to 80% on asus laptop
- script that turns on vpn if out of home and kicks off a backup if at home (through wifi ssid)
Edit: nice try to fingerprint me, big tech. You succeeded! /j
Triangulating your location. Are you... in the Milky Way Galaxy
?
(Thanks for reminding me to limit accumulator charge)
Yeah, I have a script that toggles my Dell XPS between full charge and 80%, as I’m usually on mains and only need full charge occasionally.
On my desktop, I wrote a Python script that pulls a random Star Trek: The Next Generation or Deep Space Nine script from a folder and prints it in STDOUT. I use this in the XScreenSaver Text Manipulation > Program
option to turn Star Trek into a screen saver.
Currently, I use it with the Apple II screensaver, but in its original incarnation, I used the Star Wars intro screensaver. 😈
When I press Super + PrtSc, a bash script performs the following:
Takes a screenshot of the entire desktop (import -window root) and saves it as ~/screenshot.png..
Analyzes the screenshot to calculate the "mean brightness" value of the image. It converts the image to grayscale and determines the average pixel brightness (a value between 0 and 1, where 0 is black and 1 is white).
Checks if the image is dark by comparing the mean brightness to a threshold of 0.2. If the mean brightness is less than 0.2 (i.e., the image is very dark), it applies a negative filter to the image (convert -negate), effectively inverting the colors (black becomes white and vice versa).
Sends the image to a printer (lp command) named MF741C-743C for printing.
an actual print screen, finally
A kind of ‘super’ print screen, in fact.
My keyboard automatically change the keys depending of the app I'm using: closing a tab in the terminal or closing a tab inlthe browser are always the same key.
Custom cowsay written in Rust that pulls German song lyrics from my favorite band from a text file?