The Titanium Command Line (CLI) project
2015-06-17 20:37
465 查看
Installation
[sudo] npm install -g titanium
Bleeding Edge
You can download the latest and greatest unstable Titanium CLI code by running the following:[sudo] npm install -g git://github.com/appcelerator/titanium.git
Obtaining a Titanium SDK
You will need to download a Titanium SDK 3.0 or newer:# stable release (recommended) titanium sdk install --default
There are times when the latest stable release has an issue or lacks a feature in which case you may want to try an unstable Titanium SDK build. These builds are not recommended for production use, but should work for development.
# unstable next release titanium sdk install --branch 3_1_X --default # bleeding edge titanium sdk install --branch master --default
Setting up the Titanium CLI
Before you begin using the Titanium CLI, you should configure it by running the "setup" command:titanium setup
It will prompt you with a number of questions such as your e-mail address (for logging into the Appcelerator Network), the location of your Android SDK, and so on.
Usage
titanium <command> [options]
Built-in Commands
config
Configure your CLI settings.Implementation not complete
titanium config <setting> <value>
help
Displays help or help for a specific command.titanium titanium help titanium --help titanium help <command> titanium <command> --help
login
Logs into the Appcelerator NetworkImplementation not complete
Login requires both user and password options to be passed in.
titanium login <username> <password>
If you omit an option, the CLI will prompt you for the value.
titanium login
logout
Logs out of the Appcelerator NetworkImplementation not complete
titanium logout
sdk
Download and install Titanium SDKssdk install
Installs a specific version of the Titanium SDK. If no version is specified, it assumes the latest.titanium sdk install titanium sdk install <version> titanium sdk install <version> --force
Download, install , and set as default SDK.
titanium sdk install <version> --default
Download and install the latest version for the specified branch
titanium sdk install --branch master
sdk uninstall
Uninstalls a Titanium SDK.titanium sdk uninstall <version>
sdk list
Lists all installed Titanium SDKs. Optionally lists all branches and releases.titanium sdk list titanium sdk list -b titanium sdk list --branches titanium sdk list -r titanium sdk list --releases titanium sdk list -br titanium sdk list --branches --releases
setup
Reconfigures the Titanium CLI by asking you a series of questions.titanium setup
status
Indicates whether you are logged in or not.titanium status titanium status --output json
version
Displays the current version of the CLI and exits.titanium -v titanium --version
info
Displays information about your development environment including Xcode installs, iOS SDKs, Android SDKs, and so on.titanium info titanium info -o json
Hacking the Titanium CLI
In order to begin hacking on the Titanium CLI, you need to download and install git.If you have already installed a previous version of the Titanium CLI, it's recommended you uninstall the old one first:
[sudo] npm uninstall -g titanium
The Titanium CLI is essentially pure JavaScript, so there is no build process. You just need to pull the code and resolve the dependendencies.
git clone git@github.com:appcelerator/titanium.git cd titanium npm install sudo npm link
Running Unit Tests
To run the unit tests, simply run:node forge test
Running Code Coverage
To generate the code coverage, you first must install node-jscoverage. The easist way to do this is run:git clone git@github.com:visionmedia/node-jscoverage.git cd node-jscoverage ./configure make sudo make install
Then run:
node forge test-cov
It will generate a file called coverage.html in the Titanium CLI directory.
Looking for the really old CLI?
Don't worry, it's still around. You can install it by running:[sudo] npm install –g titanium@0.0.26
相关文章推荐
- NPOIHelper
- 获取plist文件的全路径
- 《图书管理系统——java》
- 团队开发------第一次冲刺第4天
- 12 Integer to Roman(int转罗马数字Medium)
- linux网络名字空间介绍
- ALSA驱动很详细的介绍
- centOS安装openoffice的方法
- 架构师应该了解的97件事 读书笔记1
- Spring IOC AOP (二)
- Opencv2.3.1在VS2008和VS2010平台上安装配置图解
- 动态规划之矩阵链乘问题
- 2015 Objective-C 三大新特性
- Mac OS连接Linux
- Docker 网络实现
- 机器视觉开源代码集合
- ListView 使用方法(Asp.Net)
- 【译】发送表单数据
- 最小生成树算法(1)-----------prim
- pci设备学习笔记