Skip to content


Subversion checkout URL

You can clone with
Download ZIP
interactive access to the scala REPL, via telnet, http, swing and other generic scripting goodies
JavaScript Scala Perl Shell CSS Erlang
Latest commit bd85131 Razvan Cojocaru on the mac now
Failed to load latest commit information.
app/run on the mac now
notes on the mac now
project on the mac now
web/src/main on the mac now
.classpath on the mac now
.ensime on the mac now
.gitignore on the mac now
.project on the mac now
Building.markdown updated to 2.9.1
LICENSE.txt fix scalaz and speed up response time
README.markdown Fixed broken links
build.sbt small cleanups and version alignement
build.xml on the mac now
patch on the mac now
policyfile.development on the mac now
pub on the mac now
rrestart on the mac now
run used ACE editor almost everywhere now
runpro on the mac now
upload on the mac now


/**  ____    __    ____  ____  ____/___      ____  __  __  ____
 *  (  _ \  /__\  (_   )(_  _)( ___) __)    (  _ \(  )(  )(  _ \
 *   )   / /(__)\  / /_  _)(_  )__)\__ \     )___/ )(__)(  ) _ <
 *  (_)\_)(__)(__)(____)(____)(____)___/    (__)  (______)(____/
 *  Copyright (c) Razvan Cojocaru, 2007+, Creative Commons Attribution 3.0


Embeddable interactive scripting pad for scala. It is available over telnet, http and swing. Read the guide at Try it online at or see building instructions.


So anyone can interact with a running application, having access to all or some of the application's objects.

What is so special about the scrispter? It has full syntax coloring and content assist, for starters! It can be embedded into any application and shares the same port for telnet as well as web access...

How to use?

In the sbt Project file for your project (project/build/Project.scala or project/Build.scala), add the dependency:

"com.razie" % "scripster_2.10" % "0.8.3-SNAPSHOT"


"com.razie" % "scripster_2.9.1" % "0.8.1-SNAPSHOT"

If you want to build it, see building instructions.

If instead you just want to run it or add it to your runnables as a single Jar file, use the latest distribution jar from the github downloads and use it in the classpath.

Make sure that, if you use a SNAPSHOT version, the snapshots repository is added to sbt, as in project/Build.scala :

resolvers ++= Seq("snapshots" at "",
                  "releases"  at "")

For an example, see usage in my snakked project. Good luck!


  • 0.8.3-SNAPSHOT is the 2.10.0 build
  • 0.8.2-SNAPSHOT is the last 2.9.1 build


May add some more scripting languages in the future but otherwise I don't think this will evolve.

Features for when I (or you can) find the time:

  • store and access local scripts
  • sign the scripts and encrypt them for safe emailing
  • more secure access
  • use servlet API for embedding in normal servlet-based apps
  • domain local and domain signed script quoting


Many examples are in the junits: test_src/razie/scripster/test/

Put some objects in a context and run a simple scala script:

val ctx = new ScalaScriptContext("a" -> 1, "b" -> 2)
ScalaScript ("a+b").eval (ctx) getOrElse "?"

Create and add variables to the context, to pass to the next script:

val ctx = new ScalaScriptContext("a" -> 1, "b" -> 2)
ScalaScript ("val c = a+b").interactive (ctx) 
ScalaScript ("c").interactive (ctx) getOrElse "?"

Create a scripster server: razie.scripster.MainScripster.scala



There's only basic policy-file based security - need to add some, especially per-script permissions. The simplest way I see to do that is to create a "client" package for all script code and grant it only specific permissions...

There's no mapping to a "normal" servlet. Jetty support etc. There is however a ScripsterService class that could serve as the basis for that. I might soon entertain moving this to play.

Architectural notes

Scripster and DCI

The simplest application will define its domain model, a few contexts and just give users access to those objects in the respective contexts. That's Scripster for you!

Users are guided through what they can do with the domain objects by the available content assist...

You may want to create UIs to nice-ify the user interaction, but, once you have your domains and contexts, with Scripster, your basic app is up and running in less than 5 minutes.

Something went wrong with that request. Please try again.