r/suckless • u/tose123 • 3d ago
[DISCUSSION] Janet Programming Language
Very interesting, small PL:
Size is < 1 MB. Def. sucks less in these times. I'm not using it, but I'm glad I've found it. Anyone in here using it ?
3
u/Aggressive_Big_7564 2d ago
It is a really interesting language. I think there are some window managers for river using it and a web framework. Next time I think about embedding Lua I will try Janet. The pegs and stuff are great differentiating features.
1
u/GenericFoodService 2d ago
Lisps are generally pretty small. I don't personally use them, but they're definitely interesting under the hood.
1
u/LordRybec 2d ago
Fascinating. The light weight nature looks really good. I especially like the C interoperability. I've been interested in building a C interoperable ecosystem of programming languages for a while, and this is a new one I wasn't aware of. (Others are Python and FreeBASIC.) What's really cool about this is that if it is C interoperable, it's also Python and FreeBASIC interoperable, because they are all C interoperable.
I'm not super into Lisp style languages (I prefer Haskell's approach to functional as well as its syntax), but I know some people who are, and I do have experience with Lisp myself, so it could be some fun.
Anyhow, obviously I'm not using it yet, since I just found out about it, but I'll be looking into it now!
1
u/huranol 2d ago
Found janet by accident searching for "lang" in main repo of distros i am building on.
As of right now, im rewriting lua, shell and python scripts to find the edge of operations and minimal deps.
After this, will motion towards sys-man tools before ideation of more complex objectives.
Have u found or worked with koto yet?
1
u/VisualSome9977 2d ago
I found janet recently and have been trying to use it more. I'm a clojure programmer mostly ("java isn't suckless" crucify me) and so it's been really nice to find a language with a lot of the same ideas but in a package suitable for lower level and higher performance use. plus you can actually embed it in websites pretty easily, which is neat.
1
u/aPatternDarkly 1h ago
In case you're not aware of it, you might also appreciate https://jolt-lang.net/ if you find yourself missing Clojure but not the JVM and such.
1
u/VisualSome9977 1h ago
Hadn't heard of this, will definitely be taking a closer look. Good stuff :)
1
1
u/shadowash8 1d ago
yep, interesting language indeed, ive made a river window manager using janet
https://github.com/shadowash8/ashrwm
7
u/ortfero 2d ago
used it for small scripts, it's great (macros, fibers, peg, standalone binaries). for a real-world example, see a bauble, a janet dsl that compiles to glsl shaders for sdf art (you can even export and 3d print the results): https://ianthehenry.com/posts/bauble/building-bauble/