urbit/pkg/arvo/gen/desk-jam.hoon

27 lines
529 B
Plaintext
Raw Normal View History

:: +desk-jam: jam ankh from desk
::
2021-09-22 02:13:54 +03:00
=, clay
=>
|%
++ ankh-to-map
=| res=(map path page)
=| pax=path
|= a=ankh
^- (map path page)
=? res ?=(^ fil.a) (~(put by res) pax [p q.q]:q.u.fil.a)
=/ dir=(list [seg=@ta =ankh]) ~(tap by dir.a)
|- ^+ res
?~ dir res
$(dir t.dir, res ^$(pax (snoc pax seg.i.dir), a ankh.i.dir))
--
:- %say
|= $: [now=@da eny=@uvJ bec=beak]
[=desk ~]
~
==
:- %jam
%- jam
2021-09-22 02:13:54 +03:00
%- ankh-to-map
=< ank
.^(dome:clay %cv /(scot %p p.bec)/[desk]/(scot %da now))