lutaml 0.11.3 → 0.11.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: b816c810e9f0dcc23cd37af5a3520d3f3743710501e4ad4924fd5c9ab5dcf286
4
- data.tar.gz: 585f1009c6d073c5173a9559c4f9ae96f6aeb5ebf8f03d8f7a211c330cac9d4a
3
+ metadata.gz: 0f34bf66cbe8f9fa2f898f3c5afcdf099ed1603883445cb07a42887e0d8c7e35
4
+ data.tar.gz: 7f32c3792d828d9c5303c30395e80f0a45e0d7da13b2e095b8aeed93052ab1b0
5
5
  SHA512:
6
- metadata.gz: c8f7eba7c819f9098c2b722828472c679fd2365068e1d1ea3e418c76ff88c3f028cd933c2f9663fe567c4b8438feafdbdb78de69a9d7a40cba2a0b7658939887
7
- data.tar.gz: bb4992e75e8c26ad47b1adcc11015bf4f3e08b584815b30c0d341a83dbc547d371b7559aacc3c3c4bdd15f75fe09dba8cce8731f4684f327ed09bdd0b8c01cec
6
+ metadata.gz: 923866c877f40ab1937d57c075c7c8a212998a128cd6438ab25688041990a37f8bf06ff532c8615e08360ef71570de746127142fb239c0cc697d57a09cdb7b1a
7
+ data.tar.gz: 77586b69cc36d6ecb67c2ee83a04671bf4fdc0e467594b92aaede202da308c9a8f4fadc5b28ccb6caa4d95a8d0e764bfed5fda91d19423cfe9b8163825ba8650
@@ -4,7 +4,6 @@ name: release
4
4
 
5
5
  permissions:
6
6
  contents: write
7
- packages: write
8
7
  id-token: write
9
8
 
10
9
  on:
@@ -12,24 +11,27 @@ on:
12
11
  inputs:
13
12
  next_version:
14
13
  description: |
15
- Next release version. Possible values: x.y.z, major, minor, patch (or pre|rc|etc).
16
- Also, you can pass 'skip' to skip 'git tag' and do 'gem push' for the current version
14
+ Next release version. Possible values: x.y.z, major, minor, patch or pre|rc|etc
17
15
  required: true
18
16
  default: 'skip'
19
- acknowledge_breaking_in_patch:
20
- description: "Skip the release-breaking-check guard"
21
- required: false
22
- default: "true"
23
17
  repository_dispatch:
24
18
  types: [ do-release ]
25
19
 
20
+ # One release at a time: concurrent bumps race the version commit
21
+ # and half-published gems are worse than a queued release.
22
+ concurrency:
23
+ group: release
24
+ cancel-in-progress: false
25
+
26
26
  jobs:
27
27
  release:
28
28
  uses: metanorma/ci/.github/workflows/rubygems-release.yml@main
29
29
  with:
30
30
  next_version: ${{ github.event.inputs.next_version }}
31
- acknowledge_breaking_in_patch: ${{ github.event.inputs.acknowledge_breaking_in_patch == 'true' }}
32
- gated: false
33
31
  secrets:
34
- rubygems-api-key: ${{ secrets.LUTAML_CI_RUBYGEMS_API_KEY }}
35
- pat_token: ${{ secrets.GITHUB_TOKEN }}
32
+ # OMIT rubygems-api-key: metanorma/ci switches to OIDC Trusted Publishing
33
+ # when the secret is empty (USE_OIDC = rubygems-api-key == ''). Trusted
34
+ # Publishing is already configured for the lutaml gems on rubygems.org.
35
+ # The removed `gated` input no longer exists in the reusable workflow
36
+ # and made every dispatch fail at startup.
37
+ pat_token: ${{ secrets.LUTAML_CI_PAT_TOKEN }}
data/README.adoc CHANGED
@@ -51,56 +51,19 @@ bundle exec jekyll serve
51
51
 
52
52
  === Parsing
53
53
 
