in Blog, Development

TiShadow – Getting Started (Part 1)

The Problem

One of the most frustrating things about development is the time wasted waiting for the compiler to build up your binary and then installing it either in a simulator (emulator if on Android) or on an actual device.  It doesn’t matter if you are using Titanium, or xCode or Eclipse, it just takes time.

Now lets throw in that Apple locks up our devices and makes it difficult to actually push a binary to our devices.

In our shop, we use Titanium to build both iOS and Android applications from the same codebase.  In over 2 years of development, only one app has gone our our doors that was single platform.

With that in mind, you can understand why I started looking for quicker ways to test code, either on my own devices, or on our developers’ devices.

iOS distribution was partially resolved with TestFlightApp, a (currently) free service that facilitates the distribution of apps built with ad-hoc provisioning profiles.  The entire distribution process was a good bit faster overall, but we were still building and uploading a binary for each build. And it was only for iOS. If we wanted to test on Android, well, that was another build cycle and distribution through Dropbox.

The Solution

I began to hear rumors and stories of black magic from Australia called ‘TiShadow’.

A Brief History of TiShadow

In March 2012, David Bankier, Director at YY Digital in Melbourne Australia, pushed a working copy of TiShadow to Github for the public to take a look at.  He had allowed some folks to play with it early on.

In July 2012, David demonstrated TiShadow for the London Titanium Meetup from his offices in Melbourne over the Internet, a not so insignificant distance of 10,500 miles (16,800 km for those that haven’t rebelled yet).

In October 2012, David was invited to Appcelerator’s CodeStrong in San Francisco to demonstrate not only his previous work with TiShadow, but some of his plans for the future. (video, slides)

In November 2012, David demonstrated his very latest modifications to his project at the Melbourne Titanium Meetup, features that we will look at in our second article on TiShadow.

So What Is It

TiShadow used to be a pretty big core hack. If you wanted to use it, had to download a custom modified Titanium Mobile SDK and build it yourself. Not an easy task for the majority of Titanium developers.

TiShadow essentially works by building and installing a single app on iOS and Android.  This acts as a host or controller on the device.  That client app connects to your TiShadow server which pushes your Titanium project source code and resources out to the device and runs it as if it was compiled into the client app.

How much time did it take? Well, how long does it take to zip up your project and push it OTA to a device? Thats it.  Now think about this.  You aren’t just pushing to a single device.  You are pushing to all your test devices at the same time. Multiple savings.

How do I get Started

Those that know me, understand that I am brutally honest but not mean spirited.  With that statement in mind, let me say: If you can’t follow the in the GitHub Repo of TiShadow, you probably ought not to be thinking about using it.

David has done a very good job of making the installation as easy as possible and I am not going to take the time to duplicate his efforts.

  1. Install TiShadow from npm
  2. If you are using Android, you can find a client app already in Google Play.  To build the binary yourself:
    mkdir ~/tishadowapp 
    tishadow app -d ~/tishadowapp
  3. Open up 2 terminals (osx) or a command prompts (winders).
  4. In one you start the server ’tishadow server’.
  5. Start your client app on the device and enter the ip address of the the system running the tishadow server.
  6. Now in the other command line interface, you cd on over to the root of a titanium project and type ’tishadow run’
  7. Your project, built properly and to good form using nice commonJS coding styles should pop up on your devices.


The prebuilt binary on Play may not have all the modules you will need in your project.  It is enough to get you started, but be prepaired to build out your own custom client down the line.

Ti.include works partially.  My belief is that you need to move away from this, so just updated your code and make your life so much easier already.

Series Links

TiShadow – Getting Started (Part 1) 

TiShadow – Getting Started (Part 2)

TiShadow – Increasing Productivity in your Shop

TiShadow – Educational Potential

TiShadow – Taking it to the Cloud

  1. Been hearing so much about tiShaddow… Thanks for this great summary.

  2. Might be obvious to some but it took me a few minutes to figure out that you need to install the TiShadow app to your device.

    In my case I’m using the iPhone simulator so in the tishadowapp directory I do `titanium build -p ios` then go into the app on the simulator and enter the IP address where the TiShadow server is running.

  3. TiShadow is very useful app.Because I install TiShadow from Mac OSX .and I use on it then I try to connect on Ubuntu and runnig iphone apps.its works. I m very suprising and happy..
    I think everyone use like this .TiShadow is very charming

Comments are closed.


  • This Week in Titanium Mobile Development: 3 Dec 2012 | TiDev April 25, 2014

    […] Feather wrote a great set of articles on getting started with TiShadow. Highly recommended. I recently started using TiShadow and it has made a huge difference in my […]

  • TiShadow – Educational Potential April 25, 2014

    […] TiShadow – Getting Started (Part 1)  […]

  • TiShadow – Increasing Productivity in your Shop April 25, 2014

    […] TiShadow – Getting Started (Part 1)  […]

  • TiShadow – Getting Started (Part 2) April 25, 2014

    […] TiShadow – Getting Started (Part 1)  […]