mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-14 17:41:33 +03:00
publish: add facilities for managing limbo state
This commit is contained in:
parent
2608dea563
commit
7edcd65699
@ -329,6 +329,11 @@
|
||||
|= [mar=mark vas=vase]
|
||||
^- (quip card _this)
|
||||
?+ mar (on-poke:def mar vas)
|
||||
::
|
||||
%noun
|
||||
?: =(q.vas %flush-limbo)
|
||||
[~ this(limbo [~ ~])]
|
||||
[~ this]
|
||||
::
|
||||
%handle-http-request
|
||||
=+ !<([id=@ta req=inbound-request:eyre] vas)
|
||||
@ -364,7 +369,45 @@
|
||||
==
|
||||
::
|
||||
++ on-leave on-leave:def
|
||||
++ on-peek on-peek:def
|
||||
++ on-peek
|
||||
|= pax=path
|
||||
^- (unit (unit cage))
|
||||
?+ pax (on-peek:def pax)
|
||||
::
|
||||
[%t %limbo ~]
|
||||
:^ ~ ~ %noun
|
||||
!> ^- (list path)
|
||||
%+ weld
|
||||
%+ turn ~(tap by notes.limbo)
|
||||
|= [[who=@p book=@tas note=@tas] *]
|
||||
^- path
|
||||
/(scot %p who)/[book]/[note]
|
||||
%+ turn ~(tap by comments.limbo)
|
||||
|= [[who=@p book=@tas note=@tas comment=@da] *]
|
||||
^- path
|
||||
/(scot %p who)/[book]/[note]/(scot %ds comment)
|
||||
::
|
||||
[%x %limbo @ @ @ ~]
|
||||
=/ host=(unit @p) (slaw %p i.t.t.pax)
|
||||
?~ host [~ ~]
|
||||
=/ book-name i.t.t.t.pax
|
||||
=/ note-name i.t.t.t.t.pax
|
||||
=/ note (~(get by notes.limbo) u.host book-name note-name)
|
||||
?~ note ~
|
||||
``noun+!>(u.note)
|
||||
::
|
||||
[%x %limbo @ @ @ @ ~]
|
||||
=/ host=(unit @p) (slaw %p i.t.t.pax)
|
||||
=/ comment-date=(unit @da) (slaw %da i.t.t.t.t.t.pax)
|
||||
?~ host [~ ~]
|
||||
?~ comment-date [~ ~]
|
||||
=/ book-name i.t.t.t.pax
|
||||
=/ note-name i.t.t.t.t.pax
|
||||
=/ comment
|
||||
(~(get by comments.limbo) u.host book-name note-name u.comment-date)
|
||||
?~ comment ~
|
||||
``noun+!>(u.comment)
|
||||
==
|
||||
::
|
||||
++ on-agent
|
||||
|= [wir=wire sin=sign:agent:gall]
|
||||
|
Loading…
Reference in New Issue
Block a user