I was contemplating to go this route for quite a while. I'm even considering going all-in on nushell by replacing most of the bash scripts wherever I can. I think it's the first ever contender since the dawn of bash, that might replace bash. Everywhere. Your support for nushell strengthens this idea. Thanks for this video.
I use taskfiles for similar usecases, it can remote import other taskfile (from git for example) and combined with devbox you get all the dependencies needed. Thanks Viktor, keep them coming! Glad to see you are preparing for the upcoming IDP videos :D
Nushell is definitely the best thing I've started using last year. Starting 2025 all my scripts will be written in it (unless the team really wants bash etc etc)
Thanks to another great video! I think Nushell is a great shell, it definitively simplify CLI development, even if just for the way it handles pipelines and data manipulations.
Good one. Do you know you can build CLIs using Taskfile as well? Try building a cli using Taskfile, you’ll enjoy doing it. I used both nushell and Taskfile to build CLIs. Both are good. Combining both is something I’m exploring next.
I love Taskfile. I think they are very different though. Task is focused more on executing task (hence the name) and is closer to workflow tools like Jenkins or `make`. Both execute tasks one after another or in parallel. Nushell is a programming language. The end result might look similar to users of the end result but how you define it is different. That is not to say that one is better than they other but, rather, that they work differently or, to be more precise, we write them differently.
This is a good question. My experience is that - there are different levels: 1) for a single operation, without any complex data manipulation - I'm using a bash script. 2) For multiple operations in the CLI, where there are dependencies but without _complex data manipulation_ - my tool of choice is *just* (and for you it will be *taskfile* ) 3) Only when I need to build a full-blown CLI with a lot of different endpoints - I use *nushell* . Admittedly, I don't think I'd mix *taskfile/just* with *nushell* , mainly because of the overlap in functionality.
Nushell not having job control is a deal breaker for me. I always come to the point where I want to optimise certain parts of my scripts by running tasks in parallel (even if the script was originally fully sequential), and in bash it's as simple as command1 & command2, but in nushell it's sadly not supported.
As a side note, command1 & command2 is not running in parallel. If you put it to background it is, but then you might have trouble getting results and potential issues with environment variables and a few other things.
This is what i did for years with powershell before i switched to devops job and More out of Windows world. Have to start testing this 👍. Any experience compared to doing same things on Linux with powershell 7?
I haven't used it in many years. Back in the day when I was, it was working only on Windows. I haven't been doing anything Windows-related for a long time and I completely missed that (for a long while now) Powershell actually works everywhere. I'll need to try it out. P.S. I know what I'm about to say is silly, but I'll say it anyway. I just went to check it out and got immediately annoyed by it capitalizing the first letter of each word in commands and adding a hyphen in between (e.g., `Write-Progress`). I know it does not matter but the "Linux" person in me freaks out when seeing it.
@@DevOpsToolkit you dont have to follow capitalization, it will run the same, and you can create an alias if you want to even shorten it, even though some of based commands have a shorter alias builtin
@arieheinrich3457 that's great to know and gives me higher motivation to try it out. As i mentioned earlier, it's been years since i used it very briefly (it was windows-only back then) so I know close to nothing about it. That will be my weekend project 🙂
@@DevOpsToolkit I dont mind opening a Pull request into your repo with the equivalent commands to get to the same end result, but i don't want to take the adventure of learning yourself, the bad things and the good things.
I find mind-blowing that I can understand the gusta of code you showed without any knowledge of the language or even color Syntax. That said, next time please don't just cat out the code, use a proper editor with syntax support
I use bat to show code in a terminal. That gives me syntax highlighting without the clutter of IDE. That being said, nutshell is one of few formats that are still not supported in bat so this video is an exception when syntax coloring is concerned.
I was contemplating to go this route for quite a while. I'm even considering going all-in on nushell by replacing most of the bash scripts wherever I can. I think it's the first ever contender since the dawn of bash, that might replace bash. Everywhere.
Your support for nushell strengthens this idea. Thanks for this video.
I use taskfiles for similar usecases, it can remote import other taskfile (from git for example) and combined with devbox you get all the dependencies needed. Thanks Viktor, keep them coming! Glad to see you are preparing for the upcoming IDP videos :D
Would recommend anyone writing a CLI in Python to explore the Typer and Sh libraries! They make writing awesome CLIs fun again :)
Nushell is definitely the best thing I've started using last year. Starting 2025 all my scripts will be written in it (unless the team really wants bash etc etc)
Thanks to another great video! I think Nushell is a great shell, it definitively simplify CLI development, even if just for the way it handles pipelines and data manipulations.
When scripts start requiring a reusable library, I personally prefer switching to Go.
Thanks again for this very helpful Video!
What do you think of Nushell? Does it make sense to have something in between Bash and, let's say, Go?
Good one. Do you know you can build CLIs using Taskfile as well? Try building a cli using Taskfile, you’ll enjoy doing it. I used both nushell and Taskfile to build CLIs. Both are good. Combining both is something I’m exploring next.
I love Taskfile. I think they are very different though. Task is focused more on executing task (hence the name) and is closer to workflow tools like Jenkins or `make`. Both execute tasks one after another or in parallel. Nushell is a programming language. The end result might look similar to users of the end result but how you define it is different. That is not to say that one is better than they other but, rather, that they work differently or, to be more precise, we write them differently.
@@DevOpsToolkit you are right. That’s why I’m curious how it will work if combining both 😀
@chandup I'd love to see it combined. Ping me when you have something.
This is a good question. My experience is that - there are different levels: 1) for a single operation, without any complex data manipulation - I'm using a bash script. 2) For multiple operations in the CLI, where there are dependencies but without _complex data manipulation_ - my tool of choice is *just* (and for you it will be *taskfile* ) 3) Only when I need to build a full-blown CLI with a lot of different endpoints - I use *nushell* . Admittedly, I don't think I'd mix *taskfile/just* with *nushell* , mainly because of the overlap in functionality.
Nushell not having job control is a deal breaker for me.
I always come to the point where I want to optimise certain parts of my scripts by running tasks in parallel (even if the script was originally fully sequential), and in bash it's as simple as command1 & command2, but in nushell it's sadly not supported.
Have you seen par-each (www.nushell.sh/book/parallelism.html#par-each)?
As a side note, command1 & command2 is not running in parallel. If you put it to background it is, but then you might have trouble getting results and potential issues with environment variables and a few other things.
This is what i did for years with powershell before i switched to devops job and More out of Windows world. Have to start testing this 👍. Any experience compared to doing same things on Linux with powershell 7?
I haven't used it in many years. Back in the day when I was, it was working only on Windows. I haven't been doing anything Windows-related for a long time and I completely missed that (for a long while now) Powershell actually works everywhere. I'll need to try it out.
P.S. I know what I'm about to say is silly, but I'll say it anyway. I just went to check it out and got immediately annoyed by it capitalizing the first letter of each word in commands and adding a hyphen in between (e.g., `Write-Progress`). I know it does not matter but the "Linux" person in me freaks out when seeing it.
@DevOpsToolkit actually iv been too started to get annoyed by Windows captalizations 😄
@@DevOpsToolkit you dont have to follow capitalization, it will run the same, and you can create an alias if you want to even shorten it, even though some of based commands have a shorter alias builtin
@arieheinrich3457 that's great to know and gives me higher motivation to try it out. As i mentioned earlier, it's been years since i used it very briefly (it was windows-only back then) so I know close to nothing about it. That will be my weekend project 🙂
@@DevOpsToolkit I dont mind opening a Pull request into your repo with the equivalent commands to get to the same end result, but i don't want to take the adventure of learning yourself, the bad things and the good things.
I find mind-blowing that I can understand the gusta of code you showed without any knowledge of the language or even color Syntax. That said, next time please don't just cat out the code, use a proper editor with syntax support
I use bat to show code in a terminal. That gives me syntax highlighting without the clutter of IDE. That being said, nutshell is one of few formats that are still not supported in bat so this video is an exception when syntax coloring is concerned.
@@DevOpsToolkit Did a spelling corrector help you type nutshell? 😃
i use bashly
I haven't tried it yet. Adding it to my to-do list...
I prefer go with kong :)
Still can accomplish similar with Powershell 7.x
Its funny how this is literally powershell
Ansible
Ansible is, indeed, a great choice for something like that.
ugh, another one.. 👎
Another what?