Fascists, Racists, Transphobes, Terfs, Homophobes can fuck off.

  • 2 Posts
  • 144 Comments
Joined 3 years ago
cake
Cake day: February 22nd, 2022

help-circle




  • I have about 25 or so shell scripts I use somewhat regularly and well over 300 aliases. I actually specifically don’t wrap package manager related scripts for no reason in particular, but many often do.

    My rule for an alias is if the amount of custom flags gets lengthy, and I use it often, yeah it gets an alias. Here’s an example of using yt-dlp:

    alias ytdl='yt-dlp --sponsorblock-remove all --write-auto-sub -f "bestvideo\*+bestaudio[ext=m4a]/best" -f mp4'
    

    For shell scripts, my rule goes that it should probably have multiple features related around a single idea, that way you can use getopts to create custom flags. For example, I have a script that wraps very basic, but commonly used, git commands, chaining the classic add, commit -m, and push behind a series of read prompts, it has -h flags for help -l for a minimal log output, -i to initialize a new repository (even using github api token to remotely create the repo if you want to use github), and -r to revert back changes to a specified commit.

    Generally speaking aliases will get you what you need most of the time in a pinch, but shell scripting is more powerful, versatile, but potentially more time consuming.

    Others have rightly pointed out that these abstractions can sometimes negatively impact muscle memory, but IMHO this only really applies if you work as devops or sysadmin, where you are often responsible for running many different Linux servers, but usually this isn’t an issue if you have access to the internet and can see your saved aliases and/or scripts (but yeah, instant recall of native commands trumps notes every time).

    Additionally, another mentioned using git to keep track of your aliases, which I totally agree with. Whatever you do, back up your aliases and shell scripts, ideally with a git repo of some kind. This not only allows you to take your new scripts/aliases with you wherever you go, but also reference them later in case it’s not possible to use them on not your machine.

    Hope this helps. Bash can be crazy powerful if you take the time to learn it, and aliases are a great entry point to recognizing that potential. Here’s one of my favorites that combines mkdir with cd:

    alias mkcd='{ IFS= read -r d && mkdir "$d" && cd "$d"; } <<<' 
    

    Good luck, and have fun.


  • On Android, from FDroid you can install an app called Seal, which is a minimal frontend for yt-dlp. I discovered it while trying to circumvent issues Newpipe was having with some update to the YouTube API.

    Unlike Newpipe forks, which can use the sponsor block API but not when downloading the video directly to your device, Seal allows you to input the custom flags available from the yt-dlp cli, so you can automatically skip annoying sponsor mentions even on your downloaded videos.



  • z3rOR0ne@lemmy.mltoLinux@lemmy.mlFavourite DE
    link
    fedilink
    arrow-up
    1
    ·
    3 months ago

    Honestly my first olkb was the Planck from DROP. A 40% keyboard where the numbers and symbols are each on their own separate layer. The defaults on the Voyager were very clunky IMHO, so I simply switched them to the defaults of the Planck, including moving the home row up one whole row. This left a few spare keys as the Voyager is a 55 key, so I simply added two Super keys instead of one as well as a few other duplicates.

    I’ve also heard of some interesting workarounds for using Vim with Colemack/Dvorak. It is funny, when I first discovered OLKBs, I kept encouraging people to use them, and I still do. Same with Vim. But ultimately I get why people don’t. I’m so used to this workflow now, going back to a standard keyboard feels clunky and slow, and I’d imagine my setup feels awkward and alien to most if not all other people.

    But it’s uniquely mine and I can type 100wpm if I am on a roll with his setup.

    The clamps are a hilarious accident that happened to work for me. I was experimenting with different ways to get that near 90° angle shoulder width apart, and this was the3 soluuon I haphazardly stumbled on.

    Glad you like it/find it entertaining! I wish you well in finding what works for you! ✌️






  • z3rOR0ne@lemmy.mltoLinux@lemmy.mlFavourite DE
    link
    fedilink
    arrow-up
    5
    ·
    edit-2
    4 months ago

    Nah, didn’t go that far (yet), just heavily edited a qmk_firmware configuration. So yeah, I’ll admit I didn’t exactly write my own keyboard firmware.

    I have the soldering tools ready for when I have time to learn. Sadly I only have time for software lately, and hardware/firmware has had to take a back seat.

    Customizing your workflow around the keyboard is a helluva drug though! If it weren’t for Vim being configured for QWERTY out of the box, I’d probably configure a COLEMAK or DVORAK setup as well.

    I’d encourage you to go as far down the rabbit hole as you’re comfortable, the learning curve can slow you down initially, but the dividends pay off in the long run imho.

    Here’s a pic of my current setup. The keyboard is prebuilt (Voyager ZSA), just with custom firmware. Couple clamps keep it vertical for ergonomics.



  • z3rOR0ne@lemmy.mltoLinux@lemmy.mlFavourite DE
    link
    fedilink
    arrow-up
    6
    ·
    edit-2
    4 months ago

    I’ve been on BSPWM for nearly 2 years now. Custom scripts and keybindings all over the place. My workflow is so customized and keyboard centric with this TWM. Vim bindings in the terminal, Vimium in the browser, and a heavily customized Neovim Text Editor with Espanso Text expander global keybindings every where… Not to mention a 55 key split Ortholinear Keyboard with custom firmware…yeah… My hands almost never touch my mouse except to game.



  • Yeah, I generally agree with all sentiments. TS is handy at times, but working with poorly written .d.ts types from 3rd party libs is Hell.

    The MS acquisition of Github is sad imho. Using alternatives is nice. I’ll eventually get around to self hosting a Gitea or cgit instance.

    Ubuntu, Mint, and PopOS are probably the closest to a mainstream Linux Desktop from what I’ve seen, and perhaps one day one of those really will take the mantle and push the Linux Desktop forward into the mainstream, but I just don’t see it. I do hope I’m wrong though.




  • On X11, Nvidia is pretty close to plug n’play (unless you install multiple kernels, but even then it isn’t so bad). Wayland has been a stuttery mess for Nvidia for a while now and there’s a long standing issue up that hopefully will be resolved in 550 release.

    That said, linux desktop environment developers will likely have to adjust a large amount of environment variables (more than they probably have already) that thus far have had to be set by the User by hand. One has only to look at the Hyprland docs on setting up Nvidia to see the extent to which the bulk of the configuration is set on the User as it stands right now.