(.require [library [lux (.except) [abstract [monad (.only do)] [predicate (.only Predicate)]] [control [concurrency ["[0]" async (.only Async)]]] [data ["[0]" binary ["[1]" \\format]] ["[0]" text [encoding ["[0]" utf8]]] [collection ["[0]" set]] [format ["[0]" tar] ["[0]" xml]]] [tool [compiler [meta ["[0]" export]]]] [world [console (.only Console)] ["[0]" file]]]] ["[0]" //// [command (.only Command)] ["/" profile] ["[1][0]" action] ["[1][0]" pom] ["[1][0]" package] ["[1][0]" dependency ["[1]/[0]" deployment] ["[1]/[0]" status]] ["[1][0]" repository (.only Repository) ["[1]/[0]" origin]] ["[1][0]" artifact (.only Artifact) ["[1]/[0]" type]]]) (def .public snapshot? (Predicate Artifact) (|>> (the ////artifact.#version) (text.contains? "-SNAPSHOT"))) (def .public (do! console remote fs artifact profile) (-> (Console Async) (Repository Async) (file.System Async) Artifact (Command Any)) (do [! ////action.monad] [library (|> profile (the /.#sources) set.list (export.library fs) (at ! each (binary.result tar.format))) pom (at async.monad in (////pom.write profile)) _ (////dependency/deployment.one remote [artifact ////artifact/type.lux_library] (let [pom_data (|> pom (at xml.codec encoded) (at utf8.codec encoded))] [////package.#origin {////repository/origin.#Remote ""} ////package.#library [library (////dependency/status.verified library)] ////package.#pom [pom pom_data (////dependency/status.verified pom_data)]]))] (in [])))