Skip to main content
Glama
emicklei

melrōse musical expression player

by emicklei
import.go568 B
package dsl import ( "fmt" "os" "path/filepath" "github.com/emicklei/melrose/core" ) // ImportProgram runs a script from a file func ImportProgram(ctx core.Context, filename string) error { pwd, ok := ctx.Environment().Load(core.WorkingDirectory) if !ok { pwd = "" } fullName := filepath.Join(pwd.(string), filename) data, err := os.ReadFile(fullName) if err != nil { abs, _ := filepath.Abs(fullName) return fmt.Errorf("unable to read file[%s] :%v", abs, err) } eval := NewEvaluator(ctx) _, err = eval.EvaluateProgram(string(data)) return err }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/emicklei/melrose'

If you have feedback or need assistance with the MCP directory API, please join our Discord server