diff options
author | Eduardo Julian | 2021-09-12 00:07:08 -0400 |
---|---|---|
committer | Eduardo Julian | 2021-09-12 00:07:08 -0400 |
commit | dda05bca0956af5e5b3875c4cc36e61aa04772e4 (patch) | |
tree | 0f8b27697d58ab5c8e41aba7c7c9f769d3800767 /stdlib/source/program/aedifex/metadata | |
parent | d48270f43c404ba19ca04da2553455ecaaf2caba (diff) |
Made the "#" character great again!
Diffstat (limited to '')
-rw-r--r-- | stdlib/source/program/aedifex/metadata.lux | 10 | ||||
-rw-r--r-- | stdlib/source/program/aedifex/metadata/artifact.lux | 40 | ||||
-rw-r--r-- | stdlib/source/program/aedifex/metadata/snapshot.lux | 32 |
3 files changed, 41 insertions, 41 deletions
diff --git a/stdlib/source/program/aedifex/metadata.lux b/stdlib/source/program/aedifex/metadata.lux index d0dbba2ba..83320d752 100644 --- a/stdlib/source/program/aedifex/metadata.lux +++ b/stdlib/source/program/aedifex/metadata.lux @@ -18,16 +18,16 @@ (def: .public (remote_artifact_uri artifact) (-> Artifact URI) (let [/ uri.separator] - (format (//artifact.directory / (value@ #//artifact.group artifact)) - / (value@ #//artifact.name artifact) - / (value@ #//artifact.version artifact) + (format (//artifact.directory / (value@ //artifact.#group artifact)) + / (value@ //artifact.#name artifact) + / (value@ //artifact.#version artifact) / ..remote_file))) (def: .public (remote_project_uri artifact) (-> Artifact URI) (let [/ uri.separator] - (format (//artifact.directory / (value@ #//artifact.group artifact)) - / (value@ #//artifact.name artifact) + (format (//artifact.directory / (value@ //artifact.#group artifact)) + / (value@ //artifact.#name artifact) / ..remote_file))) (def: local_file diff --git a/stdlib/source/program/aedifex/metadata/artifact.lux b/stdlib/source/program/aedifex/metadata/artifact.lux index d0bdf887e..ad0477dcc 100644 --- a/stdlib/source/program/aedifex/metadata/artifact.lux +++ b/stdlib/source/program/aedifex/metadata/artifact.lux @@ -59,10 +59,10 @@ (def: (time_format value) (%.Format Time) - (let [(^slots [#time.hour #time.minute #time.second]) (time.clock value)] - (%.format (..pad hour) - (..pad minute) - (..pad second)))) + (let [(^slots [time.#hour time.#minute time.#second]) (time.clock value)] + (%.format (..pad #hour) + (..pad #minute) + (..pad #second)))) (def: (instant_format value) (%.Format Instant) @@ -84,7 +84,7 @@ (template [<name> <type> <tag> <pre>] [(def: <name> (-> <type> XML) - (|>> <pre> {#xml.Text} list {#xml.Node <tag> xml.attributes}))] + (|>> <pre> {xml.#Text} list {xml.#Node <tag> xml.attributes}))] [group_format Group ..<group> (|>)] [name_format Name ..<name> (|>)] @@ -94,15 +94,15 @@ (def: versions_format (-> (List Version) XML) - (|>> (list\each ..version_format) {#xml.Node ..<versions> xml.attributes})) + (|>> (list\each ..version_format) {xml.#Node ..<versions> xml.attributes})) (def: .public (format value) (-> Metadata XML) - {#xml.Node ..<metadata> + {xml.#Node ..<metadata> xml.attributes (list (..group_format (value@ #group value)) (..name_format (value@ #name value)) - {#xml.Node ..<versioning> + {xml.#Node ..<versioning> xml.attributes (list (..versions_format (value@ #versions value)) (..last_updated_format (value@ #last_updated value)))})}) @@ -129,10 +129,10 @@ minute (<>.codec n.decimal (<text>.exactly 2 <text>.decimal)) second (<>.codec n.decimal (<text>.exactly 2 <text>.decimal))] (<>.lifted (time.time - [#time.hour hour - #time.minute minute - #time.second second - #time.milli_second 0])))) + [time.#hour hour + time.#minute minute + time.#second second + time.#milli_second 0])))) (def: last_updated_parser (Parser Instant) @@ -178,20 +178,20 @@ (do async.monad [project (\ repository download (..uri artifact))] (case project - {#try.Success project} + {try.#Success project} (in (|> project (do> try.monad [(\ utf8.codec decoded)] [(\ xml.codec decoded)] [list (<xml>.result ..parser)]))) - {#try.Failure error} - (in {#try.Success - (let [(^slots [#///artifact.group #///artifact.name]) artifact] - [#group group - #name name - #versions (list) - #last_updated ..epoch])})))) + {try.#Failure error} + (in {try.#Success + (let [(^slots [///artifact.#group ///artifact.#name]) artifact] + [..#group #group + ..#name #name + ..#versions (list) + ..#last_updated ..epoch])})))) (def: .public (write repository artifact metadata) (-> (Repository Async) Artifact Metadata (Async (Try Any))) diff --git a/stdlib/source/program/aedifex/metadata/snapshot.lux b/stdlib/source/program/aedifex/metadata/snapshot.lux index 05a065c6f..c840fc870 100644 --- a/stdlib/source/program/aedifex/metadata/snapshot.lux +++ b/stdlib/source/program/aedifex/metadata/snapshot.lux @@ -62,7 +62,7 @@ (template [<name> <type> <tag> <pre>] [(def: <name> (-> <type> XML) - (|>> <pre> #xml.Text list {#xml.Node <tag> xml.attributes}))] + (|>> <pre> {xml.#Text} list {xml.#Node <tag> xml.attributes}))] [group_format Group ..<group> (|>)] [name_format Name ..<name> (|>)] @@ -71,8 +71,8 @@ (def: .public (format (^slots [#artifact #versioning])) (-> Metadata XML) - (let [(^slots [#///artifact.group #///artifact.name #///artifact.version]) artifact] - {#xml.Node ..<metadata> + (let [(^slots [///artifact.#group ///artifact.#name ///artifact.#version]) artifact] + {xml.#Node ..<metadata> xml.attributes (list (..group_format group) (..name_format name) @@ -91,12 +91,12 @@ [group (<xml>.somewhere (..text ..<group>)) name (<xml>.somewhere (..text ..<name>)) version (<xml>.somewhere (..text ..<version>)) - versioning (with_expansions [<default_version> [#///artifact/snapshot/version.extension ///artifact/type.jvm_library - #///artifact/snapshot/version.value version - #///artifact/snapshot/version.updated ///artifact/time.epoch]] + versioning (with_expansions [<default_version> [///artifact/snapshot/version.#extension ///artifact/type.jvm_library + ///artifact/snapshot/version.#value version + ///artifact/snapshot/version.#updated ///artifact/time.epoch]] (|> (<xml>.somewhere ///artifact/versioning.parser) (\ ! each - (revised@ #///artifact/versioning.versions + (revised@ ///artifact/versioning.#versions (: (-> (List ///artifact/snapshot/version.Version) (List ///artifact/snapshot/version.Version)) (|>> (case> (^ (list)) @@ -104,12 +104,12 @@ versions versions))))) - (<>.else [#///artifact/versioning.snapshot #///artifact/snapshot.Local - #///artifact/versioning.last_updated ///artifact/time.epoch - #///artifact/versioning.versions (list <default_version>)])))] - (in [#artifact [#///artifact.group group - #///artifact.name name - #///artifact.version version] + (<>.else [///artifact/versioning.#snapshot {///artifact/snapshot.#Local} + ///artifact/versioning.#last_updated ///artifact/time.epoch + ///artifact/versioning.#versions (list <default_version>)])))] + (in [#artifact [///artifact.#group group + ///artifact.#name name + ///artifact.#version version] #versioning versioning])))) (def: .public equivalence @@ -128,15 +128,15 @@ (do async.monad [project (\ repository download (..uri artifact))] (case project - {#try.Success project} + {try.#Success project} (in (|> project (do> try.monad [(\ utf8.codec decoded)] [(\ xml.codec decoded)] [list (<xml>.result ..parser)]))) - {#try.Failure error} - (in {#try.Success + {try.#Failure error} + (in {try.#Success [#artifact artifact #versioning ///artifact/versioning.init]})))) |