Skip to content

Commit 21ff99d

Browse files
committed
Created ionic binary:
1 parent ad0748b commit 21ff99d

3 files changed

Lines changed: 16 additions & 6 deletions

File tree

bin/ionic

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
#!/usr/bin/env node
2+
3+
'use strict';
4+
5+
process.title = 'ionic';
6+
7+
var Ionic = require('../lib/ionic').Ionic;
8+
9+
var ionic = new Ionic();
10+
ionic.run();

ionic.js renamed to lib/ionic.js

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,12 @@
66
http://ionicframework.com/
77
88
A utility for starting and administering Ionic based mobile app projects.
9-
Licensed under the MITlicense. See LICENSE For more.
9+
Licensed under the MIT license. See LICENSE For more.
1010
1111
Copyright 2013 Drifty (http://drifty.com/)
1212
*/
1313

14-
var IonicStartTask = require('./lib/ionic/start.js').IonicStartTask;
14+
var IonicStartTask = require('./ionic/start.js').IonicStartTask;
1515

1616
var argv = require('optimist').argv;
1717

@@ -85,6 +85,4 @@ Ionic.prototype = {
8585

8686
};
8787

88-
89-
var ionic = new Ionic();
90-
ionic.run();
88+
exports.Ionic = Ionic;

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44
"preferGlobal": true,
55
"description": "A tool for creating and building Ionic Framework mobile apps.",
66
"homepage": "http://ionicframework.com/",
7-
"main": "ionic.js",
7+
"bin": {
8+
"ionic": "bin/ionic"
9+
},
810
"keywords": [
911
"ionic",
1012
"ionic framework",

0 commit comments

Comments
 (0)