CodeRunner is the best way to write code on your Mac. You can run code in almost any language instantly, and you’ll be surprised by the powerful set of features in such a lightweight and easy-to-use editor.
- 1. Change Build Directory
Create a shell variable named
CodeRunner Preferences > Advanced and set the absolute path to your build directory.
Run command to
$compiler because the path to the program passed by the compile script will be absolute.
Edit Script to edit the compile script and add this bloc of code:
if [[ ! -z $CR_BUILD_DIR ]]; then
Paste this block after the bloc
out="$out.out", this will create a destination folder called
objc and compile the script in.
Do the same with Swift Language.
CodeRunner can run a shell script before executing the file, like the own used in Swift, the file is compiled with this script before running.
In the file, the
script tag is optional.
Check the example with AngularJS below.