4 ms·
I'm very curious to hear from the folks who have used Nu as a daily driver. Besides the initial relearning costs and the rough edges to be expected from work-in
by asoneth 5y ago
I'm very curious to hear from the folks who have used Nu as a daily driver. Besides the initial relearning costs and the rough edges to be expected from work-in-progress software, have you run into downsides compared to shells like Bash or Fish?
- thayne 5y agoI haven't switched to it as my daily driver (yet) because of some downsides. Several are addressed in this release, but there are still a few features that aren't there yet including: - no support for background tasks, or resummoning stopped processes - while completion was added in 0.60, it doesn't look quite as featureful as zsh completion, and of course it doesn't have as many completions written as older shells - less common need, but I don't think there is a way to do something like `exec {myvar}>file` - I don't think there is an equivalent of `<(command)` to pass the output of a command to another command as a file. Although that could probably be implemented as a plugin pretty easily.
- ripley12 5y ago> I don't think there is a way to do something like `exec {myvar}>file` I might be misunderstanding this, but piping to `save` is how you usually redirect to a file in Nu: https://www.nushell.sh/book/commands/save.html https://www.nushell.sh/book/commands/save.html
- thayne 5y ago`exec {myvar}>file` will open a file descriptor that can write to `file`, and then store that file descriptor in the variable `$myvar`, so you can then redirect additional commands to it with `>$myvar` or `>>$myvar`. From the bash man page: > Each redirection that may be preceded by a file descriptor number may instead be preceded by a word of the form {varname}. In this case, for each redirection operator except >&- and <&-, the shell will allocate a file descriptor greater than or equal to 10 and assign it to varname. If &- or <&- is preceded by {varname}, the value of varname defines the file descriptor to close. If {varname} is supplied, the redirection persists beyond the scope of the command, allowing the shell programmer to manage the file descriptor himself.
- ripley12 5y agoThanks, I was misunderstanding.
- conradludgate 5y agoI daily drove it for a few months but eventually switched back to zsh. Besides a few features it was missing, I realised that I just don't use shell features much, so it's superior pipelining with proper structured data ended up being a hindrance because I couldn't just copy paste scripts from the web
- asoneth 5y agoThanks, that makes a lot of sense. I use Fish so I'm used to having to occasionally translate snippets from the web by now. (I try and tell myself it's good to understand what the commands I'm copying from random internet guides actually do, but to be honest that does not make it feel less annoying when it happens.)