Operand

_

gram: nue

Nue

NuShell bindings.

Around 2.5 years into using NuShell, here are the many commands I use daily. I organize these into modules, and hope you can learn from these examples.

This codebase is meant to reside (or be symlinked) into ~/.config/nushell/; then, Nushell finds these modules through the normal config.nu. This config file then loads launch.nu, which is an index of the sources that can be used to (dis)engage any modules you choose.

Dependency modules

These modules are simple, used to build up the more-complex use cases below.

  • grammar: generic commands for reshaping records inside a nushell command pipeline.
  • nix: sadly, some of our modules require the nix package-manager, to quickly access uncommonly-used packages needed for a command. I'd like to loosen this dependency, though for now the dependent modules are:
    • code
    • disc
    • zk
    • program
    • signal
    • gram
    • diagram
  • disc: alongside sub-modules disc zfs and disc luks, this module helps bind discs (physical media, memory cards, usb cards) into the normal computer filesystem.
  • day: calendar and clock commands.
  • cache: a couple of simple commands for caching the responses from other commands.
  • code: helpers for using git codebases.
  • log: Record the response from commands, keep a record of crucial commands.

Landscape Modules

  • node: My mind's analogy for "files" on a computer is more similar to "nodes" in a graph or tree; so this module maps the usage of crucial disc locations per-user. (soon! this reads the connection addresses from node.yml.)
  • machine: references and connection commands for remote computers, this reads the connection addresses from machine.yml.
  • gram: manage codebases, deploy them to operand; this reads the connection addresses from machine.yml.

Usage Modules

These are used in my normal production process.

  • quick: change and re-load the necessary bindings for the chesapeake OS.
  • session: manage durable console sessions through Zellij.
  • command: many simple commands for common aims.
  • signal: connections and networking.
  • program: launch and manage long-running programs.
  • hub: clone and mirror codebases from github.
  • diagram: process d2 diagrams using a common design language.
  • flash: reproduce the configuration for the chesapeake nix-based operating system.
  • index: index online domains! in a shell!
  • media: Source and play back online media using YT-DLP
  • niri: manage the Niri desktop, in my case used alongside Noctalia.
  • page: explore your browser's pages using Omar Rizwan's phenomenal plugin TabFS.
  • record screen recording on Wayland desktops.

Experiments

  • incus: aims to replace lxc for building sandboxed containers and vms running on Incus.
  • lemonade: run local LLMs on an AMD Ryzen GPU, through Lemonade.
  • usb: explore USB connections
  • press: dump the public API records from any wordpress domain.

Unused? Abandoned.