hslua-repl-0.1.2: Isocline-based Lua REPL

Copyright | Copyright © 2017-2024 Albert Krewinkel
License | MIT
Maintainer | Albert Krewinkel <tarleb@hslua.org>
Safe Haskell | None
Language | Haskell2010

HsLua.REPL

Contents

- Run scripts as program

Description

Embeddable Lua interpreter interface.

Synopsis

- repl :: LuaError e => LuaE e NumResults
- replWithEnv :: LuaError e => Maybe Reference -> LuaE e NumResults
- setup :: Config -> LuaE e ()
- data Config = Config {
  - replPrompt :: Text
  - replInfo :: Text
  - replHistory :: Maybe FilePath
  }
- defaultConfig :: Config

# Run scripts as program

repl :: LuaError e => LuaE e NumResults Source #

Run a Lua REPL.

replWithEnv :: LuaError e => Maybe Reference -> LuaE e NumResults Source #

Run a Lua REPL, using the table in the given upvalue as the load environment.

setup :: Config -> LuaE e () Source #

Setup a new repl. Prints the version and extra info before the first prompt.

data Config Source #

Lua runner command line options.

Constructors

Config |

Fields

- replPrompt :: Text
- replInfo :: Text
- replHistory :: Maybe FilePath

defaultConfig :: Config Source #