Clone this wiki locally
To learn more about Calatrava, start by reading the overview.
It should be as easy to get started with Calatrava as possible. However, there are still a small number of dependencies that need to be installed beforehand.
Note: Currently, Calatrava only supports development on Macs. this will probably always be the case for iOS apps, but there are plans to at least support Linux for Android and Mobile Web. Windows is a little further off. Pull requests welcomed.
rvm. Calatrava projects are configured to use
rvmby default. You could use Calatrava without it, but you will then need to make sure you have Ruby 2.2.0 or higher installed however you prefer.
- to check ruby version: $ruby --version
- if ruby version is down-level, see which versions are available with $rvm list
- if an appropriate version is in the list, select it with $rvm use version
if an appropriate version is not available, get it with $rvm install 2.0.0
bundler. Install in either your
rvmglobal gemset, or wherever else makes sense for your setup.
Xcode. You'll have to get this from the Mac App Store. Once installed, make sure you download and install the command line tools, and make sure you run
xcode-select. Calatrava doesn't actually directly use Xcode except when building iOS apps, so you can use it on a non-Mac as long as you don't run the iOS build targets.
Android SDK. I recommend installing using homebrew if you're on a Mac. But however you get hold of it, the
androidcommand is expected to be on the path.
Node.js. Only used to run tests, not part of any production code. Again, if you're on a Mac I recommend installing using homebrew.
If you have never set up your Mac for Ruby development before, here are a simple set of steps to get you up and running with all the required pieces.
Once you have the dependenices installed, there are just six simple steps to creating and building your first Calatrava cross-platform mobile app.
Install the Calatrava gem:
gem install calatrava
Create your Calatrava project:
calatrava create <project-name>
cd <project-name>. If you're using
rvmyou will be prompted to trust a new
To build and run the Mobile Web app:
Then browse to
http://localhost:8888in your favourite browser.
To build and install the Android app:
You will need to have an Android emulator running, or a device connected.
To build and run the iOS app open the Xcode workspace in the
iosdirectory, and then build and run the target named after your project.