frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

Open in hackernews

Gleam v1.12

https://github.com/gleam-lang/gleam/blob/main/changelog/v1.12.md
83•Alupis•2h ago

Comments

Alupis•2h ago
Some highlights from this release are listed here[1].

The best part of Gleam in my opinion is the language's design. It's just so elegant to read and write. Take this example code snippet from the release notes:

    pub fn find_book() -> Result(Book, LibraryError) {
      case ask_for_isbn() {
        Error(error) -> Error(error)
        Ok(isbn) -> load_book(isbn)
      }
    }

It's a trivial code snippet, but I'm finding this kind of "first class" pattern matching produces very readable, elegant-looking, well organized code.

There was a discussion the other day about the pipe operator being added to PHP 8.x. Gleam was my first language which included a pipe operator. Now, having used it a bit, I feel every language should have something like it.

    pub fn hello_test() {
      telephone.ring()
      |> should.equal("Hello, Joe!")
    }
The pipe skips so much boilerplate and clearly communicates intent. Absolutely love it.

[1] https://gleam.run/news/no-more-dependency-management-headach...

steve_adams_86•1h ago
I'm so envious of this. In TypeScript I use ts-pattern and Effect Schema, and while they make this logic way nicer, it's insanely verbose and doesn't offer any of the niceties of being first class.
Alupis•1h ago
I have not used it at all, but Gleam does have a javascript target in it's compiler/build-tool. So in theory, you can write Gleam (strongly typed, etc) and produce js.

I've exclusively used the BEAM/Erlang target so far - but the js community within Gleam seems quite interesting.

steve_adams_86•1h ago
I've been considering trying this, but my team already struggles to properly adopt TypeScript so I'm fairly sure introducing Gleam would cause a few people to throw me out a window.
giacomocava•1h ago
Omg yes, pattern matching is such an amazing feature I miss it dearly in languages that don't have it!
ZpJuUuNaQ5•1h ago
>It's just so elegant to read and write.

Interesting. I was just about to write the opposite. I tried Gleam to solve last year's Advent of Code, and it felt like a weird mix between Rust and Elixir. You can't write code as elegantly as you'd do in Elixir, which was somewhat disappointing. I switched back to Elixir after a couple of days. I think the biggest advantage of Gleam is static type system.

lpil•1h ago
If you've examples of code you have in Elixir that you could not express well in Gleam I would be very happy to help you out with that.

The two languages are almost the same at the value level, so code should translate across well.

Alupis•1h ago
Depending when this was, it was likely pre-1.x days? Things moved very quickly there for a while - it's worth checking back in again.

Gleam seems to have a lot of obvious influences from Rust, and the creator is a rust dev.

