Skip to content

Commit

Permalink
Merge pull request #395 from SAP/updateddocs23
Browse files Browse the repository at this point in the history
updated after UA review
  • Loading branch information
ShimiT committed May 23, 2019
2 parents 51951a6 + e0df7db commit 63d202c
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 19 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,20 +12,20 @@

#### Multi-Target Application

Before using this package, be sure you are familiar with the multi-target application concept and terminology. For background and detailed information, see the [Multi-Target Application Model](https://www.sap.com/documents/2016/06/e2f618e4-757c-0010-82c7-eda71af511fa.html) guide.
Before using this package, make sure that you are familiar with the multi-target application concept and terminology. For background and detailed information, see the [Multi-Target Application Model](https://www.sap.com/documents/2016/06/e2f618e4-757c-0010-82c7-eda71af511fa.html) guide.

#### The Cloud MTA Build Tool overview
The Cloud MTA Build Tool is a standalone command-line tool that builds a deployment-ready
multi-target application (MTA) archive `.mtar` file from the artifacts of an MTA project according to the project’s MTA
development descriptor (`mta.yaml` file) or from module build artifacts according to the MTA deployment descriptor (`mtad.yaml` file). Also it provides commands for runing intermediate build process steps, for example, the mta.yaml file validations,building a single module according to configurations in the development descriptor, generating deployment descriptor, etc.
multitarget application (MTA) archive `.mtar` file from the artifacts of an MTA project according to the project’s MTA
development descriptor (`mta.yaml` file) or from module build artifacts according to the MTA deployment descriptor (`mtad.yaml` file). Also, it provides commands for running intermediate build process steps; for example, the `mta.yaml` file validations, building a single module according to the configurations in the development descriptor, generating the deployment descriptor, and so on.


><b>For more information, see the the [Cloud MTA Build Tool user guide](https://sap.github.io/cloud-mta-build-tool/)</b>
><b>For more information, see the [Cloud MTA Build Tool user guide](https://sap.github.io/cloud-mta-build-tool/)</b>
## Contributions

Contributions are greatly appreciated.
If you want to contribute, please follow [the guidelines](docs/docs/process.md).
If you want to contribute, follow [the guidelines](docs/docs/process.md).

## Support

Expand Down
10 changes: 5 additions & 5 deletions docs/docs/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ To use a non-default builder for a module, specify its name in the builder param

#### Configuring build order
You can define the dependencies between modules to ensure that they are built in a certain order. In addition, you can use the build results of one module to build another module.
Also you can can configure a build step that is performed before building any of the modules.
Also you can can configure build steps that are performed before building any of the modules.

##### Defining module build order
To define the build order of modules, in the `mta.yaml` file, add a `requires` section under the `build-parameters` section of the dependent module; that is, a module that should be built only after building another required module. Then specify the required module name as a property of the dependent module’s `requires` section.
Expand Down Expand Up @@ -60,7 +60,7 @@ modules:
> **_CAUTION:_** Cyclical dependencies are not allowed. If such dependencies are found, the build fails.
<br>
##### Using build results for building another `modulecopy` artifact
##### Using build results for building another module

If you want to use the build results of module B for building module A, modify the `requires` section as follows:

Expand Down Expand Up @@ -91,7 +91,7 @@ modules:

#### Configuring a global build

If you want to run a builder process before running builders of the specific modules, define it by using the `build-parameters` section at the global level in the `mta.yaml` file as follows:
If you want to run addtional build steps before running builders of the specific modules, define it by using the `build-parameters` section at global level in the `mta.yaml` file as follows:


```yaml
Expand Down Expand Up @@ -132,7 +132,7 @@ modules:
...

```
> **_NOTE:_** Only the following build parameters are considered when configuring a builder at the "before-all" level: <li>`timeout`<li>`commands` (for the `custom` builder only)<li> `fetcher-opts` (for the `fetcher` builder only)
> **_NOTE:_** Only the following build parameters are considered when configuring a builder at the global level: <li>`timeout`<li>`commands` (for the `custom` builder only)<li> `fetcher-opts` (for the `fetcher` builder only)
<br>
#### Configuring the `fetcher` builder
Expand Down Expand Up @@ -202,7 +202,7 @@ For example:

#### Configuring and packaging modules according to target platforms

If you want to control which modules should be packaged into a multitarget application archive for a specific platform during a multitarget application build, use the `supported-platforms` build parameter as follows:
If you want to control which modules should be packaged into a multitarget application archive for a specific platform, use the `supported-platforms` build parameter as follows:

```yaml

Expand Down
18 changes: 11 additions & 7 deletions docs/docs/migration.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@
If you have previously used the [Multitarget Application Archive Builder](https://help.sap.com/viewer/58746c584026430a890170ac4d87d03b/Cloud/en-US/ba7dd5a47b7a4858a652d15f9673c28d.html) for building your MTA projects, you should be aware of the differences between the tools.


#### Features that handled differently in the Cloud MTA Build Tool
#### Features that are handled differently in the Cloud MTA Build Tool

* For building an MTA project, the Cloud MTA build Tool uses `GNU Make` technology. Therefore, you should have `GNU Make` installed in your build environmnet. Please read the correponding sections for more information about [`GNU Make` installation](makefile.md) and [commands for building a project](usage.md#how-to-build-an-mta-archive-from-the-project-sources).
<li> The Cloud MTA build Tool uses `GNU Make` technology for building an MTA project. Therefore, you should have `GNU Make` installed in your build environmnet.

For more information, see sections [`GNU Make` installation](makefile.md) and [commands for building a project](usage.md#how-to-build-an-mta-archive-from-the-project-sources).
&nbsp;
* Packaging of HTML5 modules in `deploy_mode=html5-repo`

<li> Packaging of HTML5 modules in `deploy_mode=html5-repo`
You need to update your `mta.yaml` file to exclude `html5` modules from the resulting MTA archive. In order to do that, add the following to the `build-parameters` section for each module of this type:

```yaml
Expand All @@ -15,15 +18,16 @@ You need to update your `mta.yaml` file to exclude `html5` modules from the resu
supported-platforms: []
```
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; For more information about the `supported-platforms` build parameter, see [Configuring and Packaging Modules According to Target Platforms](configuration.md#configuring-and-packaging-modules-according-to-target-platforms).
&nbsp;
* The following `build-parameters` are not supported by the Cloud MTA Build Tool: <ul><li>`npm-opts`<li>`grunt-opt`<li>`maven-opts`</ul>
&nbsp;&nbsp;

<li> The following `build-parameters` are not supported by the Cloud MTA Build Tool: <ul><li>`npm-opts`<li>`grunt-opt`<li>`maven-opts`</ul>

If you need to change the default build behavior defined for the correponding builder, see [configure `custom` builder](configuration.md#configuring-the-custom-builder). For a complete list of available builders and their default behaviors, see [Builders execution commands](https://github.com/SAP/cloud-mta-build-tool/blob/master/configs/builder_type_cfg.yaml).
If you need to change the default build behavior defined for the corresponding builder, see [configure `custom` builder](configuration.md#configuring-the-custom-builder). For a complete list of available builders and their default behaviors, see [Builders execution commands](https://github.com/SAP/cloud-mta-build-tool/blob/master/configs/builder_type_cfg.yaml).
&nbsp;

#### New features in the Cloud MTA Build Tool

* In addition to configuring build behaviour in `mta.yaml`, you can configure build process of the specific module or the whole project in the `Makefile.mta` file that you can generate the file using [`mbt init` command](usage.md#cloud-mta-build-tool-commands). The generated file contains default configurations for buidling MTA project according to our best practices.
* In addition to configuring the build behaviour in `mta.yaml`, you can configure build process of the specific module or the whole project in the `Makefile.mta` file, which you can generate the file using [`mbt init` command](usage.md#cloud-mta-build-tool-commands). The generated file contains the default configurations for buidling the MTA project according to our best practices.
&nbsp;&nbsp;
* If you want to run a builder process before running builders of the specific modules, define it using [global `before-all` build parameters](configuration.md#configuring-global-build).
&nbsp;
Expand Down
2 changes: 1 addition & 1 deletion docs/docs/performance.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@


TBD
Under construction
3 changes: 2 additions & 1 deletion docs/docs/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ make -f Makefile.mta p=cf

| Command | Usage &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | Description
| ------ | -------- | ----------
| init | `mbt init <flags>` | Generates the `Makefile.mta` file according to the MTA descriptor (`mta.yaml` file). <br> The `make` command uses the generated `Makefile.mta` file to package the MTA project. <br> Use the `mbt init` command with the following flags:<br><ul><li>`-s (--source)` is the path to the MTA project; the current path is set as the default.<br> Example: `mbt init -s C:/TestProject` <li>`-t (--target)` is the path to the generated `Makefile` folder; the current path is set as the default. <br> Example: `mbt init -t C:/TestFolder`<li>`-m (--mode)` is the mode of the `Makefile` generation; supported values are `default` and `verbose`.<br> Example: `mbt init -m default`
| init | `mbt init <flags>` | Generates the `Makefile.mta` file according to the MTA descriptor (`mta.yaml` file). <br> The `make` command uses the generated `Makefile.mta` file to package the MTA project. <br> Use the `mbt init` command with the following flags:<br><ul><li>`-s (--source)` is the path to the MTA project; the current path is set as the default.<br> Example: `mbt init -s C:/TestProject` <li>`-t (--target)` is the path to the generated `Makefile` folder; the current path is set as the default. <br> Example: `mbt init -t C:/TestFolder`

<br>
#### Make commands
Expand All @@ -53,6 +53,7 @@ Use the `make` command to package the MTA project with the following parameters:

| Parameter | Type | Mandatory&nbsp;/<br>Optional | Description&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; | Examples
| ----------- | ------ | ------- | ---------- | --------------------------------------
| `-f <path to Makefile.mta>` | string | Mandatory | The path to the Makefile.mta file that contains build configurations | `make -f Makefile.mta p=cf`
| `p` | string | Mandatory | The name of the deployment platform. <br>The supported deployment platforms are: <ul><li>`cf` for SAP Cloud Platform Cloud Foundry environment <li>`neo` for the SAP Cloud Platform Neo environment <li>`xsa` for the SAP HANA XS advanced model |`make -f Makefile.mta p=cf`
| `t` | string | Optional | The folder for the generated `MTAR` file. The default value is the current folder. If this parameter is not provided, the `MTAR` file is saved in the `mta_archives` subfolder of the current folder. If the parameter is provided, the `MTAR` file is saved in the root of the folder provided by the argument. | `make -f Makefile.mta p=cf t=C:\temp`
| `mtar` | string | Optional | The file name of the generated archive file. If this parameter is omitted, the file name is created according to the following naming convention: <br><br> `<mta_application_ID>_<mta_application_version>.mtar` <br><br> If the parameter is provided, but does not include an extension, the `.mtar` extension is added. | `make -f Makefile.mta p=cf mtar=myMta`<br><br> `make -f Makefile.mta p=cf mtar=myMta.mtar`
Expand Down

0 comments on commit 63d202c

Please sign in to comment.