@lionweb/cli v0.6.10
The cli package
This package exposes an executable for use with a CLI. It can be used as follows:
$ npx @lionweb/cli <command> <arguments>Just running
$ npx @lionweb/cliproduces information about which commands are available.
This CLI utility does not perform any explicit validation apart from the file at the given path existing and being valid JSON. It does some implicit validation as it can error out on incorrect serializations.
Sorting a serialization chunk
Run the following command to sort a serialization chunk (e.g.):
npx @lionweb/cli sort ../artifacts/chunks/languages/lioncore.jsonSorting a serialization chunk means the following:
- All nodes sorted by ID.
- For all nodes, their properties, containments, and references sorted by key (from the meta-pointer),
- All containments and references sorted by ID.
The sorting produces a serialization chunk that's also aligned on JSON-level with the specification. That means that key-value pairs appear in precisely the same order as they do in the specification, and that missing key-value pairs are put in and get their default values.
Changelog
0.6.10
- (Depend on
@lionweb/coreand@lionweb/utilitiesversion 0.6.9.) - Use the
AggregatingSimplisticHandlerto report on language deserialization problems.
0.6.9
- (Depend on
@lionweb/coreand@lionweb/utilitiesversion 0.6.8.)
0.6.8
- (Depend on
@lionweb/coreand@lionweb/utilitiesversion 0.6.7.)
0.6.7
- (Depend on
@lionweb/coreand@lionweb/utilitiesversion 0.6.6.)
0.6.6
- TS types generator now generates 1 file per language.
The output directory will be
<languages serialization chunk's file name>_gen/. - The
infer-languagecommand has been renamed toinfer-languages(without deprecated alias).
0.6.5
- Extend metrics functionality.
0.6.4
- Add a command
infer-languagethat infers a language from the given serialization chunk.
0.6.3
- Add a command
measurethat computes metrics.
0.6.2
- Expose diffing functionality from
@lionweb/validation
0.6.1
- Fix that
@lionweb/validationwas not specified as a (non-dev) dependency.
0.6.0
- Change the
diagramcommand to output PlantUML and Mermaid diagram files per language. - Add a
validationcommmand to validate JSON files as serialization chunks. - Remove the shortening functionality from
extract. - Rename the
extractcommand →sort, and remove the textualization for chunks that are the serialization of languages. - Textualizing a serialization chunk of languages will use the LionCore/M3-specific syntax unless the flag
--languagesAsRegularis an argument. - Add a
repaircommand. - Add a
textualizecommand – that's optionally language-aware – to render a JSON serialization chunk as pure text.
0.5.0
This is the first version corresponding to a release of LionWeb (version: 2023.1) as a whole.
- Make language-related functionality "multi-lingual", i.e. a serialization chunk can contain multiple
Languages.- (Languages will be sorted by name.)
- Improve extraction functionality: only catch JSON-parsing exceptions.
- Configure single entrypoint named
lionweb-cli.
No changelog has been kept for previous versions, regardless of whether these were published or not.
Development
Build the executable from source as follows:
$ npm run build1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago