Hacker Newsnew | past | comments | ask | show | jobs | submit | amterp's commentslogin

I am working on Rad [0], a programming language built specifically for CLI scripts, so you don't need to write Bash, and it offers CLI-tailored features which make it a better choice than Python.

Lately I've mainly been working on stability and bug fixes. I've released some big features the past few months so I'm doing a big push on polish, before I again tackle some larger features that I'd like to implement.

If CLI scripts is something you're interested in at all, give it a go! We have docs and a guide [1] for getting started, feedback very welcome :)

[0] https://github.com/amterp/rad [1] https://amterp.github.io/rad/guide/getting-started/


Oh, until the URL part, I assumed you were the creator of Red [1]. I vaguely remembered reading about it a couple years ago, and thought "I don't remember it being positioned as for CLI scripts shrug".

Even seeing 'rad' in the URLs, at first I thought you'd misspelt them there :)

[1] https://www.red-lang.org/


This looks great!

I'm currently using Material for MkDocs but was thinking of switching off it, in part due to the lack of options around having custom highlighting in code blocks (my docs website is for a programming language I am working on). What are Zensical's plans here? Tree sitter highlighting would be perfect in my case.


Zensical team here – right now it's still Python/Pygments under the hood, as we're using the same toolchain for rendering for compatibility reasons, but we'll be rethinking language support from the ground up, and tree sitter is something we're experimenting with. Ideally, we'll be able to unify code highlighting with language support with API reference docs.


Love this, lots of great ideas I'll be stealing :)

Folks interested in scripting like this might like this tool I'm working on https://github.com/amterp/rad

Rad is built specifically for writing CLI scripts and is perfect for these sorts of small to medium scripts, takes a declarative approach to script arguments, and has first-class shell command integration. I basically don't write scripts in anything else anymore.


Working hard on Rad, which is aiming to be a Bash-replacement for writing CLI scripts. The goal is to allow users to write maintainable scripts with declarative argument parsing, built-in JSON processing, HTTP requests, and interactive prompts - all in a familiar, readable syntax (Python-like!). Here's an example of the declarative approach to script args:

  args:
      username str           # Required string
      password str?          # Optional string
      token str?             # Optional auth token
      age int                # Required integer
      status str             # Required string
  
      username requires password     // If username is provided, password must also be provided
      token excludes password        // Token and password cannot be used together
      age range [18, 99]             // Inclusive range from 18 to 99
      status enum ["active", "inactive", "pending"]
Rad does all the arg parsing for you (unlike Bash), including validation for those constraints you wrote, and you can get on with writing the rest of your script is a nice, friendly syntax!

Very keen for feedback so if any of that sounds interesting, feel free to give it a go!

https://github.com/amterp/rad


Have you seen usage (https://github.com/jdx/usage)? It seems similar.


Work continues for me on Rad[0]. It's a programming language designed specifically for CLI scripts. I was sick of writing Bash scripts and thought we could do much, much better, so that's the goal with this project. Been working on it for a bit over a year now, and I'm using it every day! Still have many big features in mind, such as commands, I suspect I'm still only at the beginning at this journey!

[0] https://github.com/amterp/rad


Very much agree with the article, this is one of the reasons why I wrote Rad [0], which people here might find interesting. The idea is you write CLI scripts with a declarative approach to script arguments, including all the constraints on them, including relational ones. So you don't write your own CLI validation - you declare the shape that args should take, let Rad check user input for you, and you can focus your script on the interesting stuff. For example

  args:
      username str           # Required string
      password str?          # Optional string
      token str?             # Optional auth token
      age int                # Required integer
      status str             # Required string
  
      username requires password     // If username is provided, password must also be provided
      token excludes password        // Token and password cannot be used together
      age range [18, 99]             // Inclusive range from 18 to 99
      status enum ["active", "inactive", "pending"]
Rad will handle all the validation for you, you can just write the rest of your script assuming the constraints you declared are met.

[0]: https://github.com/amterp/rad


Modern cmd line scripting is an interesting area and I like seeing people's different approaches to improving it. Personally, I want to get as far away from writing control flow, loops, etc in Bash as I can. I'm working on https://github.com/amterp/rad which is a CLI scripting language that takes a more Python-like approach, which people here might find interesting, though it serves slightly different cases than Modernish.


Been working on https://github.com/amterp/rad for almost a year now. It's a programming language designed for writing good CLI scripts, so it's aiming to replace Bash but is much more Python-like, and offers unique syntax and a bunch of in-built support for scripting.

Please check it out if it sounds at all interesting! Keen for feedback :) I've written some docs, including a "getting started" guide, linked in the GitHub page.


I've been working on a programming language for about a year which aims to replace Bash for scripting but is far closer to Python. It's something I hope to see used by many other people in the future, but a very common objection I hear from people I pitch it to is "yeah but an LLM could just generate me a Python script to do this, sure it might be uglier, twice as long, and not work quite as well, but it saved me from learning a new language and is probably fine", to which I have lots of counters on why that's a flawed argument, but it still demonstrates what I think is an increase in people's skepticism towards new languages which will contribute to the stagnation the author is talking about. If you're writing a new language, it's demotivating to see people's receptiveness to something new diminish.

I don't blame anyone in the picture, I don't disagree that time saved with LLMs can be well worth it, but it still is a topic I think we in the PL community need to wrestle more with.


I love your idea.

LLMs are surprisingly bad at bash and apparently very bad at Powershell

Pythonic shell scripting is well suited to their language biases right now


Thanks! :) Yeah in my experience they're okay at Bash but I'm never happy with the scripts it makes, I feel like the ceiling is pretty low on how good Bash scripts can get without a disproportionate amount of effort.

I'm taking a lot of inspiration from Python in the syntax and I'm actually worried it will trip up any LLM I train on my language since I think it will risk probabilistically just reverting to Python mid-answer Time will tell


I'm working on a programming language aiming to replace Bash. It specifically targets CLI scripts where Python or Rust are overkill, but it contains a bunch of constructs that make it particularly well suited for CLI scripts, including arg parsing, table formatting, HTTP querying, Bash command invocation, etc.

Keen to hear people's thoughts and feedback! GitHub here: https://github.com/amterp/rad

The docs site also contains a guide for getting started, including some of the unique features: https://amterp.github.io/rad/guide/getting-started/


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: