gobl 0.10.0 → 0.10.1
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 +4 -4
- data/README.md +7 -13
- data/lib/gobl/version.rb +1 -1
- data/lib/gobl.rb +1 -0
- metadata +73 -73
- /data/lib/{gobl → generated/gobl}/bill/charge.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/delivery.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/discount.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/document_reference.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/invoice.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/line.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/line_charge.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/line_discount.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/ordering.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/outlay.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/payment.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/preceding.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/tax.rb +0 -0
- /data/lib/{gobl → generated/gobl}/bill/totals.rb +0 -0
- /data/lib/{gobl → generated/gobl}/cal/date.rb +0 -0
- /data/lib/{gobl → generated/gobl}/cal/period.rb +0 -0
- /data/lib/{gobl → generated/gobl}/cbc/code.rb +0 -0
- /data/lib/{gobl → generated/gobl}/cbc/key.rb +0 -0
- /data/lib/{gobl → generated/gobl}/cbc/meta.rb +0 -0
- /data/lib/{gobl → generated/gobl}/cbc/note.rb +0 -0
- /data/lib/{gobl → generated/gobl}/cbc/stamp.rb +0 -0
- /data/lib/{gobl → generated/gobl}/currency/code.rb +0 -0
- /data/lib/{gobl → generated/gobl}/currency/exchange_rate.rb +0 -0
- /data/lib/{gobl → generated/gobl}/document.rb +0 -0
- /data/lib/{gobl → generated/gobl}/dsig/digest.rb +0 -0
- /data/lib/{gobl → generated/gobl}/dsig/signature.rb +0 -0
- /data/lib/{gobl → generated/gobl}/envelope.rb +0 -0
- /data/lib/{gobl → generated/gobl}/header.rb +0 -0
- /data/lib/{gobl → generated/gobl}/i18n/string.rb +0 -0
- /data/lib/{gobl → generated/gobl}/l10n/code.rb +0 -0
- /data/lib/{gobl → generated/gobl}/l10n/country_code.rb +0 -0
- /data/lib/{gobl → generated/gobl}/note/message.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/address.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/coordinates.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/email.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/identity.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/image.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/inbox.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/item.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/name.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/party.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/person.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/registration.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/telephone.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/unit.rb +0 -0
- /data/lib/{gobl → generated/gobl}/org/website.rb +0 -0
- /data/lib/{gobl → generated/gobl}/pay/advance.rb +0 -0
- /data/lib/{gobl → generated/gobl}/pay/card.rb +0 -0
- /data/lib/{gobl → generated/gobl}/pay/credit_transfer.rb +0 -0
- /data/lib/{gobl → generated/gobl}/pay/direct_debit.rb +0 -0
- /data/lib/{gobl → generated/gobl}/pay/due_date.rb +0 -0
- /data/lib/{gobl → generated/gobl}/pay/instructions.rb +0 -0
- /data/lib/{gobl → generated/gobl}/pay/online.rb +0 -0
- /data/lib/{gobl → generated/gobl}/pay/terms.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/category.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/category_total.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/combo.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/identity.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/key_definition.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/preceding_definitions.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/rate.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/rate_total.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/rate_total_surcharge.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/rate_value.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/regime.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/scenario.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/scenario_set.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/set.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/tag.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/total.rb +0 -0
- /data/lib/{gobl → generated/gobl}/tax/zone.rb +0 -0
- /data/lib/{gobl → generated/gobl}/uuid/uuid.rb +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: bff66b8750d72848acd28331e82d9c91a951d093331400a0d2942119d83b2f9b
|
|
4
|
+
data.tar.gz: 23d17b39a899ddc36293d2b070338bc30f4011acf08b299854f027ee06f8f758
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2cc83e91eeefd2ef016b1a7a079e158c4b40cd1ba88b995b13ea46926dd7dbce06cc27547f755d18acb1e74b6ea1c81af99b7c6e5a190ecaeba1f596e9185a37
|
|
7
|
+
data.tar.gz: 22cfc2a7a0eb8c2c244bc04589033bd3f0a7e0fa6d77a76704c6775d79ba9f53bcd9ce8e84e225430a651da788a36ab8679e06e0ded107b773636479e93dec95
|
data/README.md
CHANGED
|
@@ -215,28 +215,22 @@ The command `mage setup` fetches and installs all the required dependencies to u
|
|
|
215
215
|
|
|
216
216
|
#### Code generation
|
|
217
217
|
|
|
218
|
-
Ensure all the GOBL JSON Schema files are available by manually copying the base GOBL project's `build
|
|
218
|
+
Ensure all the GOBL JSON Schema and Regime files are available by manually copying the [base GOBL project](https://github.com/invopop/gobl)'s `build/` path to the `data/` path in this repository. For example, assuming you have GOBL at `../gobl/`, you can run this:
|
|
219
219
|
|
|
220
220
|
```bash
|
|
221
|
-
rm -rf ./data
|
|
222
|
-
cp -r ../gobl/build
|
|
221
|
+
rm -rf ./data/*
|
|
222
|
+
cp -r ../gobl/build/* ./data
|
|
223
223
|
```
|
|
224
224
|
|
|
225
|
-
|
|
225
|
+
Please note that `schemas` is _.gitignored_ as we only need it to generate the code. However, the previous command also copies `regimes` which content is used by the library and so, it is part of the git repo and the gem.
|
|
226
226
|
|
|
227
|
-
|
|
228
|
-
rm -rf ./data/regimes
|
|
229
|
-
cp -r ../gobl/build/regimes ./data
|
|
230
|
-
```
|
|
231
|
-
|
|
232
|
-
Now you can delete any previously generated code with
|
|
227
|
+
Now, with the help of [the GOBL generator](https://github.com/invopop/gobl.generator), you can regenerate the code. For example, assuming the GOBL generator is at `../gobl.generator`, you can run this:
|
|
233
228
|
|
|
234
229
|
```bash
|
|
235
|
-
|
|
230
|
+
rm -rf lib/generated/gobl
|
|
231
|
+
../gobl.generator/bin/generate -l ruby -o lib/generated/gobl/
|
|
236
232
|
```
|
|
237
233
|
|
|
238
|
-
The command `mage -v generate` generates the Ruby files from the JSON Schema. If the schema is updated, it will update the Ruby files.
|
|
239
|
-
|
|
240
234
|
#### Tests
|
|
241
235
|
|
|
242
236
|
Use the `mage spec` command to run the entire test suite.
|
data/lib/gobl/version.rb
CHANGED
data/lib/gobl.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: gobl
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.10.
|
|
4
|
+
version: 0.10.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- David Lilue
|
|
@@ -68,94 +68,94 @@ files:
|
|
|
68
68
|
- data/regimes/it.json
|
|
69
69
|
- data/regimes/nl.json
|
|
70
70
|
- data/regimes/pt.json
|
|
71
|
+
- lib/generated/gobl/bill/charge.rb
|
|
72
|
+
- lib/generated/gobl/bill/delivery.rb
|
|
73
|
+
- lib/generated/gobl/bill/discount.rb
|
|
74
|
+
- lib/generated/gobl/bill/document_reference.rb
|
|
75
|
+
- lib/generated/gobl/bill/invoice.rb
|
|
76
|
+
- lib/generated/gobl/bill/line.rb
|
|
77
|
+
- lib/generated/gobl/bill/line_charge.rb
|
|
78
|
+
- lib/generated/gobl/bill/line_discount.rb
|
|
79
|
+
- lib/generated/gobl/bill/ordering.rb
|
|
80
|
+
- lib/generated/gobl/bill/outlay.rb
|
|
81
|
+
- lib/generated/gobl/bill/payment.rb
|
|
82
|
+
- lib/generated/gobl/bill/preceding.rb
|
|
83
|
+
- lib/generated/gobl/bill/tax.rb
|
|
84
|
+
- lib/generated/gobl/bill/totals.rb
|
|
85
|
+
- lib/generated/gobl/cal/date.rb
|
|
86
|
+
- lib/generated/gobl/cal/period.rb
|
|
87
|
+
- lib/generated/gobl/cbc/code.rb
|
|
88
|
+
- lib/generated/gobl/cbc/key.rb
|
|
89
|
+
- lib/generated/gobl/cbc/meta.rb
|
|
90
|
+
- lib/generated/gobl/cbc/note.rb
|
|
91
|
+
- lib/generated/gobl/cbc/stamp.rb
|
|
92
|
+
- lib/generated/gobl/currency/code.rb
|
|
93
|
+
- lib/generated/gobl/currency/exchange_rate.rb
|
|
94
|
+
- lib/generated/gobl/document.rb
|
|
95
|
+
- lib/generated/gobl/dsig/digest.rb
|
|
96
|
+
- lib/generated/gobl/dsig/signature.rb
|
|
97
|
+
- lib/generated/gobl/envelope.rb
|
|
98
|
+
- lib/generated/gobl/header.rb
|
|
99
|
+
- lib/generated/gobl/i18n/string.rb
|
|
100
|
+
- lib/generated/gobl/l10n/code.rb
|
|
101
|
+
- lib/generated/gobl/l10n/country_code.rb
|
|
102
|
+
- lib/generated/gobl/note/message.rb
|
|
103
|
+
- lib/generated/gobl/org/address.rb
|
|
104
|
+
- lib/generated/gobl/org/coordinates.rb
|
|
105
|
+
- lib/generated/gobl/org/email.rb
|
|
106
|
+
- lib/generated/gobl/org/identity.rb
|
|
107
|
+
- lib/generated/gobl/org/image.rb
|
|
108
|
+
- lib/generated/gobl/org/inbox.rb
|
|
109
|
+
- lib/generated/gobl/org/item.rb
|
|
110
|
+
- lib/generated/gobl/org/name.rb
|
|
111
|
+
- lib/generated/gobl/org/party.rb
|
|
112
|
+
- lib/generated/gobl/org/person.rb
|
|
113
|
+
- lib/generated/gobl/org/registration.rb
|
|
114
|
+
- lib/generated/gobl/org/telephone.rb
|
|
115
|
+
- lib/generated/gobl/org/unit.rb
|
|
116
|
+
- lib/generated/gobl/org/website.rb
|
|
117
|
+
- lib/generated/gobl/pay/advance.rb
|
|
118
|
+
- lib/generated/gobl/pay/card.rb
|
|
119
|
+
- lib/generated/gobl/pay/credit_transfer.rb
|
|
120
|
+
- lib/generated/gobl/pay/direct_debit.rb
|
|
121
|
+
- lib/generated/gobl/pay/due_date.rb
|
|
122
|
+
- lib/generated/gobl/pay/instructions.rb
|
|
123
|
+
- lib/generated/gobl/pay/online.rb
|
|
124
|
+
- lib/generated/gobl/pay/terms.rb
|
|
125
|
+
- lib/generated/gobl/tax/category.rb
|
|
126
|
+
- lib/generated/gobl/tax/category_total.rb
|
|
127
|
+
- lib/generated/gobl/tax/combo.rb
|
|
128
|
+
- lib/generated/gobl/tax/identity.rb
|
|
129
|
+
- lib/generated/gobl/tax/key_definition.rb
|
|
130
|
+
- lib/generated/gobl/tax/preceding_definitions.rb
|
|
131
|
+
- lib/generated/gobl/tax/rate.rb
|
|
132
|
+
- lib/generated/gobl/tax/rate_total.rb
|
|
133
|
+
- lib/generated/gobl/tax/rate_total_surcharge.rb
|
|
134
|
+
- lib/generated/gobl/tax/rate_value.rb
|
|
135
|
+
- lib/generated/gobl/tax/regime.rb
|
|
136
|
+
- lib/generated/gobl/tax/scenario.rb
|
|
137
|
+
- lib/generated/gobl/tax/scenario_set.rb
|
|
138
|
+
- lib/generated/gobl/tax/set.rb
|
|
139
|
+
- lib/generated/gobl/tax/tag.rb
|
|
140
|
+
- lib/generated/gobl/tax/total.rb
|
|
141
|
+
- lib/generated/gobl/tax/zone.rb
|
|
142
|
+
- lib/generated/gobl/uuid/uuid.rb
|
|
71
143
|
- lib/gobl.rb
|
|
72
|
-
- lib/gobl/bill/charge.rb
|
|
73
|
-
- lib/gobl/bill/delivery.rb
|
|
74
|
-
- lib/gobl/bill/discount.rb
|
|
75
|
-
- lib/gobl/bill/document_reference.rb
|
|
76
|
-
- lib/gobl/bill/invoice.rb
|
|
77
|
-
- lib/gobl/bill/line.rb
|
|
78
|
-
- lib/gobl/bill/line_charge.rb
|
|
79
|
-
- lib/gobl/bill/line_discount.rb
|
|
80
|
-
- lib/gobl/bill/ordering.rb
|
|
81
|
-
- lib/gobl/bill/outlay.rb
|
|
82
|
-
- lib/gobl/bill/payment.rb
|
|
83
|
-
- lib/gobl/bill/preceding.rb
|
|
84
|
-
- lib/gobl/bill/tax.rb
|
|
85
|
-
- lib/gobl/bill/totals.rb
|
|
86
|
-
- lib/gobl/cal/date.rb
|
|
87
|
-
- lib/gobl/cal/period.rb
|
|
88
|
-
- lib/gobl/cbc/code.rb
|
|
89
|
-
- lib/gobl/cbc/key.rb
|
|
90
|
-
- lib/gobl/cbc/meta.rb
|
|
91
|
-
- lib/gobl/cbc/note.rb
|
|
92
|
-
- lib/gobl/cbc/stamp.rb
|
|
93
144
|
- lib/gobl/config.rb
|
|
94
|
-
- lib/gobl/currency/code.rb
|
|
95
|
-
- lib/gobl/currency/exchange_rate.rb
|
|
96
|
-
- lib/gobl/document.rb
|
|
97
|
-
- lib/gobl/dsig/digest.rb
|
|
98
|
-
- lib/gobl/dsig/signature.rb
|
|
99
145
|
- lib/gobl/enum.rb
|
|
100
|
-
- lib/gobl/envelope.rb
|
|
101
146
|
- lib/gobl/extensions/document_helper.rb
|
|
102
147
|
- lib/gobl/extensions/envelope_helper.rb
|
|
103
148
|
- lib/gobl/extensions/i18n/value_keys_helper.rb
|
|
104
149
|
- lib/gobl/extensions/tax/regime_helper.rb
|
|
105
|
-
- lib/gobl/header.rb
|
|
106
|
-
- lib/gobl/i18n/string.rb
|
|
107
150
|
- lib/gobl/id.rb
|
|
108
|
-
- lib/gobl/l10n/code.rb
|
|
109
|
-
- lib/gobl/l10n/country_code.rb
|
|
110
151
|
- lib/gobl/map.rb
|
|
111
|
-
- lib/gobl/note/message.rb
|
|
112
152
|
- lib/gobl/num/amount.rb
|
|
113
153
|
- lib/gobl/num/percentage.rb
|
|
114
154
|
- lib/gobl/object.rb
|
|
115
155
|
- lib/gobl/operations.rb
|
|
116
156
|
- lib/gobl/operations/service_error.rb
|
|
117
157
|
- lib/gobl/operations/validation_result.rb
|
|
118
|
-
- lib/gobl/org/address.rb
|
|
119
|
-
- lib/gobl/org/coordinates.rb
|
|
120
|
-
- lib/gobl/org/email.rb
|
|
121
|
-
- lib/gobl/org/identity.rb
|
|
122
|
-
- lib/gobl/org/image.rb
|
|
123
|
-
- lib/gobl/org/inbox.rb
|
|
124
|
-
- lib/gobl/org/item.rb
|
|
125
|
-
- lib/gobl/org/name.rb
|
|
126
|
-
- lib/gobl/org/party.rb
|
|
127
|
-
- lib/gobl/org/person.rb
|
|
128
|
-
- lib/gobl/org/registration.rb
|
|
129
|
-
- lib/gobl/org/telephone.rb
|
|
130
|
-
- lib/gobl/org/unit.rb
|
|
131
|
-
- lib/gobl/org/website.rb
|
|
132
|
-
- lib/gobl/pay/advance.rb
|
|
133
|
-
- lib/gobl/pay/card.rb
|
|
134
|
-
- lib/gobl/pay/credit_transfer.rb
|
|
135
|
-
- lib/gobl/pay/direct_debit.rb
|
|
136
|
-
- lib/gobl/pay/due_date.rb
|
|
137
|
-
- lib/gobl/pay/instructions.rb
|
|
138
|
-
- lib/gobl/pay/online.rb
|
|
139
|
-
- lib/gobl/pay/terms.rb
|
|
140
158
|
- lib/gobl/struct.rb
|
|
141
|
-
- lib/gobl/tax/category.rb
|
|
142
|
-
- lib/gobl/tax/category_total.rb
|
|
143
|
-
- lib/gobl/tax/combo.rb
|
|
144
|
-
- lib/gobl/tax/identity.rb
|
|
145
|
-
- lib/gobl/tax/key_definition.rb
|
|
146
|
-
- lib/gobl/tax/preceding_definitions.rb
|
|
147
|
-
- lib/gobl/tax/rate.rb
|
|
148
|
-
- lib/gobl/tax/rate_total.rb
|
|
149
|
-
- lib/gobl/tax/rate_total_surcharge.rb
|
|
150
|
-
- lib/gobl/tax/rate_value.rb
|
|
151
|
-
- lib/gobl/tax/regime.rb
|
|
152
|
-
- lib/gobl/tax/scenario.rb
|
|
153
|
-
- lib/gobl/tax/scenario_set.rb
|
|
154
|
-
- lib/gobl/tax/set.rb
|
|
155
|
-
- lib/gobl/tax/tag.rb
|
|
156
|
-
- lib/gobl/tax/total.rb
|
|
157
|
-
- lib/gobl/tax/zone.rb
|
|
158
|
-
- lib/gobl/uuid/uuid.rb
|
|
159
159
|
- lib/gobl/version.rb
|
|
160
160
|
homepage: https://github.com/invopop/gobl.ruby
|
|
161
161
|
licenses:
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|