Skip to content

sele-dev/steel_ex

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SteelEx

Hex.pm Documentation

SteelEx allows you to work with embedded Steel Scheme in Elixir. It is heavily inspired by pythonx.

Roadmap

  • Pre-Alpha versions: v0.0.X

Installation

The library is available at hex but currently doesn't include pre-compiled NIFs, so Rust is required to compile the library locally. It can be installed by adding steel_ex to your dependencies list in mix.exs:

def deps do
  [
    {:steel_ex, "~> 0.0.1"}
  ]
end

If using livebook, install it at the top of your notebook:

Mix.install([
  {:steel_ex, "~> 0.0.1"}
])
# => :ok

Usage

The ~SCM sigil is provided to embed Scheme code within Elixir. Currently the last result of evaluating the scheme code will be passed back into the BEAM. See the docs on hexdocs.

import SteelEx

~SCM"""
(cadr '(1 2 3))
"""
# => {:ok, 2}

Development Environment Setup

This is suitable at least for use on Fedora Kinoite. distrobox is useful but not required.

distrobox create --image docker.io/library/elixir:1.18.4 --name steel_ex
distrobox enter steel_ex
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y \
. "$HOME/.cargo/env" \
rustup default stable \
git clone https://github.com/sele-dev/steel_ex \
cd steel_ex \
mix deps.get \
mix test

Related Projects

  • Steel Scheme - Embedded, extensible Scheme dialect built in Rust
  • steel_ex_mcp - MCP server providing Steel Scheme tools

License

Licensed under the Mozilla Public License 2.0 (MPL-2.0).

About

SteelEx allows you to work with embedded Steel Scheme in Elixir.

Resources

License

Stars

Watchers

Forks

Contributors