19 lines
747 B
Plaintext
19 lines
747 B
Plaintext
!import "arboricx-manifest.tri" !Local
|
|
|
|
-- Read and validate a full Arboricx bundle.
|
|
-- Returns (pair validManifest afterContainer).
|
|
-- The manifest core fields are validated against expected values.
|
|
readArboricxBundle = (bs :
|
|
bindResult (readArboricxRequiredSections bs)
|
|
(sections afterContainer :
|
|
matchPair
|
|
(manifestBytes _ :
|
|
bindResult (readManifest manifestBytes)
|
|
(parsedManifest afterManifest :
|
|
matchPair
|
|
(coreManifest metadataWithExtensions :
|
|
bindResult (validateManifestCore coreManifest afterManifest)
|
|
(validCore _ : ok (pair validCore metadataWithExtensions) afterContainer))
|
|
parsedManifest))
|
|
sections))
|