From 9e2f1e76f2c8df01ed7687d934c3210fcf676bd6 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Thu, 16 Jun 2022 00:48:19 -0400 Subject: De-sigil-ification: suffix : [Part 13] --- stdlib/source/program/aedifex/repository/local.lux | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'stdlib/source/program/aedifex/repository/local.lux') diff --git a/stdlib/source/program/aedifex/repository/local.lux b/stdlib/source/program/aedifex/repository/local.lux index 1a7fb0ffd..b491e6d12 100644 --- a/stdlib/source/program/aedifex/repository/local.lux +++ b/stdlib/source/program/aedifex/repository/local.lux @@ -20,35 +20,35 @@ ["[1][0]" local] ["[1][0]" metadata]]]) -(def: .public (root program fs) +(def .public (root program fs) (-> (Program Async) (file.System Async) file.Path) (let [/ (at fs separator)] (|> ///local.repository (text.replaced uri.separator /) (format (at program home) /)))) -(def: (path /) +(def (path /) (-> Text (-> URI file.Path)) (text.replaced uri.separator /)) -(def: (absolute_path program fs) +(def (absolute_path program fs) (-> (Program Async) (file.System Async) (-> URI file.Path)) (let [/ (at fs separator)] (|>> ///metadata.local_uri (..path /) (format (..root program fs) /)))) -(def: .public (repository program fs) +(def .public (repository program fs) (-> (Program Async) (file.System Async) (//.Repository Async)) (implementation - (def: description + (def description (..root program fs)) - (def: download + (def download (|>> (..absolute_path program fs) (at fs read))) - (def: (upload uri content) + (def (upload uri content) (do [! async.monad] [.let [absolute_path (..absolute_path program fs uri)] ? (at fs file? absolute_path) -- cgit v1.2.3