From e153b011bb94ba95474505c307873616bb493b6d Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Sat, 24 Oct 2020 21:44:21 -0400 Subject: Changed type-parameters for Mixin types. --- stdlib/source/program/aedifex/command/pom.lux | 35 +++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 stdlib/source/program/aedifex/command/pom.lux (limited to 'stdlib/source/program/aedifex/command/pom.lux') diff --git a/stdlib/source/program/aedifex/command/pom.lux b/stdlib/source/program/aedifex/command/pom.lux new file mode 100644 index 000000000..f493092a5 --- /dev/null +++ b/stdlib/source/program/aedifex/command/pom.lux @@ -0,0 +1,35 @@ +(.module: + [lux #* + [abstract + [monad (#+ do)]] + [control + ["." try (#+ Try)] + [security + ["!" capability]] + [concurrency + ["." promise (#+ Promise) ("#@." monad)]]] + [data + ["." text + ["%" format (#+ format)] + ["." encoding]] + [format + ["." xml]]] + [world + ["." file (#+ Path File)]]] + ["." /// #_ + [command (#+ Command)] + ["#." action (#+ Action)] + ["#." pom]]) + +(def: #export (do! fs profile) + (-> (file.System Promise) (Command Path)) + (do ///action.monad + [pom (promise@wrap (///pom.write profile)) + file (: (Promise (Try (File Promise))) + (file.get-file promise.monad fs ///pom.file)) + outcome (|> pom + (:: xml.codec encode) + encoding.to-utf8 + (!.use (:: file over-write))) + #let [_ (log! "Successfully wrote POM file!")]] + (wrap ///pom.file))) -- cgit v1.2.3