54
- The `Lutaml::Parser.parse` method provides a single point of entry for parsing
55
- data model files, including:
56
-
57
- * EXPRESS files with `.exp` extension
58
- * YAML Compressed EXPRESS CACHE files
59
- * QEA files with `.qea` extension (Enterprise Architect databases)
60
- * XMI files with `.xmi` extension
61
- * XML files with `.xml` extension
62
- * LutaML files with `.lutaml` extension
63
-
64
- Depending on the input file type, `Lutaml::Parser.parse` returns:
65
-
66
- * `Expressir::Express::Model::Repository` for EXPRESS files
67
- * `Expressir::Express::Cache` for EXPRESS CACHE files
68
- * `Lutaml::Uml::Document` for QEA files (returned as single-element array)
69
- * `Lutaml::Uml::Document` for XMI files
70
- * `Lutaml::Uml::Document` for XML files
71
- * `Lutaml::Uml::Document` for LutaML files
72
-
73
- Examples to use the `Lutaml::Parser.parse`:
54
+ Parse LutaML Model Language (`.lml`/`.lutaml`) files with
55
+ link:https://github.com/lutaml/lutaml-lml[lutaml-lml]:
74
56
 
75
57
  [source,ruby]
76
58
  ----
77
59
  require "lutaml"
78
60
 
79
- # example.exp is an EXPRESS schema file
80
- model = Lutaml::Parser.parse([File.new("example.exp")])
81
- # => returns Expressir::Express::Model::Repository model
82
-
83
- # example.exp.yaml is an EXPRESS cache file created with Expressir
84
- model = Lutaml::Parser.parse([File.new("example.exp.yaml")], ::Lutaml::Parser::EXPRESS_CACHE_PARSE_TYPE)
85
- # => returns Expressir::Express::Cache model
86
-
87
- # example.xmi is an XMI file
88
- model = Lutaml::Parser.parse([File.new("example.xmi")])
89
- # => returns Lutaml::Uml::Document model
90
-
91
- # example.xml is an XML file
92
- model = Lutaml::Parser.parse([File.new("example.xml")])
93
- # => returns Lutaml::Uml::Document model
94
-
95
- # example.lutaml is an LutaML file
96
- model = Lutaml::Parser.parse([File.new("example.lutaml")])
97
- # => returns Lutaml::Uml::Document model
98
-
99
- # example.yaml is an LutaML YAML file
100
- model = Lutaml::Parser.parse([File.new("example.yaml")])
101
- # => returns Lutaml::Uml::Document model
61
+ doc = Lutaml::Lml.parse_document(File.new("model.lutaml"))
62
+ doc.classes.first.attributes.map(&:name)
102
63
  ----
103
64
 
65
+ EXPRESS schemas parse through `Lutaml::Express::Parsers::Exp.parse(io)`;
66
+ see README.md for the full family table and the repository layer.
104
67
 
105
68
  == Working with UML
106
69
 
