diff options
Diffstat (limited to 'stdlib/source/program/aedifex/artifact/snapshot')
5 files changed, 24 insertions, 24 deletions
diff --git a/stdlib/source/program/aedifex/artifact/snapshot/build.lux b/stdlib/source/program/aedifex/artifact/snapshot/build.lux index 483da5e39..f0a0c7d18 100644 --- a/stdlib/source/program/aedifex/artifact/snapshot/build.lux +++ b/stdlib/source/program/aedifex/artifact/snapshot/build.lux @@ -20,22 +20,22 @@ (type: .public Build Nat) -(def: .public equivalence +(def .public equivalence (Equivalence Build) nat.equivalence) -(def: tag +(def tag xml.Tag ["" "buildNumber"]) -(def: .public format +(def .public format (-> Build XML) (|>> %.nat {xml.#Text} list {xml.#Node ..tag xml.attributes})) -(def: .public parser +(def .public parser (Parser Build) (<| (<xml>.node ..tag) (<text>.then (<>.codec nat.decimal (<text>.many <text>.decimal))) diff --git a/stdlib/source/program/aedifex/artifact/snapshot/stamp.lux b/stdlib/source/program/aedifex/artifact/snapshot/stamp.lux index 3365d685c..2f82cf020 100644 --- a/stdlib/source/program/aedifex/artifact/snapshot/stamp.lux +++ b/stdlib/source/program/aedifex/artifact/snapshot/stamp.lux @@ -22,36 +22,36 @@ [#time Time #build Build])) -(def: .public equivalence +(def .public equivalence (Equivalence Stamp) (all product.equivalence //time.equivalence //build.equivalence )) -(def: <timestamp> +(def <timestamp> xml.Tag ["" "timestamp"]) -(def: time_format +(def time_format (-> Time XML) (|>> //time.format {xml.#Text} list {xml.#Node ..<timestamp> xml.attributes})) -(def: .public (format (open "_[0]")) +(def .public (format (open "_[0]")) (-> Stamp (List XML)) (list (..time_format _#time) (//build.format _#build))) -(def: time_parser +(def time_parser (Parser Time) (<| (<xml>.node <timestamp>) (<text>.then //time.parser) <xml>.text)) -(def: .public parser +(def .public parser (Parser Stamp) (<>.and (<xml>.somewhere ..time_parser) (<xml>.somewhere //build.parser))) diff --git a/stdlib/source/program/aedifex/artifact/snapshot/time.lux b/stdlib/source/program/aedifex/artifact/snapshot/time.lux index 3b6fbe0ee..38a60ede0 100644 --- a/stdlib/source/program/aedifex/artifact/snapshot/time.lux +++ b/stdlib/source/program/aedifex/artifact/snapshot/time.lux @@ -24,20 +24,20 @@ (type: .public Time ///time.Time) -(def: .public equivalence +(def .public equivalence (Equivalence Time) ///time.equivalence) -(def: separator +(def separator ".") -(def: .public (format [date time]) +(def .public (format [date time]) (%.Format Time) (%.format (///time/date.format date) ..separator (///time/time.format time))) -(def: .public parser +(def .public parser (<text>.Parser Time) (do <>.monad [date ///time/date.parser diff --git a/stdlib/source/program/aedifex/artifact/snapshot/version.lux b/stdlib/source/program/aedifex/artifact/snapshot/version.lux index bf26ae259..e38534c8f 100644 --- a/stdlib/source/program/aedifex/artifact/snapshot/version.lux +++ b/stdlib/source/program/aedifex/artifact/snapshot/version.lux @@ -23,7 +23,7 @@ #value Text #updated Time])) -(def: .public equivalence +(def .public equivalence (Equivalence Version) (all product.equivalence text.equivalence @@ -32,7 +32,7 @@ )) (with_template [<definition> <tag>] - [(def: <definition> xml.Tag ["" <tag>])] + [(def <definition> xml.Tag ["" <tag>])] [<extension> "extension"] [<value> "value"] @@ -41,23 +41,23 @@ [<snapshot_version> "snapshotVersion"] ) -(def: (text_format tag value) +(def (text_format tag value) (-> xml.Tag Text XML) (|> value {xml.#Text} list {xml.#Node tag xml.attributes})) -(def: .public (format (open "_[0]")) +(def .public (format (open "_[0]")) (-> Version XML) (<| {xml.#Node ..<snapshot_version> xml.attributes} (list (..text_format ..<extension> _#extension) (..text_format ..<value> _#value) (..text_format ..<updated> (///time.format _#updated))))) -(def: (text tag) +(def (text tag) (-> xml.Tag (Parser Text)) (<| (<xml>.node tag) <xml>.text)) -(def: .public parser +(def .public parser (Parser Version) (<| (<xml>.node ..<snapshot_version>) (all <>.and diff --git a/stdlib/source/program/aedifex/artifact/snapshot/version/value.lux b/stdlib/source/program/aedifex/artifact/snapshot/version/value.lux index 875326058..c0b528186 100644 --- a/stdlib/source/program/aedifex/artifact/snapshot/version/value.lux +++ b/stdlib/source/program/aedifex/artifact/snapshot/version/value.lux @@ -16,20 +16,20 @@ [#version Text #snapshot Snapshot])) -(def: .public equivalence +(def .public equivalence (Equivalence Value) (all product.equivalence text.equivalence ///.equivalence )) -(def: separator +(def separator "-") -(def: .public snapshot +(def .public snapshot "SNAPSHOT") -(def: .public (format (open "/[0]")) +(def .public (format (open "/[0]")) (%.Format Value) (case /#snapshot {///.#Local} |