HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
ngs-lang
ngs
C2016–2025
ngs-lang / ngs

ngs

Next Generation Shell (NGS)

11Distinct people
54Mentions
0Explicit recommenders
1.5KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Next Generation Shell (NGS)

GitHub

Where it is used

No documented product use was verified in the last source check.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

Mentioned in the same Hacker News threads. That is not proof they are substitutes.

This week on Hacker News

Nov 9–Nov 16 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/16/2026, 1:56:48 AM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year54 dated mentions

Observed mentions: 2016-04-21 10:54:15 UTC to 2025-05-04 03:32:47 UTC.

01020302016-01-01 00:00:00 UTC to 2017-01-01 00:00:00 UTC (exclusive): 3 mentions; 1 submissions, 2 comments20162017-01-01 00:00:00 UTC to 2018-01-01 00:00:00 UTC (exclusive): 4 mentions; 0 submissions, 4 comments2018-01-01 00:00:00 UTC to 2019-01-01 00:00:00 UTC (exclusive): 2 mentions; 1 submissions, 1 comments2019-01-01 00:00:00 UTC to 2020-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 4 mentions; 1 submissions, 3 comments20202021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 27 mentions; 0 submissions, 27 comments2022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 8 mentions; 0 submissions, 8 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 3 mentions; 0 submissions, 3 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2025

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20162016-01-01 00:00:00 UTC2017-01-01 00:00:00 UTC312
20172017-01-01 00:00:00 UTC2018-01-01 00:00:00 UTC404
20182018-01-01 00:00:00 UTC2019-01-01 00:00:00 UTC211
20192019-01-01 00:00:00 UTC2020-01-01 00:00:00 UTC101
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC413
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC27027
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC808
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC101
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC303
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC101

What Hacker News says

