This is the main class for running Afterglow as a self-contained JAR application. When you are learning and experimenting in your REPL, the main namespace you want to be using is afterglow.examples
(-main & args)
The entry point when invoked as a jar from the command line. Parse options and start servers on the appropriate ports.
The command-line options supported by Afterglow.
Format an error message related to command-line invocation.
(exit status msg)
Terminate execution with a message to the command-line user.
Set up the logging environment for Afterglow. Called by main when invoked as a jar, and by the examples namespace when brought up in a REPL for exploration, and by extensions such as afterglow-max which host Afterglow in Cycling ’74’s Max.
Holds the running REPL server, if there is one, for later shutdown.
Holds the running OSC server, if there is one, for later shutdown.
Holds the future which is cleaning up expired web sessions, if any.
Start a network REPL for debugging or remote control.
Start the embedded OSC server on the specified port.
(start-web-server port browser)
Start the embedded web UI server on the specified port. If a truthy value is supplied for browser, opens a web browser window on the newly launched server. If the server was already running, logs a warning. Either way, makes sure the background thread which cleans up expired sessions is running.
Shut down the embedded OSC server if it is running.
Shut down the embedded web UI, OSC and NREPL servers.
Print message explaining command-line invocation options.
Holds the running web UI server, if there is one, for later shutdown.