News for hackers. Stuff that matters.
Re:GitHub – nushell/nushell: A new type of shell by brushfoot on Wednesday June 16, 2021 @06:16AM (#27526824)
It's supported on Linux. It's one of the first packages I install on a fresh box lately.
Re:GitHub – nushell/nushell: A new type of shell by loulouxiv on Wednesday June 16, 2021 @05:56PM (#27533919)
What do you use it for generally ?
Re:GitHub – nushell/nushell: A new type of shell by brushfoot on Thursday June 17, 2021 @09:45AM (#27539486)
My default shell. Everything from manipulating XML to system administration. I'm a big fan of the object-based pipeline.

Quick examples:

- Accelerators for data and conversion tasks. For example, reading a file with `Get-Content` (or frequently in the shell, the alias `gc`) and parsing and converting into a traversable, queryable XML: `[xml]$myXml = gc my-file.xml`. Then you can go `$myXml.customers.firstName` or use an XPath query.

- To get the difference between two dates, `[DateTime]::Now - [DateTime]'2021-01-01'` returns a `TimeSpan` with the elapsed hours, days, etc. It parses the date string for you because of the `[DateTime]` before it.

- The cmdlets for system administration. For example, exporting processes that use more than 200 MB of RAM and their image paths to CSV: `Get-Process | where { $_.WorkingSet -gt 200000000 } | select ProcessName, Path | Export-Csv memory-hogs.csv`