relaton-cli 3.0.0.pre.alpha.17 → 3.0.0.pre.alpha.19

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: 8dc8eee9f59498883f62c56a989f07450f7e240be24bcbb69c7d9c5ff304d8e5
4
- data.tar.gz: dde7c61e5d4702adc5c3679907f87be659461e6c7a7742097dbd442a0daf2033
3
+ metadata.gz: 520b7f51e110fe890b6ac3fc948a24ce3b1599dff5e783041a864d04140b4a51
4
+ data.tar.gz: 55a7a404b4b0c3fe0795b65214b1535fd6dacb0ef0849bab3f8d31364dd8073e
5
5
  SHA512:
6
- metadata.gz: f378d0fd79c049d097cf450a53ecf73c1d0cd829969a2dcdee69634a2d0b093ea3fdd30b21606844452b89c93c777c2aa5361e31552105a227cdf63af04f2533
7
- data.tar.gz: 3629ba68fb0bf6f5a4e21f8e18055b6ee7a33c2fe271472ed8682e217773f84805b721598d208436672ac379254199d0ae638a5261d15539cffd251601e39ceb
6
+ metadata.gz: da04c456d04952fdf1b82adce975acce190d28aabab157dc9ee712a576cebbbea81e511b3178a6d99628b243f98324df8147a543d278baba7ffb4f8d7e24af69
7
+ data.tar.gz: 4c796605aec0b10b1658fb4e329a9733578a4fd52f4121ae00d30728ac451eca40f3538cc59f946b255799e69ba7e7fe995532b840ef4fee6fd16688f665e424
@@ -1,6 +1,7 @@
1
1
  require "json"
2
2
  require "yaml"
3
3
  require "zlib"
4
+ require "digest"
4
5
  require "pathname"
5
6
  require "fileutils"
6
7
  require "liquid"
@@ -579,11 +580,21 @@ module Relaton
579
580
 
580
581
  monolith = File.join(output, machine.monolith_filename)
581
582
  machine.write_monolith(monolith)
582
- zip_file(monolith)
583
+ zip_path = zip_file(monolith)
584
+
585
+ # Content address of the published whole-index artifact: a consumer
586
+ # pins `sha256` from this manifest and can verify the zip it fetched.
587
+ # `bytes` is the same artifact's size (progress and cache accounting).
588
+ artifact = {
589
+ "sha256" => Digest::SHA256.file(zip_path).hexdigest,
590
+ "bytes" => File.size(zip_path),
591
+ }
583
592
 
584
593
  write_file(
585
594
  File.join(output, "index", "manifest.json"),
586
- JSON.pretty_generate(machine.manifest(generated: @generated)),
595
+ JSON.pretty_generate(
596
+ machine.manifest(generated: @generated).merge(artifact),
597
+ ),
587
598
  )
588
599
  if machine.skipped_count.positive?
589
600
  Util.warn "Machine index: skipped #{machine.skipped_count} of " \
@@ -595,13 +606,14 @@ module Relaton
595
606
 
596
607
  # Zip sibling of a monolith — the form `Relaton::Index url:`
597
608
  # fetches today. The zip stores the yaml at its bare basename,
598
- # matching the layout data repos publish in git.
609
+ # matching the layout data repos publish in git. Returns the zip path.
599
610
  def zip_file(yaml_path)
600
611
  zip_path = yaml_path.sub(/\.yaml\z/, ".zip")
601
612
  File.delete(zip_path) if File.exist?(zip_path)
602
613
  Zip::File.open(zip_path, create: true) do |archive|
603
614
  archive.add(File.basename(yaml_path), yaml_path)
604
615
  end
616
+ zip_path
605
617
  end
606
618
 
607
619
  # Copy the scanned corpus onto the site so clients can fetch
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: relaton-cli
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.0.pre.alpha.17
4
+ version: 3.0.0.pre.alpha.19
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-10-19 00:00:00.000000000 Z
11
+ date: 2026-10-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: liquid
@@ -44,14 +44,14 @@ dependencies:
44
44
  requirements:
45
45
  - - '='
46
46
  - !ruby/object:Gem::Version
47
- version: 3.0.0.pre.alpha.17
47
+ version: 3.0.0.pre.alpha.19
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - '='
53
53
  - !ruby/object:Gem::Version
54
- version: 3.0.0.pre.alpha.17
54
+ version: 3.0.0.pre.alpha.19
55
55
  - !ruby/object:Gem::Dependency
56
56
  name: thor
57
57
  requirement: !ruby/object:Gem::Requirement