eupolicy.social is one of the many independent Mastodon servers you can use to participate in the fediverse.
This Mastodon server is a friendly and respectful discussion space for people working in areas related to EU policy. When you request to create an account, please tell us something about you.

Server stats:

215
active users

#nushell

0 posts0 participants0 posts today

Can we please have one standard way to define shell completions, that is compatible with all shells?

I'm moving from zsh to nushell, and it's relatively new, and you have to configure completions by writing a lot of code, including a lot of files, it's a nightmare.

It's easier for older shells like zsh or fish only because other people already done it, and some packages include per-shell completions.

There is @carapace_sh which attempts to do the right thing, but having completions in the other place than actual app is not very good idea.

usage.jdx.dev/ is trying to do the same but differently, and it has a way for an app to provide a schema for completions. This is step in the right direction, but not many tools support this.

Has anyone tried to put this somehow on the shell level? E.q. app includes a file like `myapp.completions` , and shell have a module which reads the file and generates a list of completions based on user input.

The right way to do this, is probably by defining a standard cross-platform/cross-shell schema. And it can be read by the shell, or by the tool like carapace or usage...

usage.jdx.devUsageSchema for CLIs
#Linux#zsh#bash

I was using #zsh for the last many years, and I have configured EVERYTHING the way I like.

- Auto-completions
- Per-directory history
- #McFly for Ctrl-R quick search
- Aliases

Now I'm moving to #nushell and I want to configure everything in the same way. But, per-directory history is either broken or non-existent: github.com/nushell/nushell/dis

People do not use per-directory history? This is AWESOME, every time you switch directory you have your entire relevant history at your fingertips. I recommend everyone to try it.

zsh has per-directory-history plugin (i was using oh-my-zsh)
#atuin has even better search, you can filter by workspace/directory/session/...

Atuin has solved missing/broken per-directory history partially, but god I want this to be default in all shells.

GitHubHow to get per-directory history by "Up Arrow" · nushell nushell · Discussion #15670How do I limit history available by "up arrow" key, to only include items from current directory? I'm using sqlite history, so in theory this should be possible. In my previous life with zsh, there...

Hello world! This is a human-maintained account for Nushell. Thanks Hachyderm for hosting us.

One way to introduce Nushell is using three "pillars" that form the core of the project:
1. Shell
2. Programming Language
3. Structured Data

1/N #nushell

My current Linux desktop 11/2024:

Hardware: ThinkPad T480 with Intel i7 from 2018, dual internal batteries, 512 GB SSD, 32GB RAM.

Software:
- Fedora 41 KDE :fedora: :kde:
- Distrobox with RHEL9 (UBI) :redhat:
- Fish Shell 🐠 (gradually shifting to Nushell)
- Vivaldi Webbrowser :vivaldi:
- KMail/KOrganizer
- Konsole Terminal emulator
- Starship Prompt
- Neovim :neovim:
- Podman :podman:
- KleverNotes
- Tokodon for Mastodon
- Steam :steam: , Bottles and ProtonUP-QT

#linux#fedora#kde

Been using #nushell for a few months now and I'm entirely unconvinced by it's scripting engine.

The design is so restrictive that I usually just revert to #python for anything more than a few lines of code. Block scoping is such a PITA in particular - why can't I populate my mutables in loops? The final scripts end up being so unnecessarily complex and impossible to maintain which defeats the entire purpose of a shell language.

My shell quest continues to marceltheshell.org/ next :)

marcelHome | marcel