Skip Navigation
How big is your desk?
  • CSS is turing conplete.

  • Can I remove a git repo without resorting to `rm -rf` ?
  • What about adding the flags last?

    rm deletethisrepo -rf
    
  • It's easier to remember the IPs of good DNSes, too.
  • You could still NAT between v6's though.

  • how does this piece move?
  • Like a normal horsey, but the square it leaves behind remains on fire, destroying the next piece to land on it.

    Only the most recent square it was on remains on fire.

  • New 2024 POSIX Standards specify features for sh and standard shell utilities
  • IMO the NUL-delimited options are by far the biggest win for shell scripting. $' ' will be the most commonly used addition, but "$(printf '...')" was always an option before. You don't really have an alternative read -d ''.

  • Minor text rendering bug
  • Strange, I don't see this behavior on my device. Not sure what information would be relevant to debugging this though.

  • Do you play non-steam games?
  • A few from Itch, Parallel Launcher from Flatpak for SM64 hacks

  • XWayland 24.1 Released With Explicit Sync, Better Rootful Experience
  • It's probably the biggest deal for games running in xwayland

  • Finally something worse than “looking for 10yrs of SwiftUI experience”
  • That's a latrine. They're talking about a fancy light fixture.

  • I Upgraded The Steam Deck - 16GB vs 32GB of RAM.
  • Also, monetization

  • Switching to Wayland as a WM user
  • How is it compared to wofi?

  • d6 base, d12, d8, d10, %ile, d20, d4.
  • If you say "a 10d10", I know what you mean, but "10d10" is definitely the sum of 10 10-sided dice.

  • Do you daily drive Wayland, if so since when, if not when will you?
  • More people should be like you.

  • Do you daily drive Wayland, if so since when, if not when will you?
  • Exact same. Sway's 1.0 release was March of 2019, and it did everything I needed.

    Even playing games on my desktop, Xwayland worked fine for me.

  • Touch a file in Linux
  • Nope. If you open a nonexistent path and you have permissions to write to that directory, then that file is created.

  • Niri release 0.1.3 - the horizontally scrolling tiling wayland WM
  • 8GB memory + two Firefox profiles makes things difficult on my laptop.

  • Is there a downside to Flatpak?
  • Others have mentioned disk usage and desktop integration. There is some truth to them, but shared runtimes keeps disk uasge down (although worse than native apps). Desktop launchers now search /var/lib/flatpak/exports/share/applications by default, but I'm still having issues with themes in one or two niche apps.

    Trust is the big one. The benefit of your distro's packages is that they are maintained by a limited number of maintainers. Flatpaks have a much, much larger number of maintainers, which is where sandboxing comes in. Flathub now marks apps with lax permissions as "potentially unsafe", which is a huge step in communicating this to the average user.

    Most desktop apps can get away with having next to no access, as long as they support the appropriate XDG desktop portals.

    Ultimately, your mileage will vary, as there are many classes of application which are ill-suited to being sandboxed. Program launchers, programming languages, IDEs, file managers are a few.

  • What's stopping you from coding like this ?
  • Move the keyboard to the floor

  • Different perspectives
  • I grew up with Fahrenheit, but switched my weather app to use Celsius for a while, and I've internalized it pretty well. It works fine. The "human experience" angle doesn't work anyway because that experience is very locale-dependent.

  • Release fish 3.7.0 (released January 1, 2024)
    github.com Release fish 3.7.0 (released January 1, 2024) · fish-shell/fish-shell

    This release of fish includes a number of improvements over fish 3.6.4, detailed below. Although work continues on the porting of fish internals to the Rust programming language, that work is not i...

    Release fish 3.7.0 (released January 1, 2024) · fish-shell/fish-shell

    This release of fish includes a number of improvements over fish 3.6.4, detailed below. Although work continues on the porting of fish internals to the Rust programming language, that work is not included in this release. fish 3.7.0 and any future releases in the 3.7 series remain C++ programs.

    Notable improvements and fixes

    • Improvements to the history pager, including:
    • The history pager will now also attempt subsequence matches (#9476), so you can find a command line like git log 3.6.1..Integration_3.7.0 by searching for gitInt.
    • Opening the history pager will now fill the search field with a search string if you’re already in a search (#10005). This makes it nicer to search something with and then later decide to switch to the full pager.
    • Closing the history pager with enter will now copy the search text to the commandline if there was no match, so you can continue editing the command you tried to find right away (#9934).
    • Performance improvements for command completions and globbing, where supported by the operating system, especially on slow filesystems such as NFS (#9891, #9931, #10032, #10052).
    • fish can now be configured to wait a specified amount of time for a multi-key sequence to be completed, instead of waiting indefinitely. For example, this makes binding kj to switching modes in vi mode possible.
    • The timeout can be set via the new fish_sequence_key_delay_ms variable (#7401), and may be set by default in future versions.
    0
    Raspberry Pi - Introducing: Raspberry Pi 5
    www.raspberrypi.com Introducing: Raspberry Pi 5! - Raspberry Pi

    Announcing Raspberry Pi 5, coming in late October: over 2x faster than Raspberry Pi 4, featuring silicon designed in-house at Raspberry Pi.

    Introducing: Raspberry Pi 5! - Raspberry Pi
    268
    After a multi-year hiatus, an org transfer with new admins and maintainers, jq 1.7 has been released!
    github.com Release jq 1.7 · jqlang/jq

    After a five year hiatus we're back with a GitHub organization, with new admins and new maintainers who have brought a great deal of energy to make a long-awaited and long-needed new release. We'r...

    Release jq 1.7 · jqlang/jq

    Check out the newest version of everyone's favorite^[citation needed] command line json processing tool!

    Highlights include significant speed improvements (>10x on some of my workloads), new flags, new builtins, and a litany of bugfixes.

    3
    How do you shell expand your variables and why?

    x-post from !programming@programming.dev: https://programming.dev/post/2165136

    4
    What are the most inscrutable lines of $SHELL you've ever written?

    I'm sure some of you have absolute monstrosities of sigils (I know I do, in my .zshrc alone). Post them without context, and try and guess what other users's lines are. If you want to provide context or guess, use the markdown editor to spoiler-tag your guesses and explanations!

    1
    jq-shell: Functions for bringing json structures useful to shell
    github.com GitHub - xPMo/jq-shell: Functions for making json structures useful to shell

    Functions for making json structures useful to shell - GitHub - xPMo/jq-shell: Functions for making json structures useful to shell

    GitHub - xPMo/jq-shell: Functions for making json structures useful to shell

    This came out of playing around with curl and the Lemmy API. I wanted a repeatable way to declare a bunch of shell parameters from a json object, so I wrote a jq module! Take a look at the README for examples, or once you install, run

    shell source <( curl 'https://programming.dev/api/v3/community?id=267' | jq -r 'import "shell" as shell; .community_view | shell::param' )

    Currently this project only provides a param function, and only supports Bash and Zsh. If I think of other useful helper functions, I may add them to the project.

    This uses _ as a default prefix for each parameter. This is so things like {"PATH": "..."} generate typeset _PATH='...' and don't mangle your $PATH, for example. The prefix can be customized by passing in a string: param("mypfx").

    Before declaring a 1.0, I'm planning on expanding shell support, and have the function determine how to output using the the $SHELL parameter:

    ```fish

    This does not work (yet!)

    eval (curl $URL | jq -r ' import "shell" as shell; "fish" as $SHELL | .community_view | param ') ```

    Always up for feedback!

    0
    [ysh] (2/3) Sketches of YSH Features

    YSH, or the shell formally known as oil, is touted as a possible upgrade path from Bash.

    This is the first in a three-part series of posts re-introducing the language.

    1. Reviewing YSH
    2. Sketches of YSH Features (you are here)
    3. YSH, Narrow Waists, and Perlis-Thompson Problems (Not yet released)
    0
    [ysh] (1/3) Reviewing YSH

    YSH, or the shell formally known as oil, is touted as a possible upgrade path from Bash.

    This is the first in a three-part series of posts re-introducing the language.

    1. Reviewing YSH (you are here)
    2. Sketches of YSH Features
    3. YSH, Narrow Waists, and Perlis-Thompson Problems (Not yet released)
    0
    [zsh] Builtin Option Parsing in Zsh
    xpmo.gitlab.io Using Zparseopts

    tl;dr: Always use the flags -D and -E (and -F if available). Add a colon to indicate an argument is required (similar to getopt)

    Using Zparseopts
    0
    Tracing is your friend!

    A huge part of programming in general is learning how to troubleshoot something, not just having someone else fix it for you. One of the basic ways to do that is by tracing. Not only can this help you figure out what your script is doing and how it's doing it, but in the event that you need help from another person, posting the output can be beneficial to the person attempting to help.

    (If your shell isn't listed and you know how to enable tracing, comment below and I'll add it to the table!)

    Shell | How to enable tracing ---|--- Bash | set -x or set -o xtrace Fish | set fish_trace on sh | set -x Zsh | set -x or setopt xtrace

    Also, writing scripts in an IDE that supports your language. syntax highlighting can immediately tell you that you're doing something wrong.

    If an IDE isn't an option and you're using Bash or Sh, you can paste your script into https://www.shellcheck.net/

    (Inspired by this post on /r/bash)

    2
    Here's a sed tutorial I wrote a few years ago
    xpmo.gitlab.io Intermediate Sed Usage

    If you’ve been using Linux for any small length of time, you’ve likely used sed before. Most of the time, you’ve seen it in the form of sed "s/find/replace/g", so you simply go to it whenever there’s a replacement you want to do. But sed stands for stream editor, and as a tool it can do more than ju...

    Intermediate Sed Usage

    Feedback is still welcome, either here or as Merge Requests to my Gitlab Pages repo.

    0
    gamma Gamma @programming.dev
    Posts 13
    Comments 102
    Moderates