โจ๏ธ External Editors
Instead of using the built-in editor that comes with Mercury4Max (an editor that is running with OpenGL in the Jitter visual environment) or the CodeMirror editor that is running in the MercuryPlayground, you can also work with external code editors and just use Mercury4Max as the sound engine.
๐พ Flokโ
Flok is a web-based P2P collaborative editor for live coding music and graphics developed by Damiรกn Silvani (a.k.a. Munshkr). Similar to Etherpad, but focused on code evaluation for livecoding. While the main focus is on collaborative coding, you can also use flok as an external editor for your solo coding.
โ๏ธ Pulsarโ
Pulsar is a Community-led Hyper-Hackable Text Editor that you can install for Windows, OSX and Linux. You can extend the editor with custom plugins.
After installing the mercury-pulsar
plugin you can type code in the editor and send it via OSC-messages as /mercury-code "<code here>"
over UDP to port 4880
.
๐ป Install (OSX/Linux)โ
Make sure that ppm
(Pulsar Package Manager) is installed. On linux, it should be automatically installed with Atom. On OSX, go to the Pulsar
menu and click Install Shell Commands
.
- Download the plugin or clone via
$ git clone http://github.com/tmhglnd/mercury-pulsar
- Navigate to the directory
$ cd mercury-pulsar
and install the dependenciesppm install
- Load the package
$ ppm link .
- Restart Pulsar
๐พ Install (Windows)โ
Windows doesn't support ppm
, instead use npm
and the following steps:
- Download this repository via
$ git clone http://github.com/tmhglnd/mercury-pulsar
- Navigate to the directory and install the dependencies with
npm
instead ofppm
:$ cd mercury-pulsar
andnpm install
- Manually copy-paste the entire folder
mercury-pulsar
toC:\Users\<username>\.pulsar\packages
๐ฎ Usageโ
- Start Mercury4Max or the MercuryPlayground (running locally!, see instructions here)
- Create an empty file in Pulsar and write your code. This can be a plain
.txt
file. - Go to
Menu
>Packages
>Open Package Manager
, find themercury
package and click onEnable
. - The package should be automatically activated
- You can also toggle the package on/off with
cmd + shift + p
- Search for
mercury:toggle
andenter
.
- You can also toggle the package on/off with
- Type some code and:
- Evaluate with
cmd/ctrl/alt + enter
- Silence the sound with
cmd/ctrl/alt + .
- Randomize variables
cmd/ctrl/alt + shift + r
- Evaluate with