News for hackers. Stuff that matters.
Re:Script Lisp by mythz on Saturday February 06, 2021 @02:57PM (#26049374)
Some unique features about #Script Lisp:

- It can be embedded in the same page with other #Script templating & JS Script languages where they're all parsed into the same AST tree & evaluated as one [1]

- As it requires no build or compilation it can be easily embedded into .NET Apps to script Apps, e.g. here's a Unity3D example using Lisp to script Unity objects in a running game [2]

- There's a TCP Lisp REPL plugin you can open in .NET Apps to allow runtime scripting of a live running app, e.g for inspecting internal state or invoking remote functionality [3]

- It has a cool "watch" mode that's great for exploratory programming that revaluates on save, where you can do tasks like query RDBMS's, File Systems (inc. AWS S3 / Azure Blob), run shell scripts, query JSON APIs, etc [4]

- Can play with it in its Live Lisp LINQ Examples [5]

[1] https://sharpscript.net/docs/syntax#multi-language-support

[2] https://sharpscript.net/lisp/unity

[3] https://sharpscript.net/lisp/#techstacks-tcp-lisp-repl-demo

[4] https://sharpscript.net/lisp/#run-and-watch-lisp-scripts

[5] https://sharpscript.net/linq/restriction-operators?lang=lisp

Re:Script Lisp by thom on Saturday February 06, 2021 @01:58PM (#26048887)
Another increasingly accomplished and explicitly Clojurey effort is Babashka:

https://github.com/babashka/babashka

Re:Script Lisp by newlisper on Saturday February 06, 2021 @03:18PM (#26049574)
I have given up on Clojure, life is too short to suffer the frustrations of Java libraries.
Re:Script Lisp by cyberbanjo on Saturday February 06, 2021 @03:28PM (#26049649)
The comment your replying to is about a JVM-less Clojure implemtation
Re:Script Lisp by mark_l_watson on Saturday February 06, 2021 @04:51PM (#26050320)
Indeed! Babashka is such a cool project. SBCL save-image stand-alone command line apps start very quickly, instantly it seems, but still I think that Babashka scripts or apps even start faster.
Re:Script Lisp by newlisper on Saturday February 06, 2021 @03:43PM (#26049757)
GraalVM is based on the JVM, it consumes Java libraries...
Re:Script Lisp by fulafel on Sunday February 07, 2021 @01:43AM (#26053185)
Babashka programs run on sci, a Clojure interpreter written in Clojure. That interpreter is compiled with GraalVM to get quick startup time and single binary distribution. But passing on the sins of the father, so to say, here is like dismissing Lua becuase you don't like C libraries.

Providing libraries for babashka works over a language agnostic interface based on bencode-serialized data, and separate processes[1]. Indeed if you look at the pod registry there are pods writtenin Rust, Haskell, Go in addition to Clojure, not to mention the Python example in the pod tutorials.

[1] https://github.com/babashka/pods

Re:Script Lisp by m463 on Saturday February 06, 2021 @01:40PM (#26048725)
related, this works, even on macos:

  #!/usr/bin/emacs --script
  (message "hello, world")
Re:Script Lisp by neilv on Saturday February 06, 2021 @02:24PM (#26049084)
I once did that for Web CGI with pretty elaborate HTML that used pulled data. Doing Web CGI in Emacs Lisp at the time was even much more productive than in Perl.

If someone is trying to measure the executable startup performance, check that you've disabled loading of non-base Emacs Lisp code you don't need, and also make sure that your application code is byte-compiled on disk. (Usually, compiling the base Emacs binary involves/d loading a lot of Lisp code and doing whatever bytecompiling it did in that version, and then saving a core image to disk, so that you don't have to do all that expensive stuff. But if your distro is forcing loading a lot of additional Emacs Lisp code at each startup, you'll take a big hit. There are command line arguments to disable the site-specific and account-specific Emacs Lisp loading.)

Re:Script Lisp by jinwoo68 on Saturday February 06, 2021 @01:56PM (#26048872)
Sadly Apple doesn’t ship emacs anymore with macos. Of course you can (should?) install yourself.
Re:Script Lisp by gumby on Saturday February 06, 2021 @07:47PM (#26051603)
That’s odd and sad, as simple emacs bindings (c-a, c-k, c-y etc) are included in every app that uses the standard text libraries.

Took me years to notice as they were so deeply wired into my fingers that I just used them intuitively.

Re:Script Lisp by m463 on Saturday February 06, 2021 @04:06PM (#26049939)
Wow, really?

I always install from https://emacsformacosx.com/ and didn't check on the text-only emacs.

EDIT: Catalina killed it. Apple disappoints me.