3 releases

0.1.2 Mar 29, 2023
0.1.1 Mar 15, 2023
0.1.0 Mar 14, 2023

#744 in Programming languages

26 downloads per month

MIT and maybe CC-PDDC

62KB
920 lines

Sloppy

sloppy is a script interpreter that allows multiple programming languages to work together. It is based on toml format, where user defines a sequence of commands, and what variables each command imports and exports. The name sloppy simply means it is meant for one-time scripts, not for serious work.

Here's an example:

[[command]]
backend = "lua"
errexit = true
imports = []
exports = ["values"]
program = """
values = {
    name = "Tianyu",
    data = { "hello", "world", 123 }
}
print("Hello from Lua!")
"""

[[command]]
backend = "python"
errexit = true
imports = ["values"]
exports = []
program = """
print("Hello from Python!")
print(values)
"""

Supported Backends

  1. lua
  2. python
  3. nushell

Disclaimer

This project is currently at an early stage, use at your own risk. Feedbacks are appreciated.

Author(s)

Tianyu Cheng

Dependencies

~66–105MB
~2M SLoC