data/README.md ADDED
@@ -0,0 +1,49 @@
1
+ # LutaML
2
+
3
+ LutaML is data models in textual form. The `lutaml` gem is the umbrella
4
+ of the LutaML family: it installs the core engine together with the
5
+ textual modelling languages built on top of it, and exposes the EXPRESS
6
+ parsing surface under the `Lutaml::Express` namespace.
7
+
8
+ ## The LutaML family
9
+
10
+ | Gem | Role |
11
+ | --- | --- |
12
+ | [lutaml-model](https://github.com/lutaml/lutaml-model) | Core declarative data modelling engine with serialization to and from XML, JSON, YAML, TOML and Hash. |
13
+ | [lutaml-lml](https://github.com/lutaml/lutaml-lml) | Parser and converter for the LutaML Model Language (LML, `.lml`/`.lutaml`) textual syntax. |
14
+ | [lutaml-uml](https://github.com/lutaml/lutaml-uml) | UML domain models, document repository (`.lur` packages), and static-site generation. |
15
+ | [expressir](https://github.com/lutaml/expressir) | EXPRESS language parser and repository tooling. |
16
+ | **lutaml** (this gem) | Umbrella for the family; EXPRESS schema parsing through `Lutaml::Express::Parsers::Exp`. |
17
+
18
+ The wider ecosystem installs separately as needed:
19
+ [lutaml-store](https://github.com/lutaml/lutaml-store) (document store),
20
+ [lutaml-hal](https://github.com/lutaml/lutaml-hal) (HAL documents),
21
+ [lutaml-jsonschema](https://github.com/lutaml/lutaml-jsonschema) (JSON
22
+ Schema generation), [lutaml-xmi](https://github.com/lutaml/lutaml-xmi)
23
+ (XMI import), and [lutaml-path](https://github.com/lutaml/lutaml-path)
24
+ (path queries over LutaML models).
25
+
26
+ ## Installation
27
+
28
+ ```ruby
29
+ gem "lutaml"
30
+ ```
31
+
32
+ ## Usage
33
+
34
+ ```ruby
35
+ require "lutaml"
36
+
37
+ repository = File.open("schema.exp") do |io|
38
+ Lutaml::Express::Parsers::Exp.parse(io)
39
+ end
40
+ ```
41
+
42
+ Requiring `lutaml` loads `lutaml-lml`, `lutaml-uml` (including its
43
+ repository layer) and the EXPRESS parser autoload; every member of the
44
+ family builds on `lutaml-model`.
45
+
46
+ ## License
47
+
48
+ The gem is available as open source under the terms of the
49
+ [MIT License](https://opensource.org/licenses/MIT).
@@ -104,12 +104,10 @@ The following results will be produced:
104
104
  [source,lutaml]
105
105
  ----
106
106
  diagram Address {
107
- title ''
108
- caption ''
109
107
  association {
110
108
  owner_type aggregation
111
- owner
112
- member_type direct
109
+ owner Address
110
+ member_type association
113
111
  member AddressComponent
114
112
  }
115
113
  }
@@ -152,7 +152,7 @@ If this syntax is used inside a `class`/`enum`/`association` block, it will be c
152
152
  This is a
153
153
  multi-line
154
154
  document comment.
155
- *|
155
+ |*
156
156
 
157
157
  class A
158
158
  enum B {
@@ -162,7 +162,7 @@ enum B {
162
162
  This is a
163
163
  multi-line
164
164
  class comment.
165
- *|
165
+ |*
166
166
  bar
167
167
  }
168
168
  ----
@@ -279,15 +279,22 @@ following:
279
279
 
280
280
  The name of the element and its visibility are optional.
281
281
 
282
+ [NOTE]
283
+ --
284
+ Visibility on package contents (classes, enums, packages) is not yet
285
+ implemented; only attribute visibility (`+`, `-`, `#`, `~`) is parsed
286
+ today. Element-level visibility is a candidate for adoption into the
287
+ LML specification (RS 3001) pending an audit of UML round-trip
288
+ requirements.
289
+ --
290
+
282
291
  [example]
283
- .Declaring a package named "Ceramic" with a public visibility modifier
292
+ .Declaring a package named "CeramicInformationModel"
284
293
  ====
285
294
  [source]
286
295
  ----
287
296
  package CeramicInformationModel {
288
297
  class Ceramic {}
289
- - class PrivateCeramic {}
290
- # class ProtectedCeramic {}
291
298
  }
292
299
  ----
293
300
  ====
@@ -584,7 +591,7 @@ Explicit syntax (`attribute` keyword included):
584
591
  [source]
585
592
  ----
586
593
  class A {
587
- attribute my_attribute
594
+ attribute my_attribute, String
588
595
  }
589
596
 
590
597
  enum A {
@@ -670,6 +677,14 @@ class Figure {
670
677
 
671
678
  === Methods
672
679
 
680
+ [NOTE]
681
+ --
682
+ Methods are not yet implemented by the LML parser. This section
683
+ documents the planned surface; adoption into the LML specification
684
+ (RS 3001) is pending an audit of downstream UML round-trip
685
+ requirements (Enterprise Architect, XMI).
686
+ --
687
+
673
688
  ==== General
674
689
 
675
690
  A method is a function that is defined inside a class and can be called to
@@ -881,8 +896,14 @@ association {
881
896
  ====
882
897
  [source]
883
898
  ----
899
+ class Ceramic {}
900
+ class Glaze {}
901
+
884
902
  association {
885
- Ceramic -> Glaze
903
+ owner_type association
904
+ owner Ceramic
905
+ member_type association
906
+ member Glaze
886
907
  }
887
908
  ----
888
909
  ====
@@ -893,37 +914,32 @@ Syntax:
893
914
 
894
915
  [source]
895
916
  ----
896
- association name {
897
- owned_type association|composition|aggregation|generalization|uses
917
+ association [name] {
918
+ owner_type association|composition|aggregation|generalization|uses
919
+ owner class_name[#attribute_name]
898
920
  member_type association|composition|aggregation|generalization|uses
899
- owned association_name[#attribute_name] [{property_string}][cardinality]
900
- member association_name[#attribute_name] [{property_string}][cardinality]
921
+ member class_name[#attribute_name]
901
922
  }
902
923
  ----
903
924
 
904
925
  where:
905
926
 
906
- * `owned_type` - optional, use to define a bidirectional association (`association`|`composition`|`aggregation`|`generalization`|`uses`)
927
+ * `owner_type` - optional, use to define a bidirectional association (`association`|`composition`|`aggregation`|`generalization`|`uses`)
907
928
  * `member_type` - association type (`association`|`composition`|`aggregation`|`generalization`|`uses`)
908
- * `owned|member` - end of association, use `\#attribute_name` to set a role name
909
- * `property_string` - property string for attributes associations
910
- * `cardinality` - examples: `1..*`, `*`
929
+ * `owner`/`member` - end of association, use `#attribute_name` to set a role name
911
930
 
912
931
  Example:
913
932
 
914
933
  [source]
915
934
  ----
916
- class Association {
917
- +association:
918
- }
919
- class Type {
920
- +endType:
921
- }
935
+ class Address {}
936
+ class AddressComponent {}
922
937
 
923
- association AssociatingTypeAndAssociation {
924
- type uses
925
- from Association#+association {subsets relationship}[*]
926
- to Type#+/endType {readOnly, subsets relatedElement} [1..*]
938
+ association AddressesAssociation {
939
+ owner_type aggregation
940
+ owner Address
941
+ member_type association
942
+ member AddressComponent
927
943
  }
928
944
  ----
929
945
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Lutaml
4
- VERSION = "0.11.3"
4
+ VERSION = "0.11.5"
5
5
  end
data/lutaml.gemspec CHANGED
@@ -34,6 +34,7 @@ Gem::Specification.new do |spec|
34
34
  # (fiddle was removed from Ruby 4.0 default gems, breaking reline on Windows)
35
35
  spec.add_dependency "fiddle"
36
36
  spec.add_dependency "lutaml-lml"
37
- spec.add_dependency "lutaml-uml", "~> 0.5" # pin: 1.0.0 depends on lutaml (circular)
37
+ spec.add_dependency "lutaml-model", "~> 0.8.114"
38
+ spec.add_dependency "lutaml-uml", "~> 1.0"
38
39
  spec.metadata["rubygems_mfa_required"] = "true"
39
40
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lutaml
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.3
4
+ version: 0.11.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ribose Inc.
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2026-07-08 00:00:00.000000000 Z
11
+ date: 2026-10-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: expressir
@@ -52,20 +52,34 @@ dependencies:
52
52
  - - ">="
53
53
  - !ruby/object:Gem::Version
54
54
  version: '0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: lutaml-model
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: 0.8.114
62
+ type: :runtime
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: 0.8.114
55
69
  - !ruby/object:Gem::Dependency
56
70
  name: lutaml-uml
57
71
  requirement: !ruby/object:Gem::Requirement
58
72
  requirements:
59
73
  - - "~>"
60
74
  - !ruby/object:Gem::Version
61
- version: '0.5'
75
+ version: '1.0'
62
76
  type: :runtime
63
77
  prerelease: false
64
78
  version_requirements: !ruby/object:Gem::Requirement
65
79
  requirements:
66
80
  - - "~>"
67
81
  - !ruby/object:Gem::Version
68
- version: '0.5'
82
+ version: '1.0'
69
83
  description: 'LutaML: data models in textual form'
70
84
  email:
71
85
  - open.source@ribose.com
@@ -86,6 +100,7 @@ files:
86
100
  - CLAUDE.md
87
101
  - Gemfile
88
102
  - README.adoc
103
+ - README.md
89
104
  - Rakefile
90
105
  - bin/console
91
106
  - bin/folder_yaml2lutaml.sh