mirror of
https://github.com/urbit/shrub.git
synced 2024-11-28 13:54:20 +03:00
graph-store: mark unmarked graphs
This commit is contained in:
parent
829cd509b4
commit
fbf505c0d9
@ -7,14 +7,17 @@
|
||||
+$ card card:agent:gall
|
||||
+$ versioned-state
|
||||
$% state-0
|
||||
state-1
|
||||
==
|
||||
::
|
||||
+$ state-0 [%0 network:store]
|
||||
+$ state-1 [%1 network:store]
|
||||
::
|
||||
++ orm orm:store
|
||||
++ orm-log orm-log:store
|
||||
--
|
||||
::
|
||||
=| state-0
|
||||
=| state-1
|
||||
=* state -
|
||||
::
|
||||
%- agent:dbug
|
||||
@ -27,9 +30,27 @@
|
||||
++ on-init [~ this]
|
||||
++ on-save !>(state)
|
||||
++ on-load
|
||||
|= old=vase
|
||||
|= =old=vase
|
||||
^- (quip card _this)
|
||||
[~ this(state !<(state-0 old))]
|
||||
=+ !<(old=versioned-state old-vase)
|
||||
=| cards=(list card)
|
||||
|-
|
||||
?- -.old
|
||||
%0
|
||||
%_ $
|
||||
-.old %1
|
||||
::
|
||||
graphs.old
|
||||
%- ~(run by graphs.old)
|
||||
|= [=graph:store q=(unit mark)]
|
||||
^- [graph:store (unit mark)]
|
||||
:- graph
|
||||
?^ q q
|
||||
`%graph-validator-link
|
||||
==
|
||||
::
|
||||
%1 [cards this(state old)]
|
||||
==
|
||||
::
|
||||
++ on-watch
|
||||
~/ %graph-store-watch
|
||||
|
@ -336,8 +336,10 @@
|
||||
%^ put:orm:graph-store
|
||||
*graph:graph-store %1
|
||||
=/ body=@t
|
||||
=/ file
|
||||
(trip file.note)
|
||||
=/ idx
|
||||
(find ";>" file.note)
|
||||
(find ";>" file)
|
||||
?~ idx
|
||||
file.note
|
||||
%- crip
|
||||
|
Loading…
Reference in New Issue
Block a user