5 ms·
Apart of the .NET/Microsoft/ugly command-lets situation, how do you pitch yourself against PowerShell? The typed pipelines and advanced programming are also the
by oaiey 3y ago
Apart of the .NET/Microsoft/ugly command-lets situation, how do you pitch yourself against PowerShell? The typed pipelines and advanced programming are also there.
Not that I am a personal Powershell fan (in-memory commands and ugly commands is the ugly part for me), but "next-gen" shells with typed streams are not exactly the novelty.
- hnlmorg 3y agoMurex is an abstraction on top of POSIX rather than a replacement for POSIX and coreutils et al. Which means Murex works with all your existing CLI tools without you having to worry altering your muscle memory. If people are already using and like Powershell then I'd recommend they stick with Powershell. But if anyone is using Bash, Zsh or Fish (for example) but longed for something a little more intuitive (fewer footguns, smarter handling of structural data, etc) then Murex is a good option. It's also worth noting that I've modelled the interactive shell on IDEs rather than readline. So the UX in Murex is, in my biased opinion, one of the best out there. However I'm always open to feedback on anything that can be improved in that department. Or in fact, anything regarding the shell.
- oaiey 3y agoDid not realize that POSIX after it was obsolete standardized commands ;) anyway. But I get you. PowerShell is intended to harmonize server management and yours is a general purpose shell. Sounds like a very reasonable differentiation. Do you write articles about how you make coreutils output structured? Is that a command specific adapter or how does that work?
- hnlmorg 3y ago> Did not realize that POSIX after it was obsolete standardized commands ;) anyway. POSIX does standardise some commands[0], albeit not many and good few of them are implemented as builtins even in Bash. But it also defines STDOUT (etc) files. The way Powershell passes data is as .NET objects. The way Murex passes data is as POSIX byte streams but with type annotations passed out of band. This creates some extra overhead in serialising data but the advantage is that it works with all of your existing tooling without modification. > Do you write articles about how you make coreutils output structured? Is that a command specific adapter or how does that work? I haven't but that's a good idea. The way it works is just that you add type annotations. The default type is assumed text data, potentially in columns, like you'd see from `ps aux` or `ls -l`. There are also some builtins (eg [1][2]) that are data type aware. So if you just use the most basic features of Murex, you get a few footguns removed (eg by default variables containing spaces don't get split into multiple parameters) and a slightly different syntax to Bash but all the same CLI tools work. However if you want to invest more into Murex then you get greater power from it eg the ability to inline SQL queries[3], write unit tests[4], better error handling[5][6], etc as well as being able to do `jq` like expressions against a multitude of object and table formats. I really do need to get better at publishing it's features though! [0] https://en.wikipedia.org/wiki/File:POSIX_Utilities.pdf https://en.wikipedia.org/wiki/File:POSIX_Utilities.pdf [1] https://murex.rocks/docs/commands/index.html https://murex.rocks/docs/commands/index.html & https://github.com/lmorg/murex/blob/master/examples/table-indexes.mx https://github.com/lmorg/murex/blob/master/examples/table-in... [2] https://murex.rocks/docs/commands/foreach.html https://murex.rocks/docs/commands/foreach.html [3] https://github.com/lmorg/murex/blob/master/examples/inline-sql.mx https://github.com/lmorg/murex/blob/master/examples/inline-s... [4] https://github.com/lmorg/murex/blob/master/config/defaults/profile_all.mx#L344 https://github.com/lmorg/murex/blob/master/config/defaults/p... [5] https://murex.rocks/docs/commands/runmode.html https://murex.rocks/docs/commands/runmode.html [6] https://github.com/lmorg/murex/blob/master/examples/try-catch.mx https://github.com/lmorg/murex/blob/master/examples/try-catc...
- AlexSW 3y agoIs the scripting language based on bash (etc.)? One thing I enjoy about fish is that it's not just a shell, but also a modern scripting language alternative to sh/bash. Seems like I would lose this with Murex? (There's no right or wrong choice for Murex here, just that has to choose one way or another.)
- hnlmorg 3y agoIt's a completely new scripting language. It uses C-style braces rather than the more ALGOL-style `if / fi` keywords. However the core syntax of the language should still be familiar to those who use Bash (eg pipes, commands, `$` sigils). So there is a little more to re-learn than you would with Fish but it shouldn't feel alien to read and write.