โจ๏ธ 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โ
The Mercury Pulsar plugin is now available through the built-in Package Manager in Pulsar.
- Open Pulsar.app
- Click on Packages > Open Package Manager
- Search for
mercury - Click
Install
๐ป Install via commandlineโ
Make sure that ppm (Pulsar Package Manager) is installed. On linux and windows, it should be automatically installed with Atom. On OSX, go to the Pulsar menu and click Install Shell Commands.
Open the Terminal and type: ppm install tmhglnd/mercury (If ppm fails, you can also use pulsar -p).
Optionally you can also first clone this repository and install it manually:
- Download this repository via
git clone http://github.com/tmhglnd/mercury-pulsar - Navigate to the directory and install the dependencies
cd mercury-pulsarandppm install - Load the package
ppm link . - Restart Pulsar
๐ฎ 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
.txtfile. - Go to
Menu>Packages>Open Package Manager, find themercurypackage and click onEnable. - The package should be automatically activated
- You can also toggle the package on/off with
cmd + shift + p - Search for
mercury:toggleandenter.
- 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