2015-01-15 22:32:04 +03:00
|
|
|
::
|
2016-02-11 03:41:28 +03:00
|
|
|
:::: /hoon/talk/lib
|
2017-04-25 22:21:46 +03:00
|
|
|
::
|
2015-01-15 22:32:04 +03:00
|
|
|
:: This file is in the public domain.
|
|
|
|
::
|
2017-04-25 22:21:46 +03:00
|
|
|
/? 310
|
2015-09-01 23:56:42 +03:00
|
|
|
/- talk
|
2016-11-17 04:42:58 +03:00
|
|
|
::
|
2015-01-15 22:32:04 +03:00
|
|
|
::::
|
|
|
|
::
|
2017-10-19 02:59:51 +03:00
|
|
|
[. ^talk]
|
2016-12-07 06:13:33 +03:00
|
|
|
|_ bol/bowl:gall
|
2015-01-15 22:32:04 +03:00
|
|
|
++ main :: main story
|
2017-06-14 04:06:38 +03:00
|
|
|
|= who/ship
|
|
|
|
^- cord
|
2017-10-06 15:46:46 +03:00
|
|
|
=+ can=(clan:title who)
|
2015-01-15 22:32:04 +03:00
|
|
|
?+ can %porch
|
2015-12-09 04:54:26 +03:00
|
|
|
$czar %court
|
|
|
|
$king %floor
|
2017-04-25 22:21:46 +03:00
|
|
|
==
|
2015-06-02 21:36:56 +03:00
|
|
|
::
|
2017-06-13 01:19:45 +03:00
|
|
|
::TODO add to zuse?
|
|
|
|
++ true-self
|
|
|
|
|= who/ship
|
2017-10-06 20:35:25 +03:00
|
|
|
?. ?=($earl (clan:title who)) who
|
|
|
|
(sein:title who)
|
2017-06-13 01:19:45 +03:00
|
|
|
::
|
2017-06-14 03:51:10 +03:00
|
|
|
++ above
|
|
|
|
|= who/ship
|
2017-10-06 20:35:25 +03:00
|
|
|
?: ?=($czar (clan:title who)) ~zod
|
|
|
|
(sein:title who)
|
2015-06-02 21:36:56 +03:00
|
|
|
::
|
2016-03-15 03:37:34 +03:00
|
|
|
++ said-url :: app url
|
2016-12-07 06:13:33 +03:00
|
|
|
|= url/purl:eyre
|
2016-03-15 04:02:59 +03:00
|
|
|
:^ ost.bol %poke /said-url
|
2017-04-14 01:46:15 +03:00
|
|
|
:+ [our.bol %talk] %talk-action
|
|
|
|
^- action
|
|
|
|
:+ %phrase
|
2017-07-11 02:41:47 +03:00
|
|
|
[[our.bol (main our.bol)] ~ ~]
|
2017-10-06 15:46:46 +03:00
|
|
|
[%app dap.bol (crip (en-purl:html url))]~ :: XX
|
2016-03-15 03:37:34 +03:00
|
|
|
::
|
2015-06-02 02:25:22 +03:00
|
|
|
++ said :: app message
|
2016-08-11 21:15:06 +03:00
|
|
|
|= {our/@p dap/term now/@da eny/@uvJ mes/(list tank)}
|
2017-04-14 01:46:15 +03:00
|
|
|
:- %talk-action
|
|
|
|
^- action
|
|
|
|
:- %convey
|
2015-06-05 02:24:55 +03:00
|
|
|
|- ^- (list thought)
|
|
|
|
?~ mes ~
|
2015-06-06 02:01:44 +03:00
|
|
|
:_ $(mes t.mes, eny (sham eny mes))
|
|
|
|
^- thought
|
|
|
|
:+ (shaf %thot eny)
|
2017-07-11 02:41:47 +03:00
|
|
|
[[our (main our)] ~ ~]
|
2017-07-01 03:37:28 +03:00
|
|
|
[now [%app dap (crip ~(ram re i.mes))]]
|
2017-04-10 23:35:25 +03:00
|
|
|
::
|
|
|
|
++ uniq
|
|
|
|
|= eny/@uvJ
|
2017-10-06 20:35:25 +03:00
|
|
|
^- {serial _eny}
|
2017-04-10 23:35:25 +03:00
|
|
|
[(shaf %serial eny) (shax eny)]
|
2017-05-13 01:05:49 +03:00
|
|
|
::
|
2017-10-09 23:50:17 +03:00
|
|
|
++ range-to-path ::< msg range to path
|
|
|
|
::> turns a range structure into a path used for
|
|
|
|
::> subscriptions.
|
|
|
|
::
|
|
|
|
|= ran/range
|
|
|
|
^- path
|
|
|
|
?~ ran ~
|
|
|
|
%+ welp
|
|
|
|
/(scot -.hed.u.ran +.hed.u.ran)
|
|
|
|
?~ tal.u.ran ~
|
|
|
|
/(scot -.u.tal.u.ran +.u.tal.u.ran)
|
|
|
|
::
|
|
|
|
++ path-to-range ::< path to msg range
|
|
|
|
::> turns the tail of a subscription path into a
|
|
|
|
::> range structure.
|
|
|
|
::
|
|
|
|
|= pax/path
|
|
|
|
^- range
|
|
|
|
?~ pax ~
|
|
|
|
:+ ~
|
|
|
|
=+ hed=(slaw %da i.pax)
|
|
|
|
?^ hed [%da u.hed]
|
|
|
|
[%ud (slav %ud i.pax)]
|
|
|
|
?~ t.pax ~
|
|
|
|
:- ~
|
|
|
|
=+ tal=(slaw %da i.t.pax)
|
|
|
|
?^ tal [%da u.tal]
|
|
|
|
[%ud (slav %ud i.t.pax)]
|
|
|
|
::
|
2017-05-13 01:05:49 +03:00
|
|
|
++ change-glyphs ::< ...
|
|
|
|
::>
|
|
|
|
::
|
2017-10-19 03:05:53 +03:00
|
|
|
|= {gys/(jug char audience) bin/? gyf/char aud/audience}
|
2017-05-13 01:05:49 +03:00
|
|
|
^+ gys
|
|
|
|
:: simple bind.
|
2017-10-19 03:05:53 +03:00
|
|
|
?: bin (~(put ju gys) gyf aud)
|
2017-05-13 01:05:49 +03:00
|
|
|
:: unbind all of glyph.
|
2017-10-19 03:05:53 +03:00
|
|
|
?~ aud (~(del by gys) gyf)
|
2017-05-13 01:05:49 +03:00
|
|
|
:: unbind single.
|
2017-10-19 03:05:53 +03:00
|
|
|
(~(del ju gys) gyf aud)
|
2017-05-13 01:05:49 +03:00
|
|
|
::
|
2017-06-22 03:16:22 +03:00
|
|
|
++ change-nicks ::< change nick map
|
|
|
|
::> changes a nickname in a map, adding if it doesn't
|
|
|
|
::> yet exist, removing if the nickname is empty.
|
2017-05-13 01:05:49 +03:00
|
|
|
::
|
|
|
|
|= {nis/(map ship cord) who/ship nic/cord}
|
|
|
|
^+ nis
|
|
|
|
?: =(nic '')
|
|
|
|
(~(del by nis) who)
|
|
|
|
(~(put by nis) who nic)
|
|
|
|
::
|
2017-06-22 03:16:22 +03:00
|
|
|
++ change-config ::< apply config diff
|
|
|
|
::> applies a config diff to the given config.
|
2017-05-13 01:05:49 +03:00
|
|
|
::
|
|
|
|
|= {cof/config dif/diff-config}
|
|
|
|
^+ cof
|
|
|
|
?- -.dif
|
|
|
|
$full cof.dif
|
|
|
|
$caption cof(cap cap.dif)
|
|
|
|
$filter cof(fit fit.dif)
|
|
|
|
$remove cof
|
|
|
|
::
|
2017-06-16 04:53:47 +03:00
|
|
|
$source
|
2017-05-13 01:05:49 +03:00
|
|
|
%= cof
|
2017-06-16 04:53:47 +03:00
|
|
|
src
|
2017-10-09 23:50:17 +03:00
|
|
|
%. src.dif
|
2017-05-13 01:05:49 +03:00
|
|
|
?: add.dif
|
2017-06-28 21:12:12 +03:00
|
|
|
~(put in src.cof)
|
|
|
|
~(del in src.cof)
|
2017-05-13 01:05:49 +03:00
|
|
|
==
|
|
|
|
::
|
|
|
|
$permit
|
|
|
|
%= cof
|
2017-11-01 15:30:49 +03:00
|
|
|
sis.con
|
2017-05-13 01:05:49 +03:00
|
|
|
%. sis.dif
|
|
|
|
?: add.dif
|
2017-11-01 15:30:49 +03:00
|
|
|
~(uni in sis.con.cof)
|
|
|
|
~(dif in sis.con.cof)
|
2017-05-13 01:05:49 +03:00
|
|
|
==
|
|
|
|
::
|
|
|
|
$secure
|
|
|
|
%= cof
|
|
|
|
sec.con
|
|
|
|
sec.dif
|
|
|
|
::
|
2017-11-01 15:30:49 +03:00
|
|
|
sis.con
|
2017-05-13 01:05:49 +03:00
|
|
|
?. .= ?=(?($white $green) sec.dif)
|
|
|
|
?=(?($white $green) sec.con.cof)
|
|
|
|
~
|
2017-11-01 15:30:49 +03:00
|
|
|
sis.con.cof
|
2017-05-13 01:05:49 +03:00
|
|
|
==
|
|
|
|
==
|
|
|
|
::
|
2017-06-22 03:16:22 +03:00
|
|
|
++ change-status ::< apply status diff
|
|
|
|
::> applies a status diff to the given status.
|
2017-05-13 01:05:49 +03:00
|
|
|
::
|
|
|
|
|= {sat/status dif/diff-status}
|
|
|
|
^+ sat
|
|
|
|
?- -.dif
|
|
|
|
$full sat.dif
|
|
|
|
$presence sat(pec pec.dif)
|
|
|
|
$remove sat
|
|
|
|
::
|
|
|
|
$human
|
|
|
|
%= sat
|
|
|
|
man
|
|
|
|
?- -.dif.dif
|
|
|
|
$full man.dif.dif
|
2017-06-28 02:45:56 +03:00
|
|
|
$true [han.man.sat tru.dif.dif]
|
|
|
|
$handle [han.dif.dif tru.man.sat]
|
2017-05-13 01:05:49 +03:00
|
|
|
==
|
|
|
|
==
|
|
|
|
==
|
2017-06-13 01:19:45 +03:00
|
|
|
::
|
2017-06-14 04:06:38 +03:00
|
|
|
::TODO annotate all!
|
2017-06-13 01:19:45 +03:00
|
|
|
++ depa :: de-pathing core
|
|
|
|
=> |% ++ grub * :: result
|
|
|
|
++ weir (list coin) :: parsed wire
|
|
|
|
++ fist $-(weir grub) :: reparser instance
|
|
|
|
--
|
|
|
|
|%
|
|
|
|
::
|
|
|
|
++ al
|
|
|
|
|* {hed/$-(coin *) tal/fist}
|
|
|
|
|= wir/weir ^+ [*hed *tal]
|
|
|
|
?~ wir !!
|
|
|
|
[(hed i.wir) (tal t.wir)]
|
|
|
|
::
|
|
|
|
++ at
|
|
|
|
|* typ/{@tas (pole @tas)}
|
|
|
|
=+ [i-typ t-typ]=typ
|
|
|
|
|= wer/weir
|
2017-10-06 20:35:25 +03:00
|
|
|
^- (tup:dray:wired i-typ t-typ) ::< ie, (tup %p %tas ~) is {@p @tas}
|
2017-06-13 01:19:45 +03:00
|
|
|
?~ wer !!
|
|
|
|
?~ t-typ
|
|
|
|
?^ t.wer !!
|
|
|
|
((do i-typ) i.wer)
|
|
|
|
:- ((do i-typ) i.wer)
|
|
|
|
(^$(typ t-typ) t.wer)
|
|
|
|
::
|
|
|
|
++ mu :: true unit
|
|
|
|
|* wit/fist
|
|
|
|
|= wer/weir
|
|
|
|
?~(wer ~ (some (wit wer)))
|
|
|
|
::
|
|
|
|
++ af :: object as frond
|
|
|
|
|* buk/(pole {cord fist})
|
|
|
|
|= wer/weir
|
|
|
|
?> ?=({{$$ $tas @tas} *} wer)
|
|
|
|
?~ buk !!
|
|
|
|
=+ [[tag wit] t-buk]=buk
|
|
|
|
?: =(tag q.p.i.wer)
|
|
|
|
[tag ~|(tag+`@tas`tag (wit t.wer))]
|
2017-10-06 14:29:15 +03:00
|
|
|
?~ t-buk ~|(bad-tag+`@tas`q.p.i.wer !!)
|
2017-06-13 01:19:45 +03:00
|
|
|
(^$(buk t-buk) wer)
|
|
|
|
::
|
|
|
|
++ or
|
2017-10-06 20:35:25 +03:00
|
|
|
=+ tmp=|-($@(@tas {@tas $})) ::TODO typ/that syntax-errors...
|
|
|
|
|* typ/tmp
|
2017-06-13 01:19:45 +03:00
|
|
|
|= con/coin
|
2017-10-06 20:35:25 +03:00
|
|
|
::^- _(snag *@ (turn (limo typ) |*(a/@tas [a (odo:raid:wired a)])))
|
2017-06-13 01:19:45 +03:00
|
|
|
?> ?=($$ -.con)
|
|
|
|
=/ i-typ ?@(typ typ -.typ)
|
|
|
|
?: =(i-typ p.p.con)
|
|
|
|
:- i-typ
|
2017-10-06 20:35:25 +03:00
|
|
|
^- (odo:raid:wired i-typ)
|
2017-06-13 01:19:45 +03:00
|
|
|
q.p.con
|
|
|
|
?@ typ ~|(%bad-odor !!)
|
|
|
|
(^$(typ +.typ) con)
|
|
|
|
::
|
|
|
|
++ do
|
|
|
|
|* typ/@tas
|
2017-06-14 04:06:38 +03:00
|
|
|
=/ typecheck `@tas`typ
|
2017-06-13 01:19:45 +03:00
|
|
|
|= con/coin
|
2017-10-06 20:35:25 +03:00
|
|
|
^- (odo:raid:wired typ)
|
2017-06-13 01:19:45 +03:00
|
|
|
?. ?=($$ -.con) ~|(%not-dime !!)
|
|
|
|
?. =(typ p.p.con) ~|(bad-odor+`@tas`p.p.con !!)
|
|
|
|
q.p.con
|
|
|
|
::
|
|
|
|
++ ul :: null
|
|
|
|
|=(wer/weir ?~(wer ~ !!))
|
|
|
|
::
|
|
|
|
++ un
|
|
|
|
|* wit/$-(coin *)
|
2017-06-14 04:06:38 +03:00
|
|
|
|= wer/weir ^+ *wit
|
|
|
|
?~ wer !!
|
|
|
|
?^ t.wer !!
|
|
|
|
(wit i.wer)
|
2017-06-13 01:19:45 +03:00
|
|
|
--
|
2015-01-15 22:32:04 +03:00
|
|
|
--
|