27 sources
Powershell is available on Linux. Albeit it doesn't always play too nicely with existing CLI tools. There are also other typed shells that appeal to yourself which aren't Powershell but do have behaviours similar to Powershell and which do play a lot more nicely with the wider Linux / UNIX ecosystem: - murex https://github.com/lmorg/murex - Elvish https://github.com/elves/elvish - NGS https://github.com/ngs-lang/ngs I'm the maintainer of murex so happy to answer any questions on that shell here. I do know the the maintainers of Elvish and NGS pop on HN too.
In Unix Shell Programming: The Next 50 Years
> No "proper programming language" is capable of ergonomically piping between programs. Solved. https://github.com/ngs-lang/ngs I'm the author. Frustrated with exactly this situation I created Next Generation Shell. It's a "proper programming language" on one hand but domain-specific for "DevOps"y scripting on another. So sane syntax, data structures, error handling, multiple dispatch on one hand but also syntax for running external programs, pipes and redirects. You are welcome!
In Cheating at a company group activity using Unix tools
Hi! Author here. > This seems to be more a simple programming language than a shell. Currently it's only a programming language. The interactive part will be implemented in the NGS language itself. > simple programming language Since simple is relative: NGS is simpler than Java and more complex than awk I would say. NGS has exceptions, types with inheritance, multiple dispatch, guards (additional conditions to invoke a method), basic functional programming support, patterns, (new, in progress) facility for deeply nested data manipulation, automatic parsing of command line arguments when invoking the optional main(), threads, domain-specific syntax and facilities for running external programs and file manipulation. Simplicity is one of the language goals but not over expressive power. > A shell is first and foremost a UI, only secondarily
Read the rest
a scripting language... I'm having hard time to agree or disagree. There is a lot of interactive usage but there are also a lot of scripts in bash. When I see the scripts I wish bash was "more of a programming language". > foremost a UI ... where surprisingly little innovation happened over the last decades. It's like in the movies when there is an object in the center of the screen and the whole world is rapidly changing around it. That object is the shell. My plans for UI are at https://github.com/ngs-lang/ngs/wiki/UI-Design . > easily take a series of commands you'd do manually and put them in a script You can do it in NGS and even in this simplest use case it will be better than bash - in case of an error the execution will stop (like with -e in bash) and NGS will print stack trace (which I don't know how to do in bash and not sure it can be done in a sane manner). Edit: $a will expand to exactly one argument (as opposed to zero or more), rm -rf "$mydir/" will throw exception if mydir is undefined. Typical things which are expected from modern programming languages. NGS uses small subset of syntax from bash so running external programs in the simple forms looks the same.
In NGS – Next Generation Shell
Comparing shamelessly to my own Next Generation Shell, puting aside the completely insane syntax matters that nobody today would do or accept (such as $x expanding to zero or more arguments). cleaning up temp files Use TmpFile. It is automatically removed when the script exits. stopping automatically on error As in many other modern languages, NGS has exceptions and prints stack trace when they are not handled. Nothing special is required from the programmer. echoing errors Use built in error("my message") function. Alternatively, use exit("my message") to print the error and exit, the exit code defaults to 1 but can provided. Tired of seeing bash scripts starting with definition of warn(), debug(), error(), etc functions. These are part of standard library in NGS. You are welcome to check out the Next Generation Shell project. https://gi
Read the rest
In Common shell script mistakes (2008)
Welcome to (shameless plug) Next Generation Shell. It's a modern programming language for DevOps. It is both concise for running external programs (uses small subset of bash syntax) and it is a "real" programming language with data structures and sane error handling among other things. Compared to general purpose programming languages, it was built for "DevOps"y use cases in mind. See https://github.com/ngs-lang/ngs/wiki/Use-Cases Ability to run external programs is high on the priorities list. In NGS it means having its own short syntax and handling exit codes among other things. NGS throws exceptions on "bad" exit codes. Hint: not for all tools non zero exit code is "bad". Did not see equivalent exit code handling anywhere else. Compared to bash... It's not fair comparison even. Another era, another reality, other expectations. Small ex
Read the rest
ample: When APIs return structured data, well... you better be able to handle it. See https://ilya-sher.org/2018/09/10/jq-is-a-symptom/ Compared to other modern shells, I would say, NGS is programming language first as opposed to shell first.
In Common shell script mistakes (2008)
> > function overloading is supported in the same way that its also supported in Bash too where you might have a function but if there is a alias of the same name that will take priority. > I don't think it is called overloading. That's very different from having two methods with the same name and the "right one" is called based on types of passed arguments. Yeah you're right that's not overloading. I'm not really sure why included that in my description. > In NGS it happens in exactly one place, when main() is called. At that point command line arguments are automatically parsed based on main() parameters and passed to main(). > I don't think I understand your reasoning behind not including named parameters. there isn't really an entry point in murex scripts so function foobar { out foobar } foobar is no different from #!/us
Read the rest
r/bin/env murex out foobar and no different from typing the following into the interactive terminal $ out foobar Which means every call to a builtin, function or external executable is parsed an executed as if it has been forked, at least with regards to how parameters are just an array (actually on Windows they're not even an array. Parameters are passed just as one long string, whitespace and quotation marks and all. Which is just another example of why Windows is a shit platform). This is a limitation of POSIX (and Windows) that I decided I didn't want to work around because otherwise some parts of the language would behave like POSIX (eg calling external programs and how named parameters are passed as `--key value` style flags vs scripting functions where named parameters positional arguments). I wasn't really interested in creating a two tier language where parameters are conceptually different depending on what's being called so I decided to make flags easy instead: function hippo { # Hungry hippo example function demonstrating the `args` builtin args: args { "Flags": { "--name": "str", "--hungry": "bool" } } $args[Flags] -> set flags if { $flags[--hungry] } then { out: "$flags[--name] is hungry" } else { out: "$flags[--name] is not hungry" } } That all said. I'm still not 100% happy with this design: - `args` still contains more boilerplate code than I'm happy with - murex cannot use `args` to automatically generate an autocomplete suggestion So I expect this design will change again. > Sounds also like potentially surprising, somewhat similar to handling exit codes. Yes, it's not per program and that's why it's better but still. I don't see how that's surprising because it's literally the same thing you were describing with NGS (if I understood you correctly). > Same in NGS but https://github.com/ngs-lang/ngs/issues/494 :) lol I like it :) > Sounds like I was not clear enough as if something is not uniform in this regard in NGS. Exceptions are not only for external programs. It just happens that external program can be called inside "if" condition; an exception might occur there. It was me who was unclear as I assumed you meant it was the same error handling for builtins and functions too (as is also the case with murex). I just meant the "reality of handling forked executables" as an example rather than as a commentary about the scope of your error handling :)
In Bash functions are better than I thought
> the mystery behind function overloading In NGS the common case for multiple dispatch would be to define your own type and then add methods to existing multimethod to handle that type; additionally I've simplified the dispatch algorithm exactly for this reason - unclear answer to "what's going to be called actually?". > function overloading is supported in the same way that its also supported in Bash too where you might have a function but if there is a alias of the same name that will take priority. I don't think it is called overloading. That's very different from having two methods with the same name and the "right one" is called based on types of passed arguments. > interpreting an indexed argument into an named arguments. In NGS it happens in exactly one place, when main() is called. At that point command line arguments are automati
Read the rest
cally parsed based on main() parameters and passed to main(). I don't think I understand your reasoning behind not including named parameters. > NGS likes to expose its smart features whereas in murex they're abstracted away a little Sounds about right. Power to the people! > Having different behaviours for different executables hard coded into the shell is one behaviour I purposely avoided. I can see why. NGS prefers to do the right thing in most cases and have shorter and cleaner code. Yes adding some risk, which I see as not that big - exception when an exit code was "ok" for unknown program (unknown external programs default to exception on non-zero exit code). I also dream about moving the hard coded information about programs into separate schema, which could be re-used between different shells. That would be similar to externally provided typescript definitions for existing code, described at https://www.typescriptlang.org/docs/handbook/declaration-fil... > differ between Linux, BSD, Windows, "detect program variant" feature in the schema I mentioned above > hard coding executable behaviour Yep, smells a bit > causes more potential issues than it solves. I think in particular situation with exit codes the risk is low. > users expect the shell to understand all external executables but there are some you haven't anticipated thus breaking expectation / assumptions Yes. Downside. That's the kind of surprises that suck. Need to make sure at least the docs are clearly warning about this. > So instead I've relied on having foundational logic that is consistent. Totally understandable. > STDERR contains a failed message (eg "false", "failed", etc) or STDERR is > STDOUT[6]. This has covered every use case I've come across. Sounds also like potentially surprising, somewhat similar to handling exit codes. Yes, it's not per program and that's why it's better but still. > Additionally STDERR is highlighted red by default As it should! Yes! > mini-stack trace Yes, please! > testing framework baked into the shell language. Same in NGS but https://github.com/ngs-lang/ngs/issues/494 :) > So its fair to say I've spent a significant amount of time designing smarter ways of handling failures than your average shell scripting language. As I'm sure you have too. I guess. Differently of course :) > Personally I just describe it as "error handling" because in my view this is how peoples expectations are rather than the reality of handling forked executables. Sounds like I was not clear enough as if something is not uniform in this regard in NGS. Exceptions are not only for external programs. It just happens that external program can be called inside "if" condition; an exception might occur there.
In Bash functions are better than I thought
> writing shell scripts in Python to be cumbersome because whatever flavor of os.system() I end up using just doesn't work well syntactically. This is exactly how I felt. Bash can't handle structured data well. Python (being general purpose programming language) can't handle calling external programs well because it's not the "focus" of the language. My shameless plug solution is a "real" programming language that can do both well (along with proper handling of exit codes and more goodies for "devops"y scripting). https://github.com/ngs-lang/ngs More about this feeling when you don't have a well fitting language for "devops"y scripting - https://ilya-sher.org/2017/10/10/why-i-have-no-favorite-prog...
In Bash functions are better than I thought
Shameless plug follows. I think shells are horrible not only from (today's) programming perspective but also from UI/UX perspective. In response to commands, shells dump text to your screen: from stdout, from stderr, from different programs, humanly unreadable amounts - they just don't care, it's "not the shell's job" apparently. Here is my take: the shell's job is to do everything for my productivity. Imagine programmers arguing that "notepad" is the best, IDEs are not needed, we need to keep text editing pure. How about shells output objects on the screen and these can be interacted with? Amazing for shells, right? This exists for decades everywhere else. My vision for UI in NGS - https://github.com/ngs-lang/ngs/wiki/UI-Design
In I want a better shell (2019)
Looks pretty close :) What happens in ABS if curl fails in this example? Or JSON parsing fails? In NGS, it's an exception with a stack trace. > fun part NGS is mostly use-cases oriented - https://github.com/ngs-lang/ngs/wiki/Use-Cases Decorators are not implemented yet because there are other things higher up the list. Currently working on deeply nested data structures because it's needed for our use case for FHIR - https://github.com/ngs-lang/ngs/wiki/Deep-Data-Structures-Ma...
In The ABS Programing Language
Hello. Author of Next Generation Shell [1] here. I've skimmed ABS documentation and was surprised by the amount of similarities in thinking and reasoning between ABS and Next Generation Shell. Differences that popped into my head in limited amount of time follow: * ABS has CLI and NGS does not yet, CLI of NGS will be written in NGS itself, so it takes time. The CLI in NGS will be radically different [3]. * ABS runs on Windows. * ABS has decorators, NGS does not yet, still thinking how to do it right and more generic. * ABS has some functions that NGS doesn't and vice versa. * Found inconsistently named functions in ABS (json() vs tsv() - json() parses JSON while tsv() generates tsv); given more eyeballs on NGS, such inconsistencies should come up. * NGS has user defined types. * NGS has many predefined types, ABS has few. * NGS has multi-
Read the rest
methods and multiple dispatch. * NGS has exceptions. * NGS has (partial but already very usable implementation of) Universal Pattern Matching [2] Translating example in the docs: # ABS res = `curl -s 'https://api.ipify.org?format=json'` if !res.ok { exit(1, "An error occurred: %s".fmt(res)) } ip = res.json().ip total = ip.split(".").map(int).sum() if total > 100 { echo("The sum of [$ip] is a large number, $total.") } # NGS ip = ``curl -s 'https://api.ipify.org?format=json'``.ip total = ip.split('.').map(Int).sum() if total > 100 { echo("The sum of [$ip] is a large number, $total.") } In NGS the double backtick syntax above runs external program and parses the output. The check of `ok` is not needed because on error exception will be thrown. [1] https://github.com/ngs-lang/ngs [2] https://github.com/ngs-lang/ngs/wiki/UPM-Design [3] https://github.com/ngs-lang/ngs/wiki/UI-Design
In The ABS Programing Language
Before there are 10 people with "there is a library for that in Python" (because they are not and can not be ergonomic enough): Next Generation Shell is a "real" programming language. It also has syntax for calling external programs. It handles exit codes properly. It has facility for constructing command line arguments. Project - https://github.com/ngs-lang/ngs Motivation related to the above - https://ilya-sher.org/2017/10/10/why-i-have-no-favorite-prog... edit: ah, yes, NGS also supports command line arguments automatic parsing when main() is called; augmenting this facility would be the sane way to solve the problem.
In Bashly – Create beautiful bash scripts from simple YAML configuration

Showing the 15 most recent of 27 sources. Enable JavaScript to search and browse every indexed mention.

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.