mirror of
https://gitlab.com/openstapps/openstapps.git
synced 2026-01-08 06:22:53 +00:00
docs: adjust readme to reflect changes
This commit is contained in:
20
README.md
20
README.md
@@ -26,15 +26,17 @@ Add `@validatable` to the Typedoc comment of the types that you want to convert
|
|||||||
The command `openstapps-core-tools` can then be called using these arguments:
|
The command `openstapps-core-tools` can then be called using these arguments:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
node_modules/.bin/openstapps-core-tools schema <srcPath> <schemaPath>
|
openstapps-core-tools schema <srcPath> <schemaPath>
|
||||||
```
|
```
|
||||||
|
|
||||||
where:
|
where:
|
||||||
- `<srcPath>` is path to the project (where used `*.ts` files are, e.g. `src/core`,
|
- `<srcPath>` is path to the project (where used `*.ts` files are, e.g. `src/core`,
|
||||||
- `<schemaPath>` is directory to save output files to, e.g. `lib/schema`.
|
- `<schemaPath>` is directory to save output files to, e.g. `lib/schema`.
|
||||||
|
|
||||||
Complete command with the example arguments is then:
|
Complete command with the example arguments is then:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
node_modules/.bin/openstapps-core-tools schema src/core lib/schema
|
openstapps-core-tools schema src/core lib/schema
|
||||||
```
|
```
|
||||||
|
|
||||||
Inside of a script in `package.json` or if the npm package is installed globally, the tool `stapps-convert` can be called without its local path (`node_modules/.bin`):
|
Inside of a script in `package.json` or if the npm package is installed globally, the tool `stapps-convert` can be called without its local path (`node_modules/.bin`):
|
||||||
@@ -105,16 +107,18 @@ Where `errorNames` holds the string values of the name property of the expected
|
|||||||
The command `openstapps-core-tools` can then be called using these arguments:
|
The command `openstapps-core-tools` can then be called using these arguments:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
node_modules/.bin/openstapps-core-tools validate <schemaPath> <testPath> [reportPath]
|
openstapps-core-tools validate <schemaPath> <testPath> [reportPath]
|
||||||
```
|
```
|
||||||
|
|
||||||
where:
|
where:
|
||||||
- `<schemaPath>` is a directory where JSON schema files are, e.g. `lib/schema`,
|
- `<schemaPath>` is a directory where JSON schema files are, e.g. `lib/schema`,
|
||||||
- `<testPath>` is a directory where test files are, e.g. `src/test/resources`,
|
- `<testPath>` is a directory where test files are, e.g. `src/test/resources`,
|
||||||
- `[reportPath]` is a file where the HTML report of the validation will be saved to, e.g. `report.html` (optional argument - if it's not provided no report will be written).
|
- `[reportPath]` is a file where the HTML report of the validation will be saved to, e.g. `report.html` (optional argument - if it's not provided no report will be written).
|
||||||
|
|
||||||
Command with the example arguments is then for example:
|
Command with the example arguments is then for example:
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
node_modules/.bin/openstapps-core-tools validate lib/schema src/test/resources
|
openstapps-core-tools validate lib/schema src/test/resources
|
||||||
```
|
```
|
||||||
|
|
||||||
Inside of a script in `package.json` or if the npm package is installed globally, the tool `openstapps-validate` can be called without its local path (`node_modules/.bin`):
|
Inside of a script in `package.json` or if the npm package is installed globally, the tool `openstapps-validate` can be called without its local path (`node_modules/.bin`):
|
||||||
@@ -123,14 +127,12 @@ Inside of a script in `package.json` or if the npm package is installed globally
|
|||||||
openstapps-core-tools validate lib/schema src/test/resources report.html
|
openstapps-core-tools validate lib/schema src/test/resources report.html
|
||||||
```
|
```
|
||||||
|
|
||||||
## Generate documentation for routes
|
## Generate documentation for routes
|
||||||
|
|
||||||
To generate a documentation for the routes use the following command in the root directory of your StAppsCore.
|
To generate a documentation for the routes use the following command.
|
||||||
|
|
||||||
The generator relies on dynamic imports and must therefore be run this way.
|
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
node --require ts-node/register node_modules/@openstapps/core-tools/src/cli.ts routes PATH/TO/ROUTES.md
|
openstapps-core-tools routes PATH/TO/CORE PATH/TO/ROUTES.md
|
||||||
```
|
```
|
||||||
|
|
||||||
## Pack definitions and implementations
|
## Pack definitions and implementations
|
||||||
|
|||||||
Reference in New Issue
Block a user