Getting Started
In here you'll find all the documentation you need to get up and running with Vortex.
How to start using Vortex
Head over to the Vortex source code and clone the repo.
Go to the root of the directory. [Mac/Linux] Run the build script:
build.sh
(requires clang) [Windows] Run the build script:winbuild.sh
(requires clang) If you're on Mac/Linux, the installer will ask if you want to store the interpreter inusr/local/bin
(and set up modules inusr/local/share
). This allows you to call Vortex from anywhere. If you choose yes, you'll need to input your password to continue. If you're on Windows, the same process will happen inC:\Program Files
. Note: If you choose to add the files to your system, you can later remove them by running theuninstall.sh
script found inusr/local/share/vortex
orC:\Program Files\vortex
Depending on your system, the interpreter would have compiled in one of the system folders in
bin/build
(either mac, windows or linux). The executable we just compiled (vortex
) is the interpreter that we'll be using to run our Vortex code. Note: If you chose not to add Vortex to your bin folder, you can manually add it to your PATH so you can call it globally. Otherwise, you'll need to either store it somewhere accessible or within your project. It's also important to note that choosing no will also not compile and install the modules globally, meaning that you cannot reference them. To compile the modules separately, you'll need to run one of these scripts inside the Modules directory:build_modules.sh
(Mac),build_modules_win.sh
(Windows) orbuild_modules_lin.sh
(Linux). If you do not want to install the interpreter and modules globally, you can copy the interpreter and modules folder into a new directory, making sure that any calls to vortex reference the modules you just copied in. This can be done by passing in the filepath of the modules as a second argument to the interpereter:vortex <source filepath> -m <modules path>
Your first Vortex program
Let's write a very quick Vortex program that defines some functions and calls them in a loop.
Start by creating a vortex source file (a file ending in the extension .vtx
) and paste the below code in:
Run the above Vortex program by calling: vortex "<path/to/dir>/hello.vtx"
This is the expected output:
Congratulations! You just ran your first Vortex code 🎉
Read the next sections to get a better understanding of everything that Vortex has to offer.
Language Reference
If you haven't seen the language reference yet, now would be a great time to explore the ins and outs of Vortex:
Last updated