2018-05-16 20:20:28 +03:00
|
|
|
::
|
2018-08-29 01:13:26 +03:00
|
|
|
:::: /app/collections/hoon
|
|
|
|
::
|
2018-07-31 07:00:49 +03:00
|
|
|
/? 309
|
|
|
|
/- hall
|
2018-11-07 09:46:39 +03:00
|
|
|
/+ collections
|
2018-08-29 01:13:26 +03:00
|
|
|
::
|
|
|
|
:: cols:
|
|
|
|
::
|
|
|
|
:: run collections-item renderer on children of /web/collections
|
2018-09-07 02:39:02 +03:00
|
|
|
:: combine with a bunted config in a +collection structure defined in
|
|
|
|
:: /lib/collections because the top level collection has no config file
|
2018-08-29 01:13:26 +03:00
|
|
|
::
|
2018-09-07 02:39:02 +03:00
|
|
|
:: whenever any of the clay files that compose this renderer change, this app
|
|
|
|
:: will recompile and the +prep arm will fire. we then check which files
|
|
|
|
:: changed and notify the corresponding hall circle of that change
|
2018-08-29 01:13:26 +03:00
|
|
|
::
|
2018-07-31 07:00:49 +03:00
|
|
|
/= cols
|
|
|
|
/^ collection:collections
|
|
|
|
/; |= a=(map knot item:collections)
|
|
|
|
[*config:collections a]
|
2018-08-01 02:31:30 +03:00
|
|
|
/: /===/web/collections /_ /collections-item/
|
2017-12-02 21:45:47 +03:00
|
|
|
::
|
2018-07-31 07:00:49 +03:00
|
|
|
=, collections
|
|
|
|
=, space:userlib
|
2017-12-02 21:45:47 +03:00
|
|
|
::
|
2018-08-29 01:13:26 +03:00
|
|
|
:: state:
|
|
|
|
::
|
2018-09-07 02:39:02 +03:00
|
|
|
:: stores the collection built by above by :cols so that we can compare old
|
|
|
|
:: and new versions whenever the rendered data changes
|
2018-08-29 01:13:26 +03:00
|
|
|
::
|
2018-11-13 21:38:56 +03:00
|
|
|
~% %landscape ..^is ~
|
2018-11-07 09:46:39 +03:00
|
|
|
|_ [bol=bowl:gall sta=state]
|
2017-12-14 03:04:45 +03:00
|
|
|
::
|
2018-08-29 01:13:26 +03:00
|
|
|
:: +this: app core subject
|
|
|
|
::
|
2018-07-31 07:00:49 +03:00
|
|
|
++ this .
|
2017-12-02 21:45:47 +03:00
|
|
|
::
|
2018-08-29 01:13:26 +03:00
|
|
|
:: +prep:
|
|
|
|
::
|
|
|
|
:: on initial boot, create top level hall circle for collections, called %c
|
|
|
|
::
|
|
|
|
:: on subsequent compiles, call +ta-update:ta on the old collection data,
|
|
|
|
:: then update state to store the new collection data
|
|
|
|
::
|
2018-07-31 07:00:49 +03:00
|
|
|
++ prep
|
2018-11-13 21:38:56 +03:00
|
|
|
~/ %land-prep
|
2018-11-07 09:46:39 +03:00
|
|
|
|= old=(unit state)
|
2018-07-31 07:00:49 +03:00
|
|
|
^- (quip move _this)
|
|
|
|
?~ old
|
2018-11-07 09:46:39 +03:00
|
|
|
:_ this
|
2018-11-13 21:38:56 +03:00
|
|
|
;: welp
|
|
|
|
=< ta-done
|
|
|
|
(~(ta-hall-create-circle ta ~ bol) /c 'collections')
|
|
|
|
::
|
2018-11-16 01:34:46 +03:00
|
|
|
:* [ost.bol %peer /circles [our.bol %hall] /circles/[(scot %p our.bol)]]
|
2018-11-13 21:38:56 +03:00
|
|
|
[ost.bol %peer /inbox [our.bol %hall] /circle/inbox/config/grams]
|
|
|
|
[ost.bol %peer /invites [our.bol %hall] /circle/i/grams]
|
2018-11-16 01:34:46 +03:00
|
|
|
::
|
|
|
|
?. =(%duke (clan:title our.bol))
|
|
|
|
~
|
|
|
|
:_ ~
|
|
|
|
:* ost.bol %poke /client-action [our.bol %hall]
|
|
|
|
%hall-action %source %inbox &
|
|
|
|
(sy [[(^sein:title our.bol) %urbit-meta] ~]~)
|
|
|
|
==
|
2018-11-13 21:38:56 +03:00
|
|
|
==
|
|
|
|
==
|
2018-11-07 09:46:39 +03:00
|
|
|
?- -.u.old
|
|
|
|
%0
|
|
|
|
=/ mow=(list move)
|
|
|
|
=< ta-done
|
|
|
|
(~(ta-update ta ~ bol) col.u.old cols)
|
2018-11-13 21:38:56 +03:00
|
|
|
:- mow
|
|
|
|
%= this
|
|
|
|
sta [%0 cols str.u.old]
|
|
|
|
==
|
2018-11-07 09:46:39 +03:00
|
|
|
==
|
2017-12-02 21:45:47 +03:00
|
|
|
::
|
2018-09-07 02:39:02 +03:00
|
|
|
:: +mack:
|
|
|
|
::
|
|
|
|
:: recieve acknowledgement for permissions changes, print error if it failed
|
2017-12-02 21:45:47 +03:00
|
|
|
::
|
2018-07-31 07:00:49 +03:00
|
|
|
++ mack
|
|
|
|
|= [wir=wire err=(unit tang)]
|
|
|
|
^- (quip move _this)
|
|
|
|
?~ err
|
|
|
|
[~ this]
|
|
|
|
(mean u.err)
|
2018-03-06 04:35:33 +03:00
|
|
|
::
|
2018-08-29 01:13:26 +03:00
|
|
|
:: +coup: recieve acknowledgement for poke, print error if it failed
|
|
|
|
::
|
|
|
|
++ coup
|
|
|
|
|= [wir=wire err=(unit tang)]
|
|
|
|
^- (quip move _this)
|
|
|
|
?~ err
|
|
|
|
[~ this]
|
|
|
|
(mean u.err)
|
|
|
|
::
|
|
|
|
:: +poke-collections-action:
|
2018-07-31 07:00:49 +03:00
|
|
|
::
|
2018-09-07 03:31:06 +03:00
|
|
|
:: the main interface for creating and deleting collections and items
|
2018-07-31 07:00:49 +03:00
|
|
|
::
|
2018-08-01 21:32:34 +03:00
|
|
|
++ poke-collections-action
|
2018-11-02 06:26:15 +03:00
|
|
|
~/ %coll-poke-collections-action
|
2018-11-07 09:46:39 +03:00
|
|
|
|= act=action
|
2018-07-31 07:00:49 +03:00
|
|
|
^- (quip move _this)
|
2018-08-21 00:16:57 +03:00
|
|
|
?: =(who.act our.bol)
|
2018-11-07 09:46:39 +03:00
|
|
|
:_ this
|
|
|
|
=< ta-done
|
|
|
|
(~(ta-act ta ~ bol) act)
|
2018-08-21 00:16:57 +03:00
|
|
|
:: forward poke if its not meant for us
|
2018-08-29 01:13:26 +03:00
|
|
|
::
|
2018-08-21 00:16:57 +03:00
|
|
|
:_ this
|
|
|
|
:_ ~
|
|
|
|
:* ost.bol %poke
|
|
|
|
/forward-collections-action
|
|
|
|
[who.act %collections]
|
|
|
|
%collections-action act
|
2017-12-02 21:45:47 +03:00
|
|
|
==
|
2018-07-31 07:00:49 +03:00
|
|
|
::
|
2018-11-07 09:36:03 +03:00
|
|
|
:: +poke-json
|
2018-09-05 04:01:17 +03:00
|
|
|
::
|
|
|
|
:: utility for setting whether or not to display the onboarding page
|
|
|
|
::
|
2018-11-07 09:36:03 +03:00
|
|
|
++ poke-json
|
2018-11-02 06:26:15 +03:00
|
|
|
~/ %coll-poke-json
|
2018-11-07 09:36:03 +03:00
|
|
|
|= jon=json
|
2018-09-05 04:01:17 +03:00
|
|
|
^- (quip move _this)
|
2018-11-07 09:36:03 +03:00
|
|
|
?: ?=([%o [[%onboard %b ?] ~ ~]] jon)
|
2018-11-07 09:46:39 +03:00
|
|
|
:_ this
|
2018-11-07 09:36:03 +03:00
|
|
|
=< ta-done
|
2018-11-07 09:46:39 +03:00
|
|
|
(~(ta-write ta ~ bol) /web/landscape/onboard/json [%json !>(jon)])
|
2018-11-07 09:36:03 +03:00
|
|
|
[~ this]
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
2018-11-16 01:34:46 +03:00
|
|
|
:: +peer:
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
|
|
|
++ peer
|
|
|
|
|= wir=wire
|
|
|
|
^- (quip move _this)
|
2018-11-16 01:34:46 +03:00
|
|
|
:_ this
|
|
|
|
[ost.bol %diff %collections-prize str.sta]~
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
|
|
|
:: +reap: recieve acknowledgement for peer, retry on failure
|
|
|
|
::
|
|
|
|
++ reap
|
|
|
|
|= [wir=wire err=(unit tang)]
|
|
|
|
^- (quip move _this)
|
2018-11-16 01:34:46 +03:00
|
|
|
~& reap+[wir =(~ err)]
|
2018-11-13 21:38:56 +03:00
|
|
|
?~ err
|
|
|
|
[~ this]
|
|
|
|
?~ wir
|
|
|
|
(mean [leaf+"invalid wire for diff: {(spud wir)}"]~)
|
|
|
|
?+ i.wir
|
|
|
|
(mean [leaf+"invalid wire for diff: {(spud wir)}"]~)
|
|
|
|
::
|
|
|
|
%circles
|
|
|
|
:_ this
|
|
|
|
[ost.bol %peer /circles [our.bol %hall] /circles/[(scot %p our.bol)]]~
|
|
|
|
::
|
|
|
|
%inbox
|
|
|
|
:_ this
|
|
|
|
[ost.bol %peer /inbox [our.bol %hall] /circle/inbox/config/grams]~
|
|
|
|
::
|
|
|
|
%invites
|
|
|
|
:_ this
|
|
|
|
[ost.bol %peer /invites [our.bol %hall] /circle/i/grams]~
|
|
|
|
::
|
|
|
|
%our
|
|
|
|
[~ this]
|
|
|
|
==
|
|
|
|
::
|
|
|
|
:: +quit:
|
|
|
|
::
|
|
|
|
++ quit
|
|
|
|
|= [wir=wire err=(unit tang)]
|
|
|
|
^- (quip move _this)
|
2018-11-16 01:34:46 +03:00
|
|
|
~& quit+[wir =(~ err)]
|
2018-11-13 21:38:56 +03:00
|
|
|
?~ err
|
|
|
|
[~ this]
|
|
|
|
?~ wir
|
|
|
|
(mean [leaf+"invalid wire for diff: {(spud wir)}"]~)
|
|
|
|
?+ i.wir
|
|
|
|
(mean [leaf+"invalid wire for diff: {(spud wir)}"]~)
|
|
|
|
::
|
|
|
|
%circles
|
|
|
|
:_ this
|
|
|
|
[ost.bol %peer /circles [our.bol %hall] /circles/[(scot %p our.bol)]]~
|
|
|
|
::
|
|
|
|
%inbox
|
|
|
|
:_ this
|
|
|
|
[ost.bol %peer /inbox [our.bol %hall] /circle/inbox/config/grams]~
|
|
|
|
::
|
|
|
|
%invites
|
|
|
|
:_ this
|
|
|
|
[ost.bol %peer /invites [our.bol %hall] /circle/i/grams]~
|
|
|
|
::
|
|
|
|
%our
|
|
|
|
[~ this]
|
|
|
|
==
|
|
|
|
::
|
|
|
|
:: +diff-hall-prize:
|
|
|
|
::
|
|
|
|
++ diff-hall-prize
|
|
|
|
|= [wir=wire piz=prize:hall]
|
|
|
|
^- (quip move _this)
|
2018-11-16 01:34:46 +03:00
|
|
|
::
|
|
|
|
::
|
|
|
|
~& prize+[wir piz]
|
2018-11-13 21:38:56 +03:00
|
|
|
?~ wir
|
|
|
|
(mean [leaf+"invalid wire for diff: {(spud wir)}"]~)
|
|
|
|
?+ i.wir
|
|
|
|
(mean [leaf+"invalid wire for diff: {(spud wir)}"]~)
|
|
|
|
::
|
|
|
|
:: %circles: subscribe to the configuration of each of our circles
|
|
|
|
::
|
|
|
|
%circles
|
|
|
|
?> ?=(%circles -.piz)
|
2018-11-16 01:34:46 +03:00
|
|
|
=/ noms=(set name:hall) (~(dif in cis.piz) (sy ~[%inbox %i %public]))
|
2018-11-21 22:26:43 +03:00
|
|
|
:_ this(our-circles.str.sta (~(uni in our-circles.str.sta) noms))
|
2018-11-13 21:38:56 +03:00
|
|
|
^- (list move)
|
2018-11-16 01:34:46 +03:00
|
|
|
%+ turn ~(tap in noms)
|
|
|
|
|= nom=name:hall
|
2018-11-13 21:38:56 +03:00
|
|
|
^- move
|
2018-11-16 01:34:46 +03:00
|
|
|
[ost.bol %peer /our/[nom] [our.bol %hall] /circle/[nom]/config]
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
2018-11-16 01:34:46 +03:00
|
|
|
:: %inbox: fill inbox config, messages and remote configs with prize data
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
|
|
|
%inbox
|
2018-11-16 01:34:46 +03:00
|
|
|
?> ?=(%circle -.piz)
|
|
|
|
:- ~
|
2018-11-21 22:26:43 +03:00
|
|
|
%= this
|
|
|
|
con.inbox.str.sta `loc.cos.piz
|
|
|
|
::
|
|
|
|
env.inbox.str.sta nes.piz
|
|
|
|
::
|
|
|
|
circles.str.sta
|
|
|
|
%- ~(uni in circles.str.sta)
|
|
|
|
^- (map circle:hall (unit config:hall))
|
|
|
|
(~(run by rem.cos.piz) |=(a=config:hall `a))
|
2018-11-16 01:34:46 +03:00
|
|
|
==
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
2018-11-16 01:34:46 +03:00
|
|
|
:: %invites: fill invite messages with prize data
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
|
|
|
%invites
|
2018-11-16 01:34:46 +03:00
|
|
|
?> ?=(%circle -.piz)
|
|
|
|
:- ~
|
|
|
|
%= this
|
|
|
|
invites.str.sta nes.piz
|
|
|
|
==
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
2018-11-16 01:34:46 +03:00
|
|
|
:: %our:
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
2018-11-16 01:34:46 +03:00
|
|
|
%our
|
|
|
|
?> ?=(%circle -.piz)
|
|
|
|
=/ nom=name:hall &2:wir
|
2018-11-21 22:26:43 +03:00
|
|
|
:: XX todo: send rumor or let config-change handle it?
|
|
|
|
::
|
2018-11-16 01:34:46 +03:00
|
|
|
:- ~
|
2018-11-21 22:26:43 +03:00
|
|
|
%= this
|
|
|
|
circles.str.sta
|
|
|
|
(~(put by circles.str.sta) [our.bol nom] `loc.cos.piz)
|
|
|
|
::
|
|
|
|
our-circles.str.sta (~(put in our-circles.str.sta) nom)
|
2018-11-16 01:34:46 +03:00
|
|
|
==
|
2018-11-13 21:38:56 +03:00
|
|
|
==
|
|
|
|
::
|
|
|
|
:: +diff-hall-rumor
|
|
|
|
::
|
|
|
|
++ diff-hall-rumor
|
|
|
|
|= [wir=wire rum=rumor:hall]
|
|
|
|
^- (quip move _this)
|
2018-11-16 01:34:46 +03:00
|
|
|
~& rumor+[wir rum]
|
2018-11-13 21:38:56 +03:00
|
|
|
?~ wir
|
|
|
|
(mean [leaf+"invalid wire for diff: {(spud wir)}"]~)
|
|
|
|
?+ i.wir
|
|
|
|
(mean [leaf+"invalid wire for diff: {(spud wir)}"]~)
|
2018-11-16 01:34:46 +03:00
|
|
|
::
|
|
|
|
:: %circles:
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
|
|
|
%circles
|
2018-11-21 22:26:43 +03:00
|
|
|
~& %circles
|
2018-11-16 01:34:46 +03:00
|
|
|
?> ?=(%circles -.rum)
|
|
|
|
?: add.rum
|
2018-11-21 22:26:43 +03:00
|
|
|
:_ this(our-circles.str.sta (~(put in our-circles.str.sta) cir.rum))
|
2018-11-16 01:34:46 +03:00
|
|
|
[ost.bol %peer /our/[cir.rum] [our.bol %hall] /circle/[cir.rum]/config]~
|
2018-11-21 22:26:43 +03:00
|
|
|
:_ this(our-circles.str.sta (~(del in our-circles.str.sta) cir.rum))
|
|
|
|
[ost.bol %pull /our/[cir.rum] [our.bol %hall] ~]~
|
2018-11-16 01:34:46 +03:00
|
|
|
::
|
|
|
|
:: %inbox:
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
|
|
|
%inbox
|
2018-11-16 01:34:46 +03:00
|
|
|
?> ?=(%circle -.rum)
|
|
|
|
?+ -.rum.rum
|
2018-11-21 22:26:43 +03:00
|
|
|
~& inbox-unprocessed-rumor+rum.rum
|
2018-11-16 01:34:46 +03:00
|
|
|
[~ this]
|
|
|
|
::
|
|
|
|
:: %remove:
|
|
|
|
::
|
|
|
|
%remove
|
2018-11-21 22:26:43 +03:00
|
|
|
~& %inbox-remove
|
2018-11-16 01:34:46 +03:00
|
|
|
~& %removed-story
|
|
|
|
[~ this]
|
|
|
|
::
|
|
|
|
:: %gram: inbox has recieved messages
|
|
|
|
::
|
|
|
|
%gram
|
2018-11-21 22:26:43 +03:00
|
|
|
~& %inbox-gram
|
|
|
|
:: XX TODO: handle stack trace message when foreign circle is killed?
|
|
|
|
::
|
2018-11-16 01:34:46 +03:00
|
|
|
:- (send-rumor [%new-msg %inbox nev.rum.rum])
|
|
|
|
this(env.inbox.str.sta [nev.rum.rum env.inbox.str.sta])
|
|
|
|
::
|
|
|
|
:: %config: inbox config has changed
|
|
|
|
::
|
|
|
|
%config
|
|
|
|
=* circ cir.rum.rum
|
|
|
|
?+ -.dif.rum.rum
|
2018-11-21 22:26:43 +03:00
|
|
|
~& inbox-unprocessed-config+dif.rum.rum
|
2018-11-16 01:34:46 +03:00
|
|
|
[~ this]
|
|
|
|
::
|
2018-11-21 22:26:43 +03:00
|
|
|
:: %remove: circle has been erased
|
|
|
|
::
|
|
|
|
%remove
|
|
|
|
~& %inbox-config-remove
|
|
|
|
:- (send-rumor %config-change cir.rum.rum ~)
|
|
|
|
%= this
|
|
|
|
circles.str.sta
|
|
|
|
(~(del by circles.str.sta) cir.rum.rum)
|
|
|
|
==
|
|
|
|
::
|
2018-11-16 01:34:46 +03:00
|
|
|
:: %source: the sources of our inbox have changed
|
|
|
|
::
|
|
|
|
%source
|
2018-11-21 22:26:43 +03:00
|
|
|
~& %inbox-config-source
|
2018-11-20 01:37:00 +03:00
|
|
|
?. =(circ [our.bol %inbox])
|
|
|
|
[~ this]
|
2018-11-16 01:34:46 +03:00
|
|
|
:: we've added a source to our inbox
|
|
|
|
::
|
2018-11-21 22:26:43 +03:00
|
|
|
?> ?=(^ con.inbox.str.sta)
|
2018-11-16 01:34:46 +03:00
|
|
|
?: add.dif.rum.rum
|
2018-11-20 01:37:00 +03:00
|
|
|
=/ conf=config:hall
|
|
|
|
%= u.con.inbox.str.sta
|
2018-11-21 22:26:43 +03:00
|
|
|
src (~(put in src.u.con.inbox.str.sta) src.dif.rum.rum)
|
2018-11-20 01:37:00 +03:00
|
|
|
==
|
2018-11-21 22:26:43 +03:00
|
|
|
:- (send-rumor %config-change [our.bol %inbox] `conf)
|
|
|
|
%= this
|
|
|
|
con.inbox.str.sta `conf
|
2018-11-20 01:37:00 +03:00
|
|
|
::
|
2018-11-21 22:26:43 +03:00
|
|
|
circles.str.sta
|
|
|
|
?: (~(has by circles.str.sta) cir.src.dif.rum.rum)
|
|
|
|
circles.str.sta
|
|
|
|
(~(put by circles.str.sta) cir.src.dif.rum.rum ~)
|
2018-11-16 01:34:46 +03:00
|
|
|
==
|
|
|
|
:: we've removed a source from our inbox
|
|
|
|
::
|
2018-11-21 22:26:43 +03:00
|
|
|
=/ conf=config:hall
|
|
|
|
%= u.con.inbox.str.sta
|
|
|
|
src (~(del in src.u.con.inbox.str.sta) src.dif.rum.rum)
|
|
|
|
==
|
|
|
|
~& inbox+conf
|
|
|
|
:- (send-rumor %config-change [our.bol %inbox] `conf)
|
|
|
|
%= this
|
|
|
|
con.inbox.str.sta `conf
|
|
|
|
::
|
|
|
|
circles.str.sta
|
|
|
|
?: =(our.bol hos.cir.src.dif.rum.rum)
|
|
|
|
circles.str.sta
|
|
|
|
(~(del by circles.str.sta) cir.src.dif.rum.rum)
|
2018-11-16 01:34:46 +03:00
|
|
|
==
|
|
|
|
::
|
|
|
|
:: %full: recieved a full config update for one of our sources
|
|
|
|
::
|
|
|
|
%full
|
2018-11-21 22:26:43 +03:00
|
|
|
~& %inbox-config-full
|
2018-11-16 01:34:46 +03:00
|
|
|
=* conf cof.dif.rum.rum
|
2018-11-21 22:26:43 +03:00
|
|
|
:- (send-rumor %config-change circ `conf)
|
2018-11-16 01:34:46 +03:00
|
|
|
%= this
|
2018-11-21 22:26:43 +03:00
|
|
|
circles.str.sta (~(put by circles.str.sta) circ `conf)
|
2018-11-16 01:34:46 +03:00
|
|
|
==
|
|
|
|
==
|
|
|
|
==
|
|
|
|
::
|
|
|
|
:: %invites:
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
|
|
|
%invites
|
2018-11-21 22:26:43 +03:00
|
|
|
~& %invites
|
2018-11-16 01:34:46 +03:00
|
|
|
?> ?=(%circle -.rum)
|
|
|
|
?> ?=(%gram -.rum.rum)
|
|
|
|
:- (send-rumor [%new-msg %invites nev.rum.rum])
|
|
|
|
this(invites.str.sta [nev.rum.rum invites.str.sta])
|
|
|
|
::
|
|
|
|
:: %our:
|
2018-11-13 21:38:56 +03:00
|
|
|
::
|
|
|
|
%our
|
2018-11-16 01:34:46 +03:00
|
|
|
?> ?=(%circle -.rum)
|
|
|
|
?+ -.rum.rum
|
2018-11-21 22:26:43 +03:00
|
|
|
~& our-unprocessed-rumor+rum.rum
|
2018-11-16 01:34:46 +03:00
|
|
|
[~ this]
|
|
|
|
::
|
|
|
|
:: %remove:
|
|
|
|
::
|
|
|
|
%remove
|
2018-11-21 22:26:43 +03:00
|
|
|
~& %our-remove
|
2018-11-16 01:34:46 +03:00
|
|
|
[~ this]
|
|
|
|
::
|
|
|
|
:: %config:
|
|
|
|
::
|
|
|
|
%config
|
|
|
|
=* circ cir.rum.rum
|
|
|
|
=* diff dif.rum.rum
|
|
|
|
?+ -.diff
|
2018-11-21 22:26:43 +03:00
|
|
|
~& our-unprocessed-config+diff
|
2018-11-16 01:34:46 +03:00
|
|
|
[~ this]
|
|
|
|
::
|
|
|
|
:: %full: recieved a full config update for one of our sources
|
|
|
|
::
|
|
|
|
%full
|
2018-11-21 22:26:43 +03:00
|
|
|
~& %our-config-full
|
2018-11-16 01:34:46 +03:00
|
|
|
=* conf cof.dif.rum.rum
|
2018-11-21 22:26:43 +03:00
|
|
|
:- (send-rumor %config-change circ `conf)
|
2018-11-16 01:34:46 +03:00
|
|
|
%= this
|
2018-11-21 22:26:43 +03:00
|
|
|
circles.str.sta (~(put by circles.str.sta) circ `conf)
|
2018-11-16 01:34:46 +03:00
|
|
|
==
|
|
|
|
==
|
|
|
|
==
|
|
|
|
==
|
|
|
|
::
|
|
|
|
:: +send-rumor: send a rumor to all subscribers
|
|
|
|
::
|
|
|
|
++ send-rumor
|
|
|
|
|= rum=rumor
|
2018-11-21 22:26:43 +03:00
|
|
|
~& send-rumor+rum
|
2018-11-16 01:34:46 +03:00
|
|
|
^- (list move)
|
2018-11-21 22:26:43 +03:00
|
|
|
%+ turn (prey:pubsub:userlib /primary bol)
|
2018-11-16 01:34:46 +03:00
|
|
|
|= [=bone *]
|
|
|
|
[bone %diff %collections-rumor rum]
|
|
|
|
::
|
|
|
|
:: +poke-noun: debugging stuff
|
|
|
|
::
|
|
|
|
++ poke-noun
|
|
|
|
|= a=@t
|
|
|
|
^- (quip move _this)
|
|
|
|
?: =(a 'check all subs')
|
|
|
|
~& 'here are all incoming subs'
|
|
|
|
~& ^- (list (pair ship path))
|
|
|
|
%+ turn ~(tap by sup.bol)
|
|
|
|
|= [b=bone s=ship p=path]
|
|
|
|
^- (pair ship path)
|
|
|
|
[s p]
|
2018-11-13 21:38:56 +03:00
|
|
|
[~ this]
|
|
|
|
::
|
2018-11-16 01:34:46 +03:00
|
|
|
?: =(a 'print state')
|
|
|
|
~& str.sta
|
2018-11-13 21:38:56 +03:00
|
|
|
[~ this]
|
2018-11-16 01:34:46 +03:00
|
|
|
[~ this]
|
2017-12-02 21:45:47 +03:00
|
|
|
--
|
2018-11-13 21:38:56 +03:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|