/moonbit-pdk

Extism PDK for the MoonBit programming language.

Primary LanguageJavaScriptApache License 2.0Apache-2.0

extism/moonbit-pdk

This is an experimental Extism PDK for the MoonBit programming language.

Build

Before building, you must have already installed the MoonBit programming language, the Go programming language, and the Extism CLI tool.

To install MoonBit, follow the instructions here (it is super-easy with VSCode): https://www.moonbitlang.com/download/

Then, to build this PDK, clone the repo, and type:

$ moon update
$ moon install
$ ./build.sh

Run

To run the examples, type:

$ ./run.sh

Status

This PDK is just in its infancy.

The code has been updated to support compiler version:

$ moon version
moon 0.1.20240703 (9f69ed8 2024-07-03)

These plugins work (with the caveat that full UTF-8 input is not yet supported, only ASCII input currently works for strings):

  • greet

    e.g. ./scripts/greet.sh 'My Name'

  • count-vowels

    e.g. `./scripts/count-vowels.sh 'Once upon a dream'

  • http-get

    e.g. ./scripts/http-get.sh