You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/en/docs/refguide/general/mx-command-line-tool/app.md
+48-49Lines changed: 48 additions & 49 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,19 +1,19 @@
1
1
---
2
2
title: "App Commands"
3
-
url: /refguide/mx-command-line-tool/app
3
+
url: /refguide/mx-command-line-tool/app/
4
4
weight: 10
5
5
description: "Describes the app-related commands for the mx command-line tool."
6
6
---
7
7
8
8
## Introduction
9
9
10
-
The commands in this group are related to Mendix app creation, checking, versioning, and conversion.
10
+
The commands in this group are related to Mendix app creation, checking, versioning, and conversion tasks.
11
11
12
-
Typically, these commands require a path to the *.mpr* file as a parameter.
12
+
Most commands require a path to the *.mpr* file as a parameter.
13
13
14
14
## mx create-project Command {#create-project}
15
15
16
-
The `mx create-project` command creates a new app in Studio Pro. The app version depends on the version the tool was bundled with. For example, if you are using the mx tool for Studio Pro 11.0.0, `mx create project` will create a new app in that version.
16
+
The `mx create-project` command creates a new app in Studio Pro. The app version depends on the version the tool was bundled with. For example, if you are using the mx tool for Studio Pro 11.0.0, `mx create project` will create a new app in that version.
17
17
18
18
### Usage
19
19
@@ -26,11 +26,11 @@ These are the `OPTIONS`:
26
26
|`--app-name`| App | Assigns the specified app name to the app. |
27
27
|`--help`|| Shows help for the `mx create-project` command and exits. |
28
28
|`--language-code`| en_US | The default language of the app. |
29
-
|`--use-mpr-format-v1`| MPRv2 | If specified, the app is created in MPRv1 format (otherwise, with MPRv2). |
29
+
|`--use-mpr-format-v1`| MPRv2 | If specified, the app is created in MPRv1 format (otherwise, with MPRv2). |
30
30
|`--output-dir`| Current directory | The directory in which to create the app. |
31
-
|`--sprintr-app-id`| Optional | Associates the app [feedback features](/developerportal/app-insights/feedback/) with the provided [app](/developerportal/#my-apps) in **Apps**. The value is a GUID. When accessing the app in [Apps](https://sprintr.home.mendix.com/), this ID can be found in the browser's URL (for example, `1a428ea7-b00e-4166-9b23-20b7be88a40e`). |
31
+
|`--sprintr-app-id`| Optional | Associates the app [feedback features](/developerportal/app-insights/feedback/) with the provided [app](/developerportal/#my-apps) in **Apps**. The value is a GUID. You can find this ID in the browser URL when you access the app in [Apps](https://sprintr.home.mendix.com/) (for example, `1a428ea7-b00e-4166-9b23-20b7be88a40e`). |
32
32
33
-
`TEMPLATE-MPK-FILE` is an optional path to a Mendix app package *.mpk* file. If this argument is omitted, the app is created with a default empty project template.
33
+
`TEMPLATE-MPK-FILE` is an optional path to a Mendix app package *.mpk* file. If omitted, the command creates the app with a default empty project template.
34
34
35
35
### Examples
36
36
@@ -54,7 +54,7 @@ These are the return codes:
54
54
55
55
## mx show-version Command {#show-version}
56
56
57
-
The `mx show-version` command reports which version of Studio Pro was used last time the app was opened.
57
+
The `mx show-version` command reports which version of Studio Pro last opened the app.
{The `mx show-java-version` command reports what the configured Java version of the app is.
98
+
The `mx show-java-version` command reports the configured Java version of the app.
99
99
100
-
The input is a single MPR file.
100
+
The input is a single *.mpr* file.
101
101
102
102
{{% alert color="info" %}}
103
-
The MPR file must be the same version as mx.
103
+
The *.mpr* file must be the same version as the mx tool.
104
104
{{% /alert %}}
105
105
106
106
### Usage
@@ -113,24 +113,24 @@ For `INPUT`, enter an *.mpr* file.
113
113
114
114
### Examples
115
115
116
-
Examples of commands are described in the table below:
116
+
These are example commands:
117
117
118
118
| Example | Result |
119
119
| --- | --- |
120
120
|`mx show-java-version C:\Mendix\App1\App1.mpr`| Displays the configured Java version of the app. |
121
121
122
122
### Return Codes
123
123
124
-
Return codes are described in the table below:
124
+
These are the return codes:
125
125
126
126
| Return Code | Description |
127
127
| --- | --- |
128
-
|0| The command ran successfully. |
129
-
|1| The command failed. For example because the *.mpr* file could not be found. |
128
+
|`0`| The command ran successfully. |
129
+
|`1`| The command failed, for example, because the *.mpr* file could not be found. |
130
130
131
131
## mx convert Command {#convert}
132
132
133
-
The `mx convert` command converts the*.mpk* file (or files) of the app (or apps) to a specific Studio Pro version. For example, if you are using the mx command-line tool for Studio Pro 11.0.0, `mx convert` will convert the app to that version.
133
+
The `mx convert` command converts app*.mpk* file (or files) of the app (or apps) to a specific Studio Pro version. For example, the mx command-line tool for Studio Pro 11.0.0 converts apps to version 11.0.0.
134
134
135
135
The input can be a single file, directory, or multiple files.
136
136
@@ -148,24 +148,24 @@ These are the `OPTIONS`:
148
148
149
149
| Option | Shortcut | Result |
150
150
| --- | --- | --- |
151
-
|`--help`|| Shows help for the `mx convert`` command and exits. |
152
-
|`--in-place`|`-p`| Converts the current app directory. Use this option to convert a folder containing a Mendix app. Otherwise, `mx convert`will convert*.mpk* files. |
153
-
|`--skip-error-check`|`-s`| Does not check for errors. Use this option to disable app error-checking during the conversion. When omitted, the tool will report on the number of errors, warnings, and deprecations in the app and do the conversion. |
151
+
|`--help`|| Shows help for the `mx convert` command and exits. |
152
+
|`--in-place`|`-p`| Converts the current app directory. Use this option to convert a folder containing a Mendix app. Otherwise, `mx convert`converts*.mpk* files. |
153
+
|`--skip-error-check`|`-s`| Does not check for errors. Use this option to disable app errorchecking during conversion. When omitted, the tool reports the number of errors, warnings, and deprecations in the app before converting it. |
154
154
155
155
For `INPUT...`, enter one or more *.mpk* files or one directory that needs to be converted.
156
156
157
-
For `OUTPUT`, enter the output location for the converted results. Please note the following:
157
+
For `OUTPUT`, enter the output location for the converted results. Note the following:
158
158
159
-
* When `INPUT...` is a single file, `OUTPUT` can be a single file or directory; otherwise, `OUTPUT` must be a directory
160
-
* When using the `--in-place` option, the `INPUT...` folder will also be used as the `OUTPUT` folder, so you do not need to specify a separate `OUTPUT` folder
159
+
* When `INPUT...` is a single file, `OUTPUT` can be a single file or directory. Otherwise, `OUTPUT` must be a directory.
160
+
* When using the `--in-place` option, the `INPUT...` folder is also used as the `OUTPUT` folder, so you do not need to specify a separate `OUTPUT` folder.
161
161
162
162
### Examples
163
163
164
164
These are example commands:
165
165
166
166
| Example | Result |
167
167
| --- | --- |
168
-
|`mx convert --in-place C:\MxProjects\App-main`| Converts the app in folder *C:\MxProjects\App-main* to the specific Studio Pro version that the mx tool is bundled with. |
168
+
|`mx convert --in-place C:\MxProjects\App-main`| Converts the app in folder *C:\MxProjects\App-main* to the Studio Pro version that the mx tool is bundled with. |
169
169
|`mx convert C:\Mendix\App1.mpk C:\Mendix\App2.mpk C:\Mendix\ConvertedProjects\`| Converts the *App1.mpk* and *App2.mpk* app packages that are in the *C:\\Mendix\\* folder and puts the results in the *C:\\Mendix\\ConvertedProjects\\* folder. |
170
170
|`mx convert --skip-error-check C:\Mendix\Packages\ C:\Mendix\ConvertedPackages\`| Converts all the app packages in the *C:\\Mendix\\Packages\\* folder to the *C:\\Mendix\\ConvertedPackages\\* folder without checking for errors. |
171
171
@@ -182,7 +182,7 @@ These are the return codes:
182
182
183
183
## mx check Command {#check}
184
184
185
-
The `mx check` command checks the app *.mpr* file for issues such as errors, warnings, deprecations, or performance recommendations.
185
+
The `mx check` command checks the app *.mpr* file for errors, warnings, deprecations, and performance recommendations.
186
186
187
187
{{% alert color="info" %}}
188
188
The *.mpr* file must be the same version as the mx tool.
@@ -201,15 +201,15 @@ These are the `OPTIONS`:
201
201
|`--help`|| Shows help for the `mx check` command and exits. |
202
202
|`--warnings`|`-w`| Includes warnings in the output. |
203
203
|`--deprecations`|`-d`| Includes deprecations in the output. |
204
-
|`--performance`|`-p`| Includes performance checks in the output (performance recommendations are only outputted if there are no errors). |
204
+
|`--performance`|`-p`| Includes performance checks in the output. Performance recommendations are only included if there are no errors. |
205
205
206
206
{{% alert color="info" %}}
207
207
Errors in the *.mpr* are always reported.
208
208
{{% /alert %}}
209
209
210
210
For `INPUT`, enter a single *.mpr* file.
211
211
212
-
You can optionally specify the path to an exported suppress-warnings (JSON) file. This means`mx check -w`will use the list of suppressed warnings in the JSON file, instead of the default behavior (which is to read from the *project-settings.user.json* file in the app directory).
212
+
You can optionally specify the path to an exported suppress-warnings (JSON) file. If specified,`mx check -w`uses the list of suppressed warnings in the JSON file instead of reading from the *project-settings.user.json* file in the app directory.
213
213
214
214
### Examples
215
215
@@ -220,8 +220,8 @@ These are example commands:
220
220
|`mx check --help`| Displays the help text for the check command. |
221
221
|`mx check C:\MxProjects\App-main\App-main.mpr`| Checks the app at *C:\MxProjects\App-main\App-main.mpr* for errors. |
222
222
|`mx check C:\MxProjects\App-main\App-main.mpr -p`| Checks the app at *C:\MxProjects\App-main\App-main.mpr* for errors and performance recommendations. |
223
-
|`mx check C:\MxProjects\App-main\App-main.mpr --warnings --deprecations`| Checks the app at *C:\MxProjects\App-main\App-main.mpr* for errors, warnings, and deprecations. Suppressed warnings will be read from the *project-settings.user.json* file within the app directory. |
224
-
|`mx check C:\MxProjects\App-main\App-main.mpr c:\MxFiles\my-exported-suppressed-warnings.json --warnings`| Checks the app at *C:\MxProjects\App-main\App-main.mpr* for errors and warnings. Suppressed warnings will be read from the JSON file *my-exported-suppressed-warnings.json*. |
223
+
|`mx check C:\MxProjects\App-main\App-main.mpr --warnings --deprecations`| Checks the app at *C:\MxProjects\App-main\App-main.mpr* for errors, warnings, and deprecations. Suppressed warnings are read from the *project-settings.user.json* file in the app directory. |
224
+
|`mx check C:\MxProjects\App-main\App-main.mpr c:\MxFiles\my-exported-suppressed-warnings.json --warnings`| Checks the app at *C:\MxProjects\App-main\App-main.mpr* for errors and warnings. Suppressed warnings are read from the JSON file *my-exported-suppressed-warnings.json*. |
225
225
|`mx check C:\MxProjects\App-main\App-main.mpr -w -d -p`| Checks the app at *C:\MxProjects\App-main\App-main.mpr* for errors, warnings, deprecations, and performance recommendations. |
226
226
227
227
### Return Codes
@@ -236,20 +236,19 @@ These are the return codes:
236
236
|`4`| Deprecations were found. |
237
237
|`8`| Performance recommendations were found. |
238
238
239
-
Those values are logically `OR`combined to indicate when there are a mix of errors, warnings, deprecations, or performance recommendations.
239
+
These values are logically combined with `OR` to indicate a mix of errors, warnings, deprecations, or performance recommendations.
240
240
241
241
For example:
242
242
243
-
*`3` if errors and warnings found
244
-
*`7` if errors, warnings, and deprecations found
243
+
*`3` if errors and warnings are found
244
+
*`7` if errors, warnings, and deprecations are found
245
245
246
246
## mx translate Command {#translate}
247
247
248
-
The `mx translate` command allows you to export and import all translatable texts included in your Mendix application.
249
-
This command is currently in public beta.
248
+
The `mx translate` command exports and imports all translatable texts in your Mendix app. This command is currently in public beta.
250
249
251
250
{{% alert color="warning" %}}
252
-
A limitation of this command is that the default behavior is to exclude Marketplace modules from the exported texts. When they are updated, the texts from a previous export will not be imported correctly. Your translations will also be lost when importing a new version of a Marketplace module.
251
+
By default, this command excludes Marketplace modules from the exported texts. When Marketplace modules are updated, texts from a previous export will not import correctly, and your translations will be lost when you import a new version of a Marketplace module.
253
252
{{% /alert %}}
254
253
255
254
{{% alert color="info" %}}
@@ -266,21 +265,22 @@ These are the required parameters:
266
265
267
266
| Option | Shortcut | Result |
268
267
| --- | --- | --- |
269
-
|`--import-translations`|`-i`| Imports the translations from the directory specified as the translation directory. This is required if export is not specified. |
270
-
|`--export-translations`|`-e`| Exports the translations from the directory specified as the translation directory. This is required if import is not specified. |
271
-
|`--type`|`-t`| Specifies the file type to use. This can be either `xlsx` or `po`. |
272
-
|`--source-language-code`|`-s`| Specifies the ISO 639 language code to use (for example,`en_US` as the source language to translate from). This will be used as the text that needs to be translated. |
268
+
|`--import-translations`|`-i`| Imports translations from the specified translation directory. This is required if `--export-translations` is not specified. |
269
+
|`--export-translations`|`-e`| Exports translations to the specified translation directory. This is required if `--import-translations` is not specified. |
270
+
|`--type`|`-t`| Specifies the file type. This can be either `xlsx` or `po`. |
271
+
|`--source-language-code`|`-s`| Specifies the ISO 639 language code (for example,`en_US`) to use as the source language. |
273
272
274
273
For `PROJECT`, enter a single *.mpr* file.
275
-
For `TRANSLATION_PATH`, enter a filepath to import or export the translation files from.
274
+
275
+
For `TRANSLATION_PATH`, enter a file path to import or export the translation files.
276
276
277
277
These are the `OPTIONS`:
278
278
279
279
| Option | Shortcut | Result |
280
280
| --- | --- | --- |
281
-
|`--force-import`|`-f`| Accepts some warnings and errors and tries to continue the import process. |
282
-
|`--loose-version-check`|`-l`| Converts the project to the version of the mx.exe, if it is a different version. |
283
-
|`--include-marketplace-modules`|`-m`|By default, the export does not include Marketplace modules. Adding this option will include them in the output. |
281
+
|`--force-import`|`-f`| Accepts some warnings and errors and continues the import process. |
282
+
|`--loose-version-check`|`-l`| Converts the project to the version of the mx.exe if the versions differ. |
283
+
|`--include-marketplace-modules`|`-m`|Includes Marketplace modules in the output. By default, Marketplace modules are excluded. |
The `mx sync-java-dependencies` command synchronizes the managed Java dependencies that are configured in the modules of the project.
312
-
This results in the corresponding .*jar* files being added to the `vendorlib` directory in the project root.
311
+
The `mx sync-java-dependencies` command synchronizes the managed Java dependencies configured in the project modules. This adds the corresponding *.jar* files to the `vendorlib` directory in the project root.
313
312
314
-
The input is a single .*mpr* file.
313
+
The input is a single *.mpr* file.
315
314
316
315
{{% alert color="info" %}}
317
-
The .*mpr* file must be the same version as mx.
316
+
The *.mpr* file must be the same version as the mx tool.
318
317
{{% /alert %}}
319
318
320
319
### Usage
@@ -339,5 +338,5 @@ These are the return codes:
339
338
340
339
| Return Code | Description |
341
340
| --- | --- |
342
-
|0| The command ran successfully. |
343
-
|1| The command failed. For example, because the *.mpr* file could not be found. |
341
+
|`0`| The command ran successfully. |
342
+
|`1`| The command failed, for example, because the *.mpr* file could not be found. |
0 commit comments