configuration-filesscripting-languageembedded-languagepolish-notation

Is there such a thing as an embedded batch language?


I was recently looking through a configuration file for a game I was playing, when it struck me how much the language used in the configuration file resembled a batch language with each line formulated as a command, how simple the syntax was and how immediately clear it was what every line in the file was doing without requiring any surrounding lines of context. Still, I know of no batch language that is frequently used as an extension language, to be embedded into another application.

Are there in fact no batch languages that are designed to be embedded into other programs (foremost, I would imagine, for configuration files), or is it just that I haven't heard about them? If there are, what such languages are there?

And if there are not, is it possible to in some way run a shell script or similar from a program in an isolated environment with custom-defined commands, and access the resulting environment variables from the program afterwards?

Edit: By batch language, I mean that it should be possible to give commands, i.e. formulate lines on the form <command> [<arg1> [<arg2> [...] ] ]


Solution

  • The canonical examples of this are probably Lua and Tcl, both of which were designed to be embedded into other programs.

    Lua is more commonly used these days.

    There is a list of Lua scriptable software on Wikipedia, and another list maintained on the Lua wiki.