Skip to content

Commit aea3fe7

Browse files
committed
Merge pull request #18 from NativeScript/fatme/run-command
Run command
2 parents 1a22a46 + 3906461 commit aea3fe7

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

lib/services/platform-service.ts

+5
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,12 @@ export class PlatformService implements IPlatformService {
158158

159159
public runPlatform(platform: string): IFuture<void> {
160160
return (() => {
161+
platform = platform.toLowerCase();
162+
163+
this.validatePlatformInstalled(platform);
161164

165+
this.preparePlatform(platform).wait();
166+
this.buildPlatform(platform).wait();
162167
}).future<void>()();
163168
}
164169

resources/help.txt

+13
Original file line numberDiff line numberDiff line change
@@ -109,3 +109,16 @@ Builds the project for specified platform. This generates platform-specific code
109109

110110
--[/]--
111111

112+
--[run]--
113+
114+
Usage:
115+
$ tns run [<platform>]
116+
117+
Platform-specific usage:
118+
$ tns run android
119+
$ tns run ios
120+
121+
This is shorthand for prepare and build.
122+
123+
--[/]--
124+

0 commit comments

Comments
 (0)