From e0768b47bfc0c3b43764e97ba7eed9705785beee Mon Sep 17 00:00:00 2001 From: DimitarTachev Date: Tue, 16 Jul 2019 17:38:06 +0300 Subject: [PATCH] docs: update outdated docs --- docs/man_pages/index.md | 1 - docs/man_pages/lib-management/plugin-add.md | 2 +- docs/man_pages/lib-management/plugin-create.md | 5 ++++- docs/man_pages/lib-management/plugin-remove.md | 2 +- docs/man_pages/lib-management/plugin-update.md | 2 +- docs/man_pages/project/configuration/platform-add.md | 12 +++++------- docs/man_pages/project/configuration/prepare.md | 3 +-- docs/man_pages/project/creation/create.md | 1 - docs/man_pages/project/testing/build-android.md | 2 +- 9 files changed, 14 insertions(+), 16 deletions(-) diff --git a/docs/man_pages/index.md b/docs/man_pages/index.md index 0d86ade439..50996a387f 100644 --- a/docs/man_pages/index.md +++ b/docs/man_pages/index.md @@ -29,7 +29,6 @@ Command | Description ---|--- [create](project/creation/create.html) | Creates a new project for native development with NativeScript. [preview](project/testing/preview.html) | Generates a QR code that can be scanned by the NativeScript PlayGround app. -[init](project/creation/init.html) | Initializes an existing project for native development with NativeScript. [platform add ``](project/configuration/platform-add.html) | Configures the current project to target the selected platform. [platform list](project/configuration/platform.html) | Lists all platforms that the project currently targets. [platform remove ``](project/configuration/platform-remove.html) | Removes the selected platform from the platforms that the project currently targets. This operation deletes all platform-specific files and subdirectories from your project. diff --git a/docs/man_pages/lib-management/plugin-add.md b/docs/man_pages/lib-management/plugin-add.md index 400b8706ee..5aac7e8a0b 100644 --- a/docs/man_pages/lib-management/plugin-add.md +++ b/docs/man_pages/lib-management/plugin-add.md @@ -8,7 +8,7 @@ position: 1 ### Description <% if(isConsole) { %>Installs the specified plugin and any packages that it depends on.<% } %> -<% if(isHtml) { %>Installs the specified plugin and its dependencies in the local `node_modules` folder, adds it to the `dependencies` section in `package.json`, and prepares the plugin for all installed platforms. If you have not configured any platforms for the project, the NativeScript CLI will prepare the plugin when you add a platform. For more information about working with plugins, see [NativeScript Plugins](https://github.com/NativeScript/nativescript-cli/blob/master/PLUGINS.md).<% } %> +<% if(isHtml) { %>Installs the specified plugin and its dependencies in the local `node_modules` folder, adds it to the `dependencies` section in `package.json`, and prepares the plugin for all installed platforms. If you have not configured any platforms for the project, the NativeScript CLI will prepare the plugin when you add a platform.<% } %> ### Commands diff --git a/docs/man_pages/lib-management/plugin-create.md b/docs/man_pages/lib-management/plugin-create.md index b267887ade..d574329b1f 100644 --- a/docs/man_pages/lib-management/plugin-create.md +++ b/docs/man_pages/lib-management/plugin-create.md @@ -10,9 +10,12 @@ position: 1 Creates a new project for NativeScript plugin development. The project uses the [NativeScript Plugin Seed](https://github.com/NativeScript/nativescript-plugin-seed) as a base and contains the following directories: * `src` - source code of the plugin -* `demo` - simple NativeScript application used to test and show plugin features * `publish` - shell scripts used to build and pack the plugin source code and publish it in [NPM](https://www.npmjs.com/) +The command will also propose you to setup demo applications and if you accept them, it will create the following additional directories: +* `demo` - simple NativeScript application used to test and show plugin features +* `demo-angular` - simple Angular application used to test and show plugin features + The project is setup for easy commit in Github, which is why the command will ask you for your Github username. <% if(isHtml) { %>Before starting to code your first plugin, you can visit the NativeScript documentation page for [building plugins](https://docs.nativescript.org/plugins/building-plugins#step-2-set-up-a-development-workflow) or the [plugin seed repository](https://github.com/NativeScript/nativescript-plugin-seed/blob/master/README.md).<% } %> diff --git a/docs/man_pages/lib-management/plugin-remove.md b/docs/man_pages/lib-management/plugin-remove.md index b00e19e3bd..543e695878 100644 --- a/docs/man_pages/lib-management/plugin-remove.md +++ b/docs/man_pages/lib-management/plugin-remove.md @@ -8,7 +8,7 @@ position: 4 ### Description <% if(isConsole) { %>Uninstalls a plugin by its name.<% } %> -<% if(isHtml) { %>Removes the specified plugin and its dependencies from the local `node_modules` folder and the `dependencies` section in `package.json`. This operation does not remove the plugin from the installed platforms and you need to run `$ tns prepare` to finish uninstalling the plugin. For more information about working with plugins, see [NativeScript Plugins](https://github.com/NativeScript/nativescript-cli/blob/master/PLUGINS.md).<% } %> +<% if(isHtml) { %>Removes the specified plugin and its dependencies from the local `node_modules` folder and the `dependencies` section in `package.json`. This operation does not remove the plugin from the installed platforms and you need to run `$ tns prepare` to finish uninstalling the plugin.<% } %> ### Commands diff --git a/docs/man_pages/lib-management/plugin-update.md b/docs/man_pages/lib-management/plugin-update.md index 9ba3a5f9dc..05607ba5f5 100644 --- a/docs/man_pages/lib-management/plugin-update.md +++ b/docs/man_pages/lib-management/plugin-update.md @@ -8,7 +8,7 @@ position: 7 ### Description <% if(isConsole) { %>Uninstalls and installs the specified plugin(s) and any packages that it depends on.<% } %> -<% if(isHtml) { %>Uninstalls and installs the specified plugin(s) and its dependencies in the local `node_modules` folder, adds it to the `dependencies` section in `package.json`, and prepares the plugin(s) for all installed platforms. If you have not configured any platforms for the project, the NativeScript CLI will prepare the plugin(s) when you add a platform. For more information about working with plugins, see [NativeScript Plugins](https://github.com/NativeScript/nativescript-cli/blob/master/PLUGINS.md).<% } %> +<% if(isHtml) { %>Uninstalls and installs the specified plugin(s) and its dependencies in the local `node_modules` folder, adds it to the `dependencies` section in `package.json`, and prepares the plugin(s) for all installed platforms. If you have not configured any platforms for the project, the NativeScript CLI will prepare the plugin(s) when you add a platform.<% } %> ### Commands diff --git a/docs/man_pages/project/configuration/platform-add.md b/docs/man_pages/project/configuration/platform-add.md index fb5b23281c..3af417fd26 100644 --- a/docs/man_pages/project/configuration/platform-add.md +++ b/docs/man_pages/project/configuration/platform-add.md @@ -13,16 +13,14 @@ Configures the current project to target the selected platform. <% if(isHtml) { Usage | Synopsis ------|------- -Android latest runtime | `$ tns platform add android [--framework-path ] [--symlink] [--sdk ] [--platform-template ]` -Android selected runtime | `$ tns platform add android[@] [--framework-path ] [--symlink] [--sdk ] [--platform-template ]` -<% if (isMacOS) { %>iOS latest runtime | `$ tns platform add ios [--framework-path ] [--symlink]` -iOS selected runtime | `$ tns platform add ios[@] [--framework-path ] [--symlink] [--platform-template ]`<% } %> +Android latest runtime | `$ tns platform add android [--framework-path ] [--sdk ] [--platform-template ]` +Android selected runtime | `$ tns platform add android[@] [--framework-path ] [--sdk ] [--platform-template ]` +<% if (isMacOS) { %>iOS latest runtime | `$ tns platform add ios [--framework-path ]` +iOS selected runtime | `$ tns platform add ios[@] [--framework-path ] [--platform-template ]`<% } %> ### Options -* `--framework-path` - Sets the path to a NativeScript runtime for the specified platform that you want to use instead of the default runtime. If `--symlink` is specified, `` is the complete path to a valid npm package or a directory that contains a NativeScript runtime for the selected platform and must point to directory in which the runtime is already extracted. If `--symlink` is not specified, `` must point to a valid npm package. -* `--symlink` - Creates a symlink to a NativeScript runtime for the specified platform that you want to use instead of the default runtime. If `--frameworkPath` is specified, creates a symlink to the specified directory. If `--frameworkPath` is not specified, creates a symlink to platform runtime installed with your current version of NativeScript. -* `--sdk` - Sets the target Android SDK for the project. `` is a valid Android API level. For example: 17, 19, MNC.<% if(isHtml) { %> For a complete list of the Android API levels and their corresponding Android versions, click [here](http://developer.android.com/guide/topics/manifest/uses-sdk-element.html#platform).<% } %> +* `--framework-path` - Sets the path to a NativeScript runtime for the specified platform that you want to use instead of the default runtime. `` must point to a valid npm package. * `--platform-template` - Sets the platform template that will be used for the native application. `` is a valid npm package, path to directory, .tgz or GitHub URL that contains a native Android or iOS template. ### Arguments diff --git a/docs/man_pages/project/configuration/prepare.md b/docs/man_pages/project/configuration/prepare.md index 211773f3ed..b68a662d79 100644 --- a/docs/man_pages/project/configuration/prepare.md +++ b/docs/man_pages/project/configuration/prepare.md @@ -7,8 +7,7 @@ position: 7 ### Description -Copies common and relevant platform-specific content from the `app` directory to the subdirectory for the selected target platform -in the `platforms` directory. This lets you build the project with the SDK for the selected platform. <% if(isMacOS) { %>You must specify the target platform for which you want to prepare your project.<% } %> +Starts a Webpack compilation and prepares the app's `App_Resources` and the plugins `platforms` directories. The output is generated in a subdirectory for the selected target platform in the `platforms` directory. This lets you build the project for the selected platform. <% if(isMacOS) { %>You must specify the target platform for which you want to prepare your project.<% } %> When running this command the HMR (Hot Module Replacement) is not enabled by default. In case you want to enable HMR, you can pass `--hmr` flag. diff --git a/docs/man_pages/project/creation/create.md b/docs/man_pages/project/creation/create.md index 1bc0a7ecf9..1f920a84c7 100644 --- a/docs/man_pages/project/creation/create.md +++ b/docs/man_pages/project/creation/create.md @@ -58,6 +58,5 @@ Template | Command Command | Description ----------|---------- -[init](init.html) | Initializes a project for development. The command prompts you to provide your project configuration interactively and uses the information to create a new package.json file or update the existing one. [install](/lib-management/install.html) | Installs all platforms and dependencies described in the `package.json` file in the current directory. <% } %> diff --git a/docs/man_pages/project/testing/build-android.md b/docs/man_pages/project/testing/build-android.md index e4041c7ecb..ad054ea51f 100644 --- a/docs/man_pages/project/testing/build-android.md +++ b/docs/man_pages/project/testing/build-android.md @@ -17,7 +17,7 @@ General | `$ tns build android [--compileSdk ] [--key-store-path ` is a valid Android API level. For example: 22, 23.<% if(isHtml) { %> For a complete list of the Android API levels and their corresponding Android versions, click [here](http://developer.android.com/guide/topics/manifest/uses-sdk-element.html#platform).<% } %> +* `--compileSdk` - Sets the Android SDK that will be used to build the project. `` is a valid Android API level. For example: 28, 29. The minimum supported SDK is 28. <% if(isHtml) { %> For a complete list of the Android API levels and their corresponding Android versions, click [here](http://developer.android.com/guide/topics/manifest/uses-sdk-element.html#platform).<% } %> * `--clean` - If set, forces the complete rebuild of the native application. * `--release` - If set, produces a release build. Otherwise, produces a debug build. When set, you must also specify the `--key-store-*` options. * `--key-store-path` - Specifies the file path to the keystore file (P12) which you want to use to code sign your APK. You can use the `--key-store-*` options along with `--release` to produce a signed release build. You need to specify all `--key-store-*` options.