this post was submitted on 21 May 2024
90 points (91.7% liked)

Programming

26421 readers
68 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities !webdev@programming.dev



founded 2 years ago
MODERATORS
all 22 comments
sorted by: hot top controversial new old
[–] einlander@lemmy.world 39 points 2 years ago

Whoa Black Betty, Amber-Lang.

[–] VubDapple@lemmy.world 30 points 2 years ago (1 children)
[–] otter@lemmy.ca 26 points 2 years ago (2 children)

I think it's to make it easier to write bash scripts, for those who are new or when the script is doing a more critical task

Modern Syntax

You will find many of the language features familiar, allowing you to get up and running much faster than if you were learning Bash from scratch.

Runtime Safety

It’s one of the key components missing from regular shell scripts. It can help you catch many bugs at compile time.

Type Safety

Amber ensures that you handle everything that could fail. Each Bash command and function that could fail must be handled in some way.

[–] VubDapple@lemmy.world 9 points 2 years ago

Ok, I guess that makes sense. Bash is a pretty old school language for those raised in the functional programming era

[–] thebardingreen@lemmy.starlightkel.xyz 4 points 2 years ago (1 children)

So if you're already pretty good at bash would you bother to switch and learn this?

[–] vext01@lemmy.sdf.org 30 points 2 years ago

Never heard of this language, but you'd be surprised how hard it is to write a correct and portable shell script.

Personally, I'd break out python once the script gets larger than a few lines, or rust if I want something more proper.

[–] deathmetal27@lemmy.world 24 points 2 years ago

So basically the TypeScript of bash.

[–] key@lemmy.keychat.org 16 points 2 years ago (1 children)

I love the concept. I hate many of the language design choices.

[–] wargreymon2023@sopuli.xyz 10 points 2 years ago (1 children)

Don't like it one bit

If bash is hard to program, get away with it, not build atop of it.

[–] laughterlaughter@lemmy.world 0 points 2 years ago (1 children)
[–] wargreymon2023@sopuli.xyz -2 points 2 years ago (1 children)

okay but the author has to write it, why not write something useful open source?

[–] furikuri@programming.dev 3 points 2 years ago

For fun or to play around with transpilers?

[–] Unpigged@lemmy.dbzer0.com 4 points 2 years ago (1 children)
[–] MachineFab812@discuss.tchncs.de 2 points 2 years ago (1 children)

We need a way to watch for replies to comments without commenting ourselves... (not an answer to your question, sorry)

[–] Unpigged@lemmy.dbzer0.com 2 points 2 years ago (1 children)

I mean, my comment isn't really meaningful either so, touche, Internet stranger.

[–] MachineFab812@discuss.tchncs.de 1 points 2 years ago

No, I meant I was following your comment, as I am interested in the answer to your question.

[–] thingsiplay@beehaw.org 3 points 2 years ago

Was posted a few hours before and has many comments: https://beehaw.org/post/13943043

[–] aluminium@lemmy.world 2 points 2 years ago

I mean if you want a shell language that behaves more like a regular programming language, PowerShell core is a thing.

[–] smileyhead@discuss.tchncs.de 2 points 2 years ago

When JavaScript developer starts writing a Linux script.