While the Gleam ecosystem is vastly less mature than Elixir's or Rust's (because it's literally younger), the language itself, I've found, is vastly more pleasant to read/write. YMMV of course.

lpil•1h ago
> Gleam seems to have a lot of obvious influences from Rust, and the creator is a rust dev.

Hi! That's me!

Gleam the language doesn't have any Rust influence really. It's a happy accident that some of the syntax ended up looking the same, but that's likely due to both being inspired by similar languages such as OCaml and the C family. Most the syntax and the semantics predate Gleam's compiler being rewritten in Rust.

The build tool is a rip-off of Cargo for sure though.

Alupis•59m ago
> The build tool is a rip-off of Cargo for sure though.

Hey, great artists steal, as the saying goes...

It's all shaped up really nice. I'm a big fan of Gleam and your work in general.

zem•56m ago
more like both gleam and rust have a strong ML influence (gleam might actually consider itself an ML? not sure about that, but it's definitely a descendant)
thijsvandien•1h ago
Error(error) -> Error(error) has strong if err != nil { return err; } vibes, and I don't consider that a good thing.
Alupis•1h ago
This is a trivial snippet. Often you will transform/map your error into another type (or deal with it in some way), so it's not so much `if err != nil { return err; }` vibes like you're thinking here.

The beauty here is being compelled to handle both the happy and sad paths. You cannot just pretend the sad path doesn't exist.

debugnik•44m ago
That's what Gleam's use expressions[1] are for (the last example is exactly this case). Most languages with the same heritage as Gleam have grown a similar syntactical feature, such as OCaml's binding operators or F#'s computation expressions. Although I appreciate how simple Gleam's is while having similar power.

[1]: https://gleam.run/news/v0.25-introducing-use-expressions/

ASalazarMX•1h ago
The official website has an interesting footer

> As a community, we want to be friendly too. People from around the world, of all backgrounds, genders, and experience levels are welcome and respected equally. See our community code of conduct for more. Black lives matter. Trans rights are human rights. No nazi bullsh*t.

On one hand I applaud that their community standards are inclusive, but on the other hand, it shouldn't be that blatantly ideological from the get go. It's just another programming language, not a political platform.

SwiftyBug•1h ago
The Gleam community has been the best, most welcoming community I've ever seen on the internet. And I've been a around for a while. I attribute this in part to their clear stance.
steve_adams_86•1h ago
I was welcomed too, and strongly encouraged to contribute. It was really nice. Though the signals might appear abrasive to some, it doesn't represent an abrasive group of people at all.
Alupis•58m ago
Joining their Discord and getting greeted by the language creator himself within a few minutes was pretty cool. Most other languages, their creators/maintainers seem so unapproachable and distant. You can talk directly with the core team on there, ask questions, etc. Louis really has built a pretty fun community around Gleam.
steve_adams_86•1h ago
I used to be on the fence with this, finding the ideology-forward attitude fairly abrasive. I've since decided that while I don't love it, I see the perceived necessity of it that some people have. I enjoy the privilege of living somewhere and being a person who no one cares to cause problems for. Some people don't have that experience, and are targeted routinely and unfairly. I see it like they put up these barriers and deterrences because they need to, not just that they want to. People who support them participate in that endeavour because it matters enough.

For guys like me, it seems like a needless distraction from what matters. Unless I consider living a life in which there are people who don't want me to exist, or something. Then yeah, I might throw up a few "please fuck off" signs, I don't know.

AnEro•51m ago
I used to think it was kinda pander-y, but then after participating in some of these communities it was just obnoxious when it wasn't stated, the cultural wedge between people. Where randomly there was drama from someone posting an unrelated yet offensive meme/joke, then it was a huge discussion on if it was ban worthy, if it was okay to joke about, or xyz. When really I just wanted to be nerdy with others.
steve_adams_86•44m ago
I get that. You can put up the signs, but it doesn't need to be a regular, loud topic in the community. In fact, the signs should serve to prevent the need to discuss it in the community and make moderation cleaner and easier.
zdragnar•47m ago
I dunno, it seems like everyone should have learned lessons from the sordid scala and node drama incidents, but instead they're just forgotten.

Don't make in groups and out groups. Just have a "be nice" rule and leave it at that.

steve_adams_86•45m ago
The trouble is that nazis think it's very nice to get rid of the untouchables. Life is messy, you've got to set some boundaries and stick to them or jerks gum up the works.
lpil•1h ago
> It shouldn't be that blatantly ideological from the get go. It's just another programming language, not a political platform.

It's first and foremost a community, and it's important for communities to have clear a code of conduct and moderation of that code.

There are lots of languages without community, Gleam is not one of those.

tuttigachimuchi•1h ago
Programming languages aren’t math—they are cultural products that have the right to express their values and objectives
turnsout•1h ago
Being anti-nazi is not ideological.
ribelo•46m ago
Of course it is. You can't be against anything without an idea, without it you wouldn't be opposed, you'd just not give a shit. Not caring isn't ideological just like not believing in god isn't, but being anti-god? That's pure ideology.
AnEro•56m ago
> It's just another programming language, not a political platform

Politics is baked into everything we do, like the lack of any political messaging is still a political message. With this approach, it weeds out those that don't align with the core community which is ideal for an organization that only thrives with volunteer involvement.

akkad33•38m ago
But this is not very relevant to the release announcement?
ModernMech•29m ago
Trans people are over represented in compilers communities. You don’t get programming languages without the hard work of people in the trans community. In a world where they are constantly under attack, it’s important to make them feel safe and welcome. Trans people are welcome in our dev communities and that needs to be explicitly stated these days, because trans inclusion is not implied in our bigoted society.
ForceBru•28m ago
> Shouldn't be that blatantly ideological, it's not a political platform

Yeah! This always stands out like a sore thumb on the website. Like _yeah_, all of it should go without saying! You're a freely available programming language, of course everyone can use it! Of course everyone is welcome! Does a hammer care about your gender or race? No, anyone can use it! It's also very weird and a little childish to specifically include "no nazi bullshit". Isn't it obvious that "nazi bullshit" isn't welcome? Like a no-brainer? Why does a programming language feel the need to say this? Are prominent nazis actively showing interest in Gleam and trying to promote their "bullshit" with it?

Also, the phrase "nazi bullshit" is severely downplaying the problem with the nazis. "Bullshit" is usually something mildly inconvenient, somewhat unfair, kinda infuriating, but it usually doesn't threaten anybody and doesn't fuel world wars.

atomfinger•10m ago
> Isn't it obvious that "nazi bullshit" isn't welcome? Like a no-brainer?

Unfortunately, not in this day and age.

> Why does a programming language feel the need to say this?

It's less about "the language saying it" and more about the standards of the community that surrounds the language.

For a language to thrive, it needs a community of people contributing to it. If it doesn't, it'll eventually die unused. As such, there's more than "just the language"; it is also a community-building effort.

> Also, the phrase "nazi bullshit" is severely...

IMHO, you're reading too much into the word "bullshit".

brightball•1h ago
Great talk on Gleam from August last year.

https://youtu.be/vyEWc0-kbkw

okkdev•42m ago
The link should probably point to the excellent 1.12.0 post on the website: https://gleam.run/news/no-more-dependency-management-headach...
mistahchris•25m ago
I really like gleam. I have a few unfinished side projects in gleam with about 10k lines of code, so I've had enough of a taste to know I like it. I can't wait to see how it matures. I plan to write more gleam in the future. I am particularly excited about the possibilities of sharing more code between webapp frontends and backends. Gleam has so much potential and is already quite productive.

I am not that online of a person. But I joined the discord to say hi and ask a few questions and I have to say the community really does have great vibes. If I were spending more time online, I would likely bias to spending it in the gleam community. They're a bunch of very friendly, and smart people working on a wide variety of interesting projects.

LLMs Can't Navigate Through the Physical World

https://hansenq.substack.com/p/eval-llms-turn-by-turn-directions
1•Hansenq•3m ago•0 comments

MP becomes first to create himself as an AI bot

https://www.bbc.co.uk/news/articles/cy5pr3q6lrpo
1•mellosouls•3m ago•0 comments

The Bluesky Dictionary

https://www.avibagla.com/blueskydictionary/
2•gaws•5m ago•0 comments

Find memory errors in unsafe Rust in production with GWP-ASan and the Scudo hard

https://blog.colinbreck.com/making-unsafe-rust-a-little-safer-find-memory-errors-in-production-with-gwp-asan/
1•fanf2•6m ago•0 comments

EU age verification app to ban any Android system not licensed by Google

https://old.reddit.com/r/degoogle/comments/1mau7yl/eu_age_verification_app_to_ban_any_android_system/
2•PaulHoule•7m ago•1 comments

How long do you make your customers wait?

https://idiallo.com/blog/do-you-make-your-customers-wait
1•foxfired•8m ago•0 comments

Project Hyperion Interstellar Ship Design Competition

https://www.projecthyperion.org
2•codeulike•8m ago•1 comments

Are there AI-first travel booking products that rethink travel?

1•andi2000•9m ago•0 comments

40 Years of the Amiga, from Commodore

https://www.goto10retro.com/p/40-years-of-the-amiga-from-commodore
1•ingve•10m ago•0 comments

Effortless PWA Integration in Next.js with next-PWA-pack

https://dev.family/blog/article/hidden-costs-of-skipping-discovery-phase
1•devfamdk•11m ago•0 comments

Eval-maxing an AI FFmpeg command generator

https://getkiln.ai/blog/end_to_end_kiln_project_demo
2•scosman•12m ago•0 comments

GPT-OSS Playground

https://gpt-oss.com/
1•leopoldj•12m ago•0 comments

La Quinta Investigating Miami's Viral Remote Receptionist

https://www.miaminewtimes.com/news/la-quinta-investigating-miamis-viral-remote-receptionist-23748941
1•pettycashstash2•13m ago•1 comments

Show HN: Claudespace – Run isolated Claude Code instances locally

https://github.com/dotproductxyz/claudespace
2•usman-m•16m ago•1 comments

Apple to pledge new $100B for US manufacturing

https://www.reuters.com/business/retail-consumer/apple-pledge-100-billion-us-manufacturing-white-house-official-says-2025-08-06/
8•mgh2•18m ago•2 comments

Q1K3 – An homage to Quake in 13kb of JavaScript (2021)

https://js13kgames.com/2021/games/q1k3
1•kykeonaut•18m ago•0 comments

AI Is a Money Trap

https://www.wheresyoured.at/ai-is-a-money-trap/
4•speckx•19m ago•0 comments

Assyriogaming

https://en.wikipedia.org/wiki/Assyriogaming
1•michaeldoron•21m ago•0 comments

The Epstein Files by Heather Marsh

https://georgiebc.wordpress.com/2025/08/03/the-epstein-files/
7•ortr•23m ago•0 comments

Guests Fined $500 for Misusing Hotel Hairdryer: AI Could Soon Monitor Every Move

https://viewfromthewing.com/guests-fined-500-for-misusing-hotel-hairdryer-ai-scans-could-soon-monitor-every-move-you-make-in-your-room/
1•freedomben•23m ago•1 comments

Wandering of the auroral oval 41,000 years ago

https://www.science.org/doi/10.1126/sciadv.adq7275
1•Stratoscope•24m ago•1 comments

Initial DecodeME DNA Results

https://www.decodeme.org.uk/initial-dna-results/
1•cpncrunch•24m ago•0 comments

How Russian money slipped into SpaceX's orbit

https://www.muskwatch.com/p/how-russian-money-slipped-into-spacexs
1•chmaynard•25m ago•0 comments

Tech Noir

https://en.wikipedia.org/wiki/Tech_noir
4•Michelangelo11•26m ago•0 comments

Microsoft's plan to fix the web with AI has hit a security flaw

https://www.theverge.com/news/719617/microsoft-nlweb-security-flaw-agentic-web
2•speckx•26m ago•0 comments

A big part of context engineering comes down to empathy

https://twitter.com/JnBrymn/status/1953173846120403179
1•softwaredoug•27m ago•0 comments

GSA Propels Government into AI Revolution with Addition of Leading Solutions

https://www.gsa.gov/about-us/newsroom/news-releases/gsa-propels-government-into-ai-revolution-with-addition-of-leading-solutions-08052025
1•ChrisArchitect•27m ago•0 comments

A case for non-scalable software

https://stackdiver.com/posts/non-scalable-software/
2•low_tech_punk•27m ago•0 comments

Florida Sues Adult Sites for Ignoring Age Verification Digital ID Law [pdf]

https://docs.reclaimthenet.org/uthmeier-complaint.pdf
1•mikece•27m ago•0 comments

S**t Umbrella

https://zachperret.com/2025/04/04/st-umbrella/
2•ezekg•28m ago•0 comments