lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


On 20/11/2021 16:39, steve donovan wrote:
Good day!

This all started because I wanted a better console calculator, Python
was irritating me and typing "lua -e 'print(math.sin(2.34))'" was just
tedious. So in its simplest form, el makes calculation on the console
a little easier on the fingers, and can remember things (even
user-defined functions) for later.

$ el 2*sin[pi*2.3]
1.6180339887499
$ el set tau=2*pi
$ el {tau+0.1 tau+0.2}
{6.3831853071796,6.4831853071796}
$ el set f={x: sin tau*x}
$ el f 0.1
0.58778525229247

It was a fun exploration of the idea "what would a shell-friendly
language based on Lua would look like?" and I hope you find it
entertaining, at least.

The Readme is the Article - otherwise just symlink e to el.lua.
(tested with 5.2 and 5.3)

regards,
Steve D

PS.

https://github.com/stevedonovan/el

Hi Steve!

Glad to see you back on the list!

About "el", wasn't there a similar attempt years ago? I didn't remember the details, but someone tried (as a proof of concept IIRC) to create an OS shell replacement using Lua.

Cheers!

-- Lorenzo