mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-18 20:31:40 +03:00
Merge branch 'master' of https://github.com/urbit/urbit
This commit is contained in:
commit
5d107f88d7
746
arvo/clay.hoon
746
arvo/clay.hoon
@ -1,746 +0,0 @@
|
||||
!:
|
||||
:: clay (4c), revision control
|
||||
!:
|
||||
|= pit=vase
|
||||
=> |%
|
||||
++ cult (map duct rove) :: subscriptions
|
||||
++ dojo ,[p=cult q=dome] :: domestic desk state
|
||||
++ gift :: out result <-$
|
||||
$% [%ergo p=@p q=@tas r=@ud] :: version update
|
||||
[%note p=@tD q=tank] :: debug message
|
||||
[%writ p=riot] :: response
|
||||
== ::
|
||||
++ kiss :: in request ->$
|
||||
$% [%font p=@p q=@tas r=@p s=@tas] :: set upstream
|
||||
[%info p=@p q=@tas r=nori] :: internal edit
|
||||
[%ingo p=@p q=@tas r=nori] :: internal noun edit
|
||||
[%init p=@p] :: report install
|
||||
[%into p=@p q=@tas r=nori] :: external edit
|
||||
[%invo p=@p q=@tas r=nori] :: external noun edit
|
||||
[%merg p=@p q=@tas r=mizu] :: internal change
|
||||
[%plug p=@p q=@tas r=@p s=@tas] :: unset upstream
|
||||
[%wart p=sock q=@tas r=path s=*] :: network request
|
||||
[%warp p=sock q=riff] :: file request
|
||||
== ::
|
||||
++ moot ,[p=case q=case r=path s=(map path lobe)] :: stored change range
|
||||
++ move ,[p=duct q=(mold note gift)] :: local move
|
||||
++ nako $: gar=(map ,@ud tako) :: new ids
|
||||
let=@ud :: next id
|
||||
lar=(set yaki) :: new commits
|
||||
bar=(set blob) :: new content
|
||||
== ::
|
||||
++ note :: out request $->
|
||||
$% $: %a :: to %ames
|
||||
$% [%want p=sock q=path r=*] ::
|
||||
== == ::
|
||||
$: %c :: to %clay
|
||||
$% [%font p=@p q=@tas r=@p s=@tas] ::
|
||||
[%merg p=@p q=@tas r=mizu] ::
|
||||
[%warp p=sock q=riff] ::
|
||||
== == ::
|
||||
$: %d ::
|
||||
$% [%flog p=[%crud p=@tas q=(list tank)]] :: to %dill
|
||||
== == ::
|
||||
$: %t ::
|
||||
$% [%wait p=@da] ::
|
||||
[%rest p=@da] ::
|
||||
== == == ::
|
||||
++ sign :: in result $<-
|
||||
$? $: %a :: by %ames
|
||||
$% [%waft p=sock q=*] ::
|
||||
[%went p=ship q=cape] ::
|
||||
== == ::
|
||||
$: %c :: by %clay
|
||||
$% [%writ p=riot] ::
|
||||
== == ::
|
||||
$: %t ::
|
||||
$% [%wake ~] :: timer activate
|
||||
== == ::
|
||||
$: @tas :: by any
|
||||
$% [%crud p=@tas q=(list tank)] ::
|
||||
== == == ::
|
||||
++ raft :: filesystem
|
||||
$: fat=(map ship room) :: domestic
|
||||
hoy=(map ship rung) :: foreign
|
||||
ran=rang :: hashes
|
||||
sor=(map ,[p=@p q=@tas r=@p s=@tas] duct) :: upstreams
|
||||
== ::
|
||||
++ rave :: general request
|
||||
$% [& p=mood] :: single request
|
||||
[| p=moat] :: change range
|
||||
== ::
|
||||
++ rede :: universal project
|
||||
$: lim=@da :: complete to
|
||||
qyx=cult :: subscribers
|
||||
ref=(unit rind) :: outgoing requests
|
||||
dom=dome :: revision state
|
||||
== ::
|
||||
++ riff ,[p=desk q=(unit rave)] :: request/desist
|
||||
++ rind :: request manager
|
||||
$: nix=@ud :: request index
|
||||
bom=(map ,@ud ,[p=duct q=rave]) :: outstanding
|
||||
fod=(map duct ,@ud) :: current requests
|
||||
haw=(map mood (unit)) :: simple cache
|
||||
== ::
|
||||
++ room :: fs per ship
|
||||
$: hun=duct :: terminal duct
|
||||
hez=(unit duct) :: sync duct
|
||||
dos=(map desk dojo) :: native desk
|
||||
== ::
|
||||
++ rove (each mood moot) :: stored request
|
||||
++ rung $: rus=(map desk rede) :: neighbor desks
|
||||
== ::
|
||||
-- =>
|
||||
::::::::::::::::::::::::::::::::::::::::::::::::::::::::
|
||||
:: section 4cA, filesystem logic ::
|
||||
::
|
||||
::
|
||||
::
|
||||
|%
|
||||
++ de :: per desk
|
||||
|= [now=@da hun=duct hez=(unit duct)]
|
||||
|= [[who=@p for=@p] syd=@ta rede ran=rang]
|
||||
=* red +<+>-
|
||||
=| yel=(list ,[p=duct q=gift])
|
||||
=| byn=(list ,[p=duct q=riot])
|
||||
=| vag=(list ,[p=duct q=gift])
|
||||
=| say=(list ,[p=duct q=path r=ship s=[p=@ud q=riff]])
|
||||
=| tag=(list ,[p=duct q=path c=note])
|
||||
|%
|
||||
++ abet
|
||||
^- [(list move) rede]
|
||||
:_ red
|
||||
;: weld
|
||||
%+ turn (flop yel)
|
||||
|=([a=duct b=gift] [hun %give b])
|
||||
::
|
||||
%+ turn (flop byn)
|
||||
|=([a=duct b=riot] [a %give [%writ b]])
|
||||
::
|
||||
%+ turn (flop vag)
|
||||
|=([a=duct b=gift] [a %give b])
|
||||
::
|
||||
%+ turn (flop say)
|
||||
|= [a=duct b=path c=ship d=[p=@ud q=riff]]
|
||||
:- a
|
||||
[%pass b %a %want [who c] [%q %re p.q.d (scot %ud p.d) ~] q.d]
|
||||
::
|
||||
%+ turn (flop tag)
|
||||
|=([a=duct b=path c=note] [a %pass b c])
|
||||
==
|
||||
::
|
||||
++ aver :: read
|
||||
|= mun=mood
|
||||
^- (unit (unit ,*))
|
||||
?: &(=(p.mun %u) !=(p.q.mun now)) :: prevent bad things
|
||||
~& [%clay-fail p.q.mun %now now]
|
||||
!!
|
||||
=+ ezy=?~(ref ~ (~(get by haw.u.ref) mun))
|
||||
?^ ezy ezy
|
||||
=+ nao=(~(case-to-aeon ze lim dom ran) q.mun)
|
||||
:: ~& [%aver-mun nao [%from syd lim q.mun]]
|
||||
?~(nao ~ [~ (~(read-at-aeon ze lim dom ran) u.nao mun)])
|
||||
::
|
||||
++ balk :: read and send
|
||||
|= [hen=duct yon=@ud mun=mood]
|
||||
^+ +>
|
||||
=+ vid=(~(read-at-aeon ze lim dom ran) yon mun)
|
||||
?~ vid (blub hen) (blab hen mun u.vid)
|
||||
::
|
||||
++ bait
|
||||
|= [hen=duct tym=@da]
|
||||
%_(+> tag :_(tag [hen /tyme %t %wait tym]))
|
||||
::
|
||||
++ best
|
||||
|= [hen=duct tym=@da]
|
||||
%_(+> tag :_(tag [hen /tyme %t %rest tym]))
|
||||
::
|
||||
++ blab :: ship result
|
||||
|= [hen=duct mun=mood dat=*]
|
||||
^+ +>
|
||||
+>(byn [[hen ~ [p.mun q.mun syd] r.mun dat] byn])
|
||||
::
|
||||
++ bleb :: ship sequence
|
||||
|= [hen=duct ins=@ud hip=nako]
|
||||
^+ +>
|
||||
(blab hen [%w [%ud ins] ~] hip)
|
||||
::
|
||||
++ blub :: ship stop
|
||||
|= hen=duct
|
||||
%_(+> byn [[hen ~] byn])
|
||||
::
|
||||
++ duce :: produce request
|
||||
|= [hen=duct rov=rove]
|
||||
^+ +>
|
||||
=. qyx (~(put by qyx) hen rov)
|
||||
?~ ref
|
||||
(mabe rov (cury bait hen))
|
||||
|- ^+ +>+.$ :: XX why?
|
||||
=+ rav=(reve rov)
|
||||
=+ ^= vaw ^- rave
|
||||
?. ?=([%& %v *] rav) rav
|
||||
[%| [%ud let.dom] `case`q.p.rav r.p.rav]
|
||||
=+ inx=nix.u.ref
|
||||
%= +>+.$
|
||||
say [[hen [(scot %ud inx) ~] for [inx syd ~ vaw]] say]
|
||||
nix.u.ref +(nix.u.ref)
|
||||
bom.u.ref (~(put by bom.u.ref) inx [hen vaw])
|
||||
fod.u.ref (~(put by fod.u.ref) hen inx)
|
||||
==
|
||||
::
|
||||
++ ease :: release request
|
||||
|= hen=duct
|
||||
^+ +>
|
||||
?~ ref
|
||||
=+ rov=(~(got by qyx) hen)
|
||||
=. qyx (~(del by qyx) hen)
|
||||
(mabe rov (cury best hen))
|
||||
=. qyx (~(del by qyx) hen)
|
||||
|- ^+ +>+.$
|
||||
=+ nux=(~(get by fod.u.ref) hen)
|
||||
?~ nux +>+.$
|
||||
%= +>+.$
|
||||
say [[hen [(scot %ud u.nux) ~] for [u.nux syd ~]] say]
|
||||
fod.u.ref (~(del by fod.u.ref) hen)
|
||||
bom.u.ref (~(del by bom.u.ref) u.nux)
|
||||
==
|
||||
::
|
||||
++ eave :: subscribe
|
||||
|= [hen=duct rav=rave]
|
||||
^+ +>
|
||||
?- -.rav
|
||||
&
|
||||
?: &(=(p.p.rav %u) !=(p.q.p.rav now))
|
||||
~& [%clay-fail p.q.p.rav %now now]
|
||||
!!
|
||||
=+ ver=(aver p.rav)
|
||||
?~ ver
|
||||
(duce hen rav)
|
||||
?~ u.ver
|
||||
(blub hen)
|
||||
(blab hen p.rav u.u.ver)
|
||||
::
|
||||
|
|
||||
=+ nab=(~(case-to-aeon ze lim dom ran) p.p.rav)
|
||||
?~ nab
|
||||
?> =(~ (~(case-to-aeon ze lim dom ran) q.p.rav))
|
||||
(duce hen (rive rav))
|
||||
=+ huy=(~(case-to-aeon ze lim dom ran) q.p.rav)
|
||||
?: &(?=(^ huy) |((lth u.huy u.nab) &(=(0 u.huy) =(0 u.nab))))
|
||||
(blub hen)
|
||||
=+ top=?~(huy let.dom u.huy)
|
||||
=+ sar=(~(lobes-at-path ze lim dom ran) u.nab r.p.rav)
|
||||
=+ ear=(~(lobes-at-path ze lim dom ran) top r.p.rav)
|
||||
=. +>.$
|
||||
?: =(sar ear) +>.$
|
||||
=+ fud=(~(make-nako ze lim dom ran) u.nab top)
|
||||
(bleb hen u.nab fud)
|
||||
?^ huy
|
||||
(blub hen)
|
||||
=+ ^= ptr ^- case
|
||||
[%ud +(let.dom)]
|
||||
(duce hen `rove`[%| ptr q.p.rav r.p.rav ear])
|
||||
==
|
||||
::
|
||||
++ echa :: announce raw
|
||||
|= [hen=duct wen=@da mer=mizu]
|
||||
^+ +>
|
||||
%= +>
|
||||
vag ?~(hez vag :_(vag [u.hez [%ergo who syd let.dom]]))
|
||||
::yel [[hen %note '=' %leaf ~] yel] :: XX do better
|
||||
==
|
||||
::
|
||||
++ echo :: announce changes
|
||||
|= [hen=duct wen=@da lem=nori]
|
||||
^+ +>
|
||||
%= +>
|
||||
vag ?~(hez vag :_(vag [u.hez [%ergo who syd let.dom]]))
|
||||
yel
|
||||
=+ pre=`path`~[(scot %p for) syd (scot %ud let.dom)]
|
||||
?- -.lem
|
||||
| :_ yel
|
||||
[hen %note '=' %leaf :(weld (trip p.lem) " " (spud pre))]
|
||||
& |- ^+ yel
|
||||
?~ q.q.lem yel
|
||||
:_ $(q.q.lem t.q.q.lem)
|
||||
:- hen
|
||||
:+ %note
|
||||
?-(-.q.i.q.q.lem %del '-', %ins '+', %mut ':')
|
||||
[%leaf (spud (weld pre p.i.q.q.lem))]
|
||||
==
|
||||
==
|
||||
::
|
||||
++ edit :: apply changes
|
||||
|= [wen=@da lem=nori]
|
||||
^+ +>
|
||||
=+ axe=(~(edit ze lim dom ran) wen lem)
|
||||
=+ `[l=@da d=dome r=rang]`+<.axe
|
||||
+>.$(dom d, ran r)
|
||||
::
|
||||
++ edis :: apply subscription
|
||||
|= nak=nako
|
||||
^+ +>
|
||||
%= +>
|
||||
hit.dom (~(uni by hit.dom) gar.nak)
|
||||
let.dom let.nak
|
||||
lat.ran %+ roll (~(tap in bar.nak) ~)
|
||||
=< .(yeb lat.ran)
|
||||
|= [sar=blob yeb=(map lobe blob)]
|
||||
=+ zax=(blob-to-lobe sar)
|
||||
%+ ~(put by yeb) zax sar
|
||||
hut.ran %+ roll (~(tap in lar.nak) ~)
|
||||
=< .(yeb hut.ran)
|
||||
|= [sar=yaki yeb=(map tako yaki)]
|
||||
%+ ~(put by yeb) r.sar sar
|
||||
==
|
||||
::
|
||||
++ exec :: change and update
|
||||
|= [hen=duct wen=@da lem=nori]
|
||||
^+ +>
|
||||
(echo:wake:(edit wen lem) hen wen lem)
|
||||
::
|
||||
++ exem :: execute merge
|
||||
|= [hen=duct wen=@da mer=mizu] :: aka direct change
|
||||
?. (gte p.mer let.dom) !! :: no
|
||||
=. +>.$ %= +>.$
|
||||
hut.ran (~(uni by hut.r.mer) hut.ran)
|
||||
lat.ran (~(uni by lat.r.mer) lat.ran)
|
||||
let.dom p.mer
|
||||
hit.dom (~(uni by q.mer) hit.dom)
|
||||
==
|
||||
=+ ^= hed :: head commit
|
||||
=< q
|
||||
%- ~(got by hut.ran)
|
||||
%- ~(got by hit.dom)
|
||||
let.dom
|
||||
=. ank.dom :: real checkout
|
||||
(~(checkout-ankh ze lim dom ran) hed)
|
||||
(echa:wake hen wen mer) :: notify or w/e
|
||||
::
|
||||
++ knit :: external change
|
||||
|= [inx=@ud rot=riot]
|
||||
^+ +>
|
||||
?> ?=(^ ref)
|
||||
|- ^+ +>+.$
|
||||
=+ ruv=(~(get by bom.u.ref) inx)
|
||||
?~ ruv +>+.$
|
||||
=> ?. |(?=(~ rot) ?=(& -.q.u.ruv)) .
|
||||
%_ .
|
||||
bom.u.ref (~(del by bom.u.ref) inx)
|
||||
fod.u.ref (~(del by fod.u.ref) p.u.ruv)
|
||||
==
|
||||
?~ rot
|
||||
=+ rav=`rave`q.u.ruv
|
||||
%= +>+.$
|
||||
lim
|
||||
?.(&(?=(| -.rav) ?=(%da -.q.p.rav)) lim `@da`p.q.p.rav)
|
||||
::
|
||||
haw.u.ref
|
||||
?. ?=(& -.rav) haw.u.ref
|
||||
(~(put by haw.u.ref) p.rav ~)
|
||||
==
|
||||
?< ?=(%v p.p.u.rot)
|
||||
=. haw.u.ref
|
||||
(~(put by haw.u.ref) [p.p.u.rot q.p.u.rot q.u.rot] ~ r.u.rot)
|
||||
?. ?=(%w p.p.u.rot) +>+.$
|
||||
|- ^+ +>+.^$
|
||||
=+ nez=[%w [%ud let.dom] ~]
|
||||
=+ nex=(~(get by haw.u.ref) nez)
|
||||
?~ nex +>+.^$
|
||||
?~ u.nex +>+.^$ :: should never happen
|
||||
=. +>+.^$
|
||||
=+ roo=(edis ((hard nako) u.u.nex))
|
||||
?>(?=(^ ref.roo) roo)
|
||||
%= $
|
||||
haw.u.ref (~(del by haw.u.ref) nez)
|
||||
==
|
||||
::
|
||||
++ mabe :: maybe fire function
|
||||
|* [rov=rove fun=$+(@da _+>.^$)]
|
||||
^+ +>.$
|
||||
%- fall :_ +>.$
|
||||
%- bind :_ fun
|
||||
^- (unit ,@da)
|
||||
?- -.rov
|
||||
%&
|
||||
?. ?=(%da -.q.p.rov) ~
|
||||
`p.q.p.rov
|
||||
%|
|
||||
=* mot p.rov
|
||||
%+ hunt
|
||||
?. ?=(%da -.p.mot) ~
|
||||
?.((lth now p.p.mot) ~ [~ p.p.mot])
|
||||
?. ?=(%da -.q.mot) ~
|
||||
?.((lth now p.q.mot) [~ now] [~ p.q.mot])
|
||||
==
|
||||
::
|
||||
++ reve
|
||||
|= rov=rove
|
||||
^- rave
|
||||
?: ?=(%& -.rov) rov
|
||||
[%| p.p.rov q.p.rov r.p.rov]
|
||||
::
|
||||
++ rive
|
||||
|= rav=[%| p=moat]
|
||||
^- rove
|
||||
[%| p.p.rav q.p.rav r.p.rav ~]
|
||||
::
|
||||
++ sync
|
||||
|= [hen=duct her=@p sud=@tas rot=riot]
|
||||
^+ +>.$
|
||||
?~ rot
|
||||
~& "autosync from {<sud>} on {<her>} to {<syd>} on {<who>} stopped"
|
||||
+>.$
|
||||
?: ?=(%y p.p.u.rot)
|
||||
%= +>.$
|
||||
yel
|
||||
[[hen %note ';' %leaf "starting to sync desk {(trip syd)}..."] yel]
|
||||
tag
|
||||
:_ tag
|
||||
:* hen /auto/(scot %p who)/[syd]/(scot %p her)/[sud]/v
|
||||
%c %warp [who her] sud
|
||||
`[%& %v q.p.u.rot /]
|
||||
==
|
||||
==
|
||||
?> ?=(%v p.p.u.rot)
|
||||
=+ der=((hard dome) r.u.rot)
|
||||
=+ ^= lum
|
||||
^- (unit (unit mizu))
|
||||
%^ ~(construct-merge ze now dom ran)
|
||||
?:(=(0 let.dom) %init %meld)
|
||||
who
|
||||
:+ syd
|
||||
`saba`[her sud [0 let.der] der]
|
||||
now
|
||||
=. tag
|
||||
:_ tag
|
||||
:* hen /auto/(scot %p who)/[syd]/(scot %p her)/[sud]/y
|
||||
%c %warp [who her] sud
|
||||
`[%& %y [%ud +(let.der)] /]
|
||||
==
|
||||
?~ lum
|
||||
~& "autosync from {<sud>} on {<her>} to {<syd>} on {<who>} failed"
|
||||
~& "please merge manually"
|
||||
+>.$
|
||||
?~ u.lum
|
||||
~& "autosync from {<sud>} on {<her>} to {<syd>} on {<who>} up to date"
|
||||
+>.$
|
||||
%= +>.$
|
||||
yel
|
||||
[[hen %note ';' %leaf "successfully synced desk {(trip syd)}..."] yel]
|
||||
tag
|
||||
:_ tag
|
||||
:* hen /auto/(scot %p who)/[syd]/(scot %p her)/[sud]/merg
|
||||
%c %merg who syd u.u.lum
|
||||
==
|
||||
==
|
||||
::
|
||||
++ wake :: update subscribers
|
||||
^+ .
|
||||
=+ xiq=(~(tap by qyx) ~)
|
||||
=| xaq=(list ,[p=duct q=rove])
|
||||
|- ^+ ..wake
|
||||
?~ xiq
|
||||
..wake(qyx (~(gas by *cult) xaq))
|
||||
?- -.q.i.xiq
|
||||
&
|
||||
=+ cas=?~(ref ~ (~(get by haw.u.ref) `mood`p.q.i.xiq))
|
||||
?^ cas
|
||||
%= $
|
||||
xiq t.xiq
|
||||
..wake ?~ u.cas (blub p.i.xiq)
|
||||
(blab p.i.xiq p.q.i.xiq u.u.cas)
|
||||
==
|
||||
=+ nao=(~(case-to-aeon ze lim dom ran) q.p.q.i.xiq)
|
||||
?~ nao $(xiq t.xiq, xaq [i.xiq xaq])
|
||||
$(xiq t.xiq, ..wake (balk p.i.xiq u.nao p.q.i.xiq))
|
||||
::
|
||||
|
|
||||
=+ mot=`moot`p.q.i.xiq
|
||||
=+ nab=(~(case-to-aeon ze lim dom ran) p.mot)
|
||||
?~ nab
|
||||
$(xiq t.xiq, xaq [i.xiq xaq])
|
||||
=+ huy=(~(case-to-aeon ze lim dom ran) q.mot)
|
||||
?~ huy
|
||||
=+ ptr=[%ud +(let.dom)]
|
||||
%= $
|
||||
xiq t.xiq
|
||||
xaq [[p.i.xiq [%| ptr q.mot r.mot s.mot]] xaq]
|
||||
..wake =+ ^= ear
|
||||
(~(lobes-at-path ze lim dom ran) let.dom r.p.q.i.xiq)
|
||||
?: =(s.p.q.i.xiq ear) ..wake
|
||||
=+ fud=(~(make-nako ze lim dom ran) u.nab let.dom)
|
||||
(bleb p.i.xiq let.dom fud)
|
||||
==
|
||||
%= $
|
||||
xiq t.xiq
|
||||
..wake =- (blub:- p.i.xiq)
|
||||
=+ ^= ear
|
||||
(~(lobes-at-path ze lim dom ran) u.huy r.p.q.i.xiq)
|
||||
?: =(s.p.q.i.xiq ear) (blub p.i.xiq)
|
||||
=+ fud=(~(make-nako ze lim dom ran) u.nab u.huy)
|
||||
(bleb p.i.xiq +(u.nab) fud)
|
||||
==
|
||||
==
|
||||
--
|
||||
::
|
||||
++ do
|
||||
|= [now=@da [who=ship him=ship] syd=@tas ruf=raft]
|
||||
=+ ^= rug ^- rung
|
||||
=+ rug=(~(get by hoy.ruf) him)
|
||||
?^(rug u.rug *rung)
|
||||
=+ ^= red ^- rede
|
||||
=+ yit=(~(get by rus.rug) syd)
|
||||
?^(yit u.yit `rede`[~2000.1.1 ~ [~ *rind] *dome])
|
||||
((de now ~ ~) [who him] syd red ran.ruf)
|
||||
::
|
||||
++ posh
|
||||
|= [him=ship syd=desk red=rede ruf=raft]
|
||||
^- raft
|
||||
=+ ^= rug ^- rung
|
||||
=+ rug=(~(get by hoy.ruf) him)
|
||||
?^(rug u.rug *rung)
|
||||
ruf(hoy (~(put by hoy.ruf) him rug(rus (~(put by rus.rug) syd red))))
|
||||
::
|
||||
++ un :: domestic ship
|
||||
|= [who=@p now=@da ruf=raft]
|
||||
=+ ^= yar ^- room
|
||||
=+ yar=(~(get by fat.ruf) who)
|
||||
?~(yar *room u.yar)
|
||||
|%
|
||||
++ abet ruf(fat (~(put by fat.ruf) who yar))
|
||||
++ pish
|
||||
|= [syd=@ta red=rede run=rang]
|
||||
%_(+> dos.yar (~(put by dos.yar) syd [qyx.red dom.red]), ran.ruf run)
|
||||
::
|
||||
++ wake
|
||||
=+ saz=(turn (~(tap by dos.yar) ~) |=([a=@tas b=*] a))
|
||||
=| moz=(list move)
|
||||
=< [moz ..wake]
|
||||
|- ^+ +
|
||||
?~ saz +
|
||||
=+ sog=abet:wake:(di i.saz)
|
||||
$(saz t.saz, moz (weld moz -.sog), ..wake (pish i.saz +.sog ran.ruf))
|
||||
::
|
||||
++ di
|
||||
|= syd=@ta
|
||||
=+ ^= saq ^- dojo
|
||||
=+ saq=(~(get by dos.yar) syd)
|
||||
?~(saq *dojo u.saq)
|
||||
((de now hun.yar hez.yar) [who who] syd [now p.saq ~ q.saq] ran.ruf)
|
||||
--
|
||||
--
|
||||
::::::::::::::::::::::::::::::::::::::::::::::::::::::::
|
||||
:: section 4cA, filesystem vane ::
|
||||
:: ::
|
||||
=| :: instrument state
|
||||
$: %0 :: vane version
|
||||
ruf=raft :: revision tree
|
||||
== ::
|
||||
|= [now=@da eny=@ ski=sled] :: activate
|
||||
^? :: opaque core
|
||||
|% ::
|
||||
++ call :: handle request
|
||||
|= $: hen=duct
|
||||
hic=(hypo (hobo kiss))
|
||||
==
|
||||
=> %= . :: XX temporary
|
||||
q.hic
|
||||
^- kiss
|
||||
?: ?=(%soft -.q.hic)
|
||||
((hard kiss) p.q.hic)
|
||||
?: (~(nest ut -:!>(*kiss)) | p.hic) q.hic
|
||||
~& [%clay-call-flub (,@tas `*`-.q.hic)]
|
||||
((hard kiss) q.hic)
|
||||
==
|
||||
^- [p=(list move) q=_..^$]
|
||||
?- -.q.hic
|
||||
%init
|
||||
:_ ..^$(fat.ruf (~(put by fat.ruf) p.q.hic [hen ~ ~]))
|
||||
=+ bos=(sein p.q.hic)
|
||||
~& [%bos bos p.q.hic]
|
||||
?: =(bos p.q.hic) ~
|
||||
^- (list move)
|
||||
%+ turn (limo ~[%main %arvo %try])
|
||||
|= syd=@tas
|
||||
[hen %pass / %c %font p.q.hic syd bos syd]
|
||||
::
|
||||
%font
|
||||
?: (~(has by sor.ruf) +.q.hic) `..^$
|
||||
:_ ..^$(sor.ruf (~(put by sor.ruf) +.q.hic hen))
|
||||
:~ :* hen %pass
|
||||
/auto/(scot %p p.q.hic)/[q.q.hic]/(scot %p r.q.hic)/[s.q.hic]/y
|
||||
%c %warp [p.q.hic r.q.hic] s.q.hic
|
||||
`[%& %y [%da now] /]
|
||||
==
|
||||
==
|
||||
::
|
||||
?(%info %into)
|
||||
?: =(%$ q.q.hic)
|
||||
?. ?=(%into -.q.hic) [~ ..^$]
|
||||
=+ yar=(need (~(get by fat.ruf) p.q.hic))
|
||||
[~ ..^$(fat.ruf (~(put by fat.ruf) p.q.hic yar(hez [~ hen])))]
|
||||
=^ mos ruf
|
||||
=+ une=(un p.q.hic now ruf)
|
||||
=+ ^= zat
|
||||
(exec:(di:wake:une q.q.hic) hen now r.q.hic)
|
||||
=+ zot=abet.zat
|
||||
:- -.zot
|
||||
=. une (pish:une q.q.hic +.zot ran.zat)
|
||||
abet:une(hez.yar ?.(=(%into -.q.hic) hez.yar.une [~ hen]))
|
||||
[mos ..^$]
|
||||
::
|
||||
?(%ingo %invo) :: not yet used
|
||||
?: =(%$ q.q.hic)
|
||||
?. ?=(%invo -.q.hic) [~ ..^$]
|
||||
=+ yar=(need (~(get by fat.ruf) p.q.hic))
|
||||
[~ ..^$(fat.ruf (~(put by fat.ruf) p.q.hic yar(hez [~ hen])))]
|
||||
=^ mos ruf
|
||||
=+ une=(un p.q.hic now ruf)
|
||||
=+ ^= zat
|
||||
(exec:(di:wake:une q.q.hic) hen now r.q.hic)
|
||||
=+ zot=abet:zat
|
||||
:- -.zot
|
||||
=. une (pish:une q.q.hic +.zot ran.zat)
|
||||
abet:une(hez.yar ?.(=(%invo -.q.hic) hez.yar.une [~ hen]))
|
||||
[mos ..^$]
|
||||
::
|
||||
%merg :: direct state up
|
||||
=^ mos ruf
|
||||
=+ une=(un p.q.hic now ruf)
|
||||
=+ ^= zat
|
||||
(exem:(di:wake:une q.q.hic) hen now r.q.hic)
|
||||
=+ zot=abet.zat
|
||||
:- -.zot
|
||||
=. une (pish:une q.q.hic +.zot ran.zat)
|
||||
abet:une(hez.yar ?.(=(%into -.q.hic) hez.yar.une [~ hen]))
|
||||
[mos ..^$]
|
||||
::
|
||||
%plug
|
||||
?. (~(has by sor.ruf) +.q.hic) `..^$
|
||||
:_ ..^$(sor.ruf (~(del by sor.ruf) +.q.hic))
|
||||
=+ hyn=(~(got by sor.ruf) +.q.hic)
|
||||
:~ :* hyn %pass
|
||||
/auto/(scot %p p.q.hic)/[q.q.hic]/(scot %p r.q.hic)/[s.q.hic]/y
|
||||
%c %warp [p.q.hic r.q.hic] s.q.hic ~
|
||||
==
|
||||
:* hyn %pass
|
||||
/auto/(scot %p p.q.hic)/[q.q.hic]/(scot %p r.q.hic)/[s.q.hic]/v
|
||||
%c %warp [p.q.hic r.q.hic] s.q.hic ~
|
||||
==
|
||||
==
|
||||
::
|
||||
%warp
|
||||
=^ mos ruf
|
||||
?: =(p.p.q.hic q.p.q.hic)
|
||||
=+ une=(un p.p.q.hic now ruf)
|
||||
=+ wex=(di:une p.q.q.hic)
|
||||
=+ ^= wao
|
||||
?~ q.q.q.hic
|
||||
(ease:wex hen)
|
||||
(eave:wex hen u.q.q.q.hic)
|
||||
=+ ^= woo
|
||||
abet:wao
|
||||
[-.woo abet:(pish:une p.q.q.hic +.woo ran.wao)]
|
||||
=+ wex=(do now p.q.hic p.q.q.hic ruf)
|
||||
=+ ^= woo
|
||||
?~ q.q.q.hic
|
||||
abet:(ease:wex hen)
|
||||
abet:(eave:wex hen u.q.q.q.hic)
|
||||
[-.woo (posh q.p.q.hic p.q.q.hic +.woo ruf)]
|
||||
[mos ..^$]
|
||||
::
|
||||
%wart
|
||||
?> ?=(%re q.q.hic)
|
||||
=+ ryf=((hard riff) s.q.hic)
|
||||
:_ ..^$
|
||||
:~ :- hen
|
||||
:^ %pass [(scot %p p.p.q.hic) (scot %p q.p.q.hic) r.q.hic]
|
||||
%c
|
||||
[%warp [p.p.q.hic p.p.q.hic] ryf]
|
||||
==
|
||||
==
|
||||
::
|
||||
++ doze
|
||||
|= [now=@da hen=duct]
|
||||
^- (unit ,@da)
|
||||
~
|
||||
::
|
||||
++ load
|
||||
|= old=[%0 ruf=raft]
|
||||
^+ ..^$
|
||||
..^$(ruf ruf.old)
|
||||
::
|
||||
++ scry :: inspect
|
||||
|= [fur=(unit (set monk)) ren=@tas his=ship syd=desk lot=coin tyl=path]
|
||||
^- (unit (unit (pair mark ,*)))
|
||||
=+ got=(~(has by fat.ruf) his)
|
||||
=+ luk=?.(?=(%$ -.lot) ~ ((soft case) p.lot))
|
||||
?~ luk [~ ~]
|
||||
?: =(%$ ren)
|
||||
[~ ~]
|
||||
=+ run=((soft care) ren)
|
||||
?~ run [~ ~]
|
||||
%+ bind
|
||||
%. [u.run u.luk tyl]
|
||||
=< aver
|
||||
?: got
|
||||
(di:(un his now ruf) syd)
|
||||
(do now [his his] syd ruf)
|
||||
|=(a=(unit) (bind a |=(b=* [%noun b])))
|
||||
::
|
||||
++ stay [%0 ruf]
|
||||
++ take :: accept response
|
||||
|= [tea=wire hen=duct hin=(hypo sign)]
|
||||
^- [p=(list move) q=_..^$]
|
||||
?: ?=([%auto @ @ @ @ ?(%y %v) ~] tea)
|
||||
?> ?=(%writ -.+.q.hin)
|
||||
=+ our=(slav %p i.t.tea)
|
||||
=* sud i.t.t.tea
|
||||
=+ her=(slav %p i.t.t.t.tea)
|
||||
=* syd i.t.t.t.t.tea
|
||||
=+ une=(un our now ruf)
|
||||
=+ wex=(di:une syd)
|
||||
=+ wao=(sync:wex hen her sud p.q.hin)
|
||||
=+ woo=abet:wao
|
||||
[-.woo ..^$(ruf abet:(pish:une syd +.woo ran.wao))]
|
||||
?- -.+.q.hin
|
||||
%crud
|
||||
[[[hen %slip %d %flog +.q.hin] ~] ..^$]
|
||||
::
|
||||
%waft
|
||||
?> ?=([@ @ ~] tea)
|
||||
=+ syd=(need (slaw %tas i.tea))
|
||||
=+ inx=(need (slaw %ud i.t.tea))
|
||||
=+ ^= zat
|
||||
=< wake
|
||||
(knit:(do now p.+.q.hin syd ruf) [inx ((hard riot) q.+.q.hin)])
|
||||
=^ mos ruf
|
||||
=+ zot=abet.zat
|
||||
[-.zot (posh q.p.+.q.hin syd +.zot ruf)]
|
||||
[mos ..^$(ran.ruf ran.zat)] :: merge in new obj
|
||||
::
|
||||
%wake
|
||||
=+ dal=(turn (~(tap by fat.ruf) ~) |=([a=@p b=room] a))
|
||||
=| mos=(list move)
|
||||
|- ^- [p=(list move) q=_..^^$]
|
||||
?~ dal [mos ..^^$]
|
||||
=+ une=(un i.dal now ruf)
|
||||
=^ som une wake:une
|
||||
$(dal t.dal, ruf abet:une, mos (weld som mos))
|
||||
::
|
||||
%writ
|
||||
?> ?=([@ @ *] tea)
|
||||
=+ our=(need (slaw %p i.tea))
|
||||
=+ him=(need (slaw %p i.t.tea))
|
||||
:_ ..^$
|
||||
:~ :- hen
|
||||
[%pass ~ %a [%want [our him] [%r %re %c t.t.tea] p.+.q.hin]]
|
||||
==
|
||||
::
|
||||
%went
|
||||
?: =(%good q.+.q.hin) [~ ..^$]
|
||||
~& [%clay-lost p.+.q.hin tea]
|
||||
[~ ..^$]
|
||||
==
|
||||
--
|
758
arvo/doll.hoon
758
arvo/doll.hoon
@ -1,758 +0,0 @@
|
||||
!:
|
||||
:: dill (4d), terminal handling
|
||||
::
|
||||
|= pit=vase
|
||||
=> |% :: interface tiles
|
||||
++ gift :: out result <-$
|
||||
$% [%bbye ~] :: reset prompt
|
||||
[%blit p=(list blit)] :: terminal output
|
||||
[%init p=@p] :: report install
|
||||
[%logo @] :: logout
|
||||
[%veer p=@ta q=path r=@t] :: install vane
|
||||
[%vega p=path] :: reboot by path
|
||||
[%verb ~] ::
|
||||
== ::
|
||||
++ kiss :: in request ->$
|
||||
$% [%belt p=belt] :: terminal input
|
||||
[%blew p=blew] :: terminal config
|
||||
[%boot p=*] :: weird %dill boot
|
||||
[%crud p=@tas q=(list tank)] :: error with trace
|
||||
[%flog p=flog] :: wrapped error
|
||||
[%flow p=*] :: forward compat
|
||||
[%hail ~] :: terminal refresh
|
||||
[%hook ~] :: this term hung up
|
||||
[%harm ~] :: all terms hung up
|
||||
[%init p=ship] :: after gall ready
|
||||
[%noop ~] :: no operation
|
||||
[%talk p=tank] ::
|
||||
[%text p=tape] ::
|
||||
== ::
|
||||
++ flog :: sent to %dill
|
||||
$% [%crud p=@tas q=(list tank)] ::
|
||||
[%text p=tape] ::
|
||||
== ::
|
||||
++ mess :: message to terminal
|
||||
$% [%term-ctrl p=(hypo ,%hail)] ::
|
||||
[%term-in p=(hypo term-in)] ::
|
||||
== ::
|
||||
++ move ,[p=duct q=(mold note gift)] :: local move
|
||||
++ note :: out request $->
|
||||
$% $: %a ::
|
||||
$% [%make p=(unit ,@t) q=@ud r=@ s=?] ::
|
||||
[%sith p=@p q=@uw r=?] ::
|
||||
== == ::
|
||||
$: %c ::
|
||||
$% [%warp p=sock q=riff] ::
|
||||
== == ::
|
||||
$: %d ::
|
||||
$% [%crud p=@tas q=(list tank)] ::
|
||||
[%text p=tape] ::
|
||||
[%logo ~] ::
|
||||
== == ::
|
||||
$: %g ::
|
||||
$% [%mess p=[p=ship q=path] q=ship r=mess] ::
|
||||
[%nuke p=[p=ship q=path] q=ship] ::
|
||||
[%show p=[p=ship q=path] q=ship r=path] ::
|
||||
[%took p=[p=ship q=path] q=ship] ::
|
||||
== == ::
|
||||
$: %t ::
|
||||
$% [%wait p=@da] ::
|
||||
== == == ::
|
||||
++ riff ,[p=desk q=(unit rave)] :: see %clay
|
||||
++ sign :: in result $<-
|
||||
$?
|
||||
$: %c ::
|
||||
$% [%writ p=riot] ::
|
||||
== == ::
|
||||
$: %g ::
|
||||
$% [%logo p=@] ::
|
||||
[%mean p=ares] ::
|
||||
[%nice ~] ::
|
||||
$: %rush ::
|
||||
$% [%term-line q=term-line] ::
|
||||
[%hymn q=manx] ::
|
||||
== == ::
|
||||
[%verb ~] ::
|
||||
[%sage p=path q=*] ::
|
||||
[%veer p=@ta q=path r=@t] ::
|
||||
[%vega p=path] ::
|
||||
== == ::
|
||||
$: %t ::
|
||||
$% [%wake ~] ::
|
||||
== ==
|
||||
$: @tas :: by any
|
||||
$% [%crud p=@tas q=(list tank)] ::
|
||||
[%init p=@p] ::
|
||||
[%note p=@tD q=tank] ::
|
||||
== == == ::
|
||||
++ term-in ::
|
||||
$: pax=path ::
|
||||
$= jof ::
|
||||
$% [%line p=cord] ::
|
||||
[%res p=span] ::
|
||||
[%cmd p=char] ::
|
||||
[%type p=?] ::
|
||||
== == ::
|
||||
++ term-line ,[p=[p=cord q=prom r=cord] q=(list cord) r=(list tark)]
|
||||
++ tark ?(tank [%stem p=@da q=tank r=tank]) ::
|
||||
:::::::: :: dill tiles
|
||||
++ bein :: terminal control
|
||||
$: $: bul=@ud :: buffer length
|
||||
bus=@ud :: cursor in buffer
|
||||
but=(list ,@c) :: buffer text
|
||||
buy=prom :: input style
|
||||
== ::
|
||||
$: hiz=@ud :: history depth
|
||||
hux=path :: history path
|
||||
hym=(map ,@ud (list ,@c)) :: history overlay
|
||||
hyt=hist :: history object
|
||||
hyr=(unit (list ,@c)) :: history search
|
||||
== ::
|
||||
$: pol=@ud :: length of prompt
|
||||
pot=tape :: prompt text
|
||||
== ::
|
||||
== ::
|
||||
++ blew ,[p=@ud q=@ud] :: columns rows
|
||||
++ belt :: raw console input
|
||||
$% [%aro p=?(%d %l %r %u)] :: arrow key
|
||||
[%bac ~] :: true backspace
|
||||
[%ctl p=@ud] :: control-key
|
||||
[%del ~] :: true delete
|
||||
[%met p=@ud] :: meta-key
|
||||
[%ret ~] :: return
|
||||
[%txt p=(list ,@c)] :: utf32 text
|
||||
== ::
|
||||
++ blit :: raw console output
|
||||
$% [%bel ~] :: make a noise
|
||||
[%clr ~] :: clear the screen
|
||||
[%hop p=@ud] :: set cursor position
|
||||
[%lin p=(list ,@c)] :: set current line
|
||||
[%mor ~] :: newline
|
||||
[%sag p=path q=*] :: save to jamfile
|
||||
[%sav p=path q=@] :: save to file
|
||||
== ::
|
||||
++ blot :: kill ring
|
||||
$: p=@ud :: length
|
||||
q=@ud :: depth
|
||||
r=(list (list ,@c)) :: kills
|
||||
== ::
|
||||
++ blur ,[p=@ud q=(unit bein) r=blot] :: columns, prompt
|
||||
++ kyev ::
|
||||
$: p=(set ?(%ctrl %shift %alt %meta)) ::
|
||||
q=$|(cord [%act speck]) ::
|
||||
== ::
|
||||
++ speck ::
|
||||
$? %ctrl %shift %alt %meta %entr %esc ::
|
||||
%caps %uncap %pgup %pgdn %home %end ::
|
||||
%baxp %del %ins %up %down %left ::
|
||||
%right ::
|
||||
== ::
|
||||
++ yard :: terminal state
|
||||
$: p=? :: verbose
|
||||
q=blur :: display state
|
||||
r=(map path hist) :: history
|
||||
s=[p=? q=@da] :: typing?/last typed
|
||||
== ::
|
||||
:: XX LEGACY 12-16-2014
|
||||
++ yord :: old terminal state
|
||||
$: p=? :: verbose
|
||||
q=blur :: display state
|
||||
r=(map path hist) :: history
|
||||
== ::
|
||||
-- =>
|
||||
|%
|
||||
++ dy
|
||||
|= [hen=duct our=ship now=@da def=(unit duct) dug=(map duct yard)]
|
||||
=+ ^= yar ^- yard
|
||||
=+ yur=(~(get by dug) hen)
|
||||
?^ yur u.yur
|
||||
?^ def (~(got by dug) u.def)
|
||||
[& [80 ~ *blot] ~ | *@da]
|
||||
=| mos=(list move)
|
||||
|%
|
||||
++ beep (curb [[%bel ~] ~]) :: send beep
|
||||
++ curb :: send blits
|
||||
|= wab=(list blit)
|
||||
^+ +>
|
||||
?~ wab +>
|
||||
+>(mos [[hen [%give %blit (flop wab)]] mos])
|
||||
::
|
||||
++ wod :: word forward
|
||||
|= bed=bein
|
||||
^- @ud
|
||||
?: =(bul.bed bus.bed)
|
||||
bus.bed
|
||||
?: =(' ' (snag bus.bed but.bed))
|
||||
$(bus.bed +(bus.bed))
|
||||
|-
|
||||
^- @ud
|
||||
?: =(bul.bed bus.bed)
|
||||
bus.bed
|
||||
?: =(' ' (snag bus.bed but.bed))
|
||||
bus.bed
|
||||
$(bus.bed +(bus.bed))
|
||||
::
|
||||
++ wob :: word backward
|
||||
|= bed=bein
|
||||
^- @ud
|
||||
?: =(0 bus.bed)
|
||||
bus.bed
|
||||
?: =(' ' (snag (dec bus.bed) but.bed))
|
||||
$(bus.bed (dec bus.bed))
|
||||
|-
|
||||
^- @ud
|
||||
?: =(0 bus.bed)
|
||||
bus.bed
|
||||
?: =(' ' (snag (dec bus.bed) but.bed))
|
||||
bus.bed
|
||||
$(bus.bed (dec bus.bed))
|
||||
::
|
||||
++ edit :: change the bed
|
||||
|= bed=bein
|
||||
^+ +>
|
||||
=. q.q.yar [~ bed]
|
||||
?> ?=(^ q.q.yar)
|
||||
%- curb
|
||||
|- ^- (list blit)
|
||||
?^ hyr.u.q.q.yar
|
||||
=+ ris=:(weld "(reverse-i-search)'" (tufa u.hyr.u.q.q.yar) "': ")
|
||||
%= $
|
||||
pot.bed ris
|
||||
pol.bed (lent ris)
|
||||
hyr.u.q.q.yar ~
|
||||
==
|
||||
:~ [%hop (add pol.bed bus.bed)]
|
||||
:- %lin
|
||||
%+ weld pot.bed
|
||||
?- buy.bed
|
||||
%none but.bed
|
||||
%text but.bed
|
||||
%pass `(list ,@)`(runt [(lent but.bed) '*'] ~)
|
||||
==
|
||||
==
|
||||
::
|
||||
++ fume :: print tank, prefix
|
||||
|= [pef=@tD tac=tank]
|
||||
^+ +>
|
||||
=+ wol=(~(win re tac) 2 p.q.yar)
|
||||
%- furl
|
||||
%+ turn wol
|
||||
|= a=tape ^- tape
|
||||
?> ?=([@ @ *] a)
|
||||
[pef ' ' t.t.a]
|
||||
::
|
||||
++ furl :: print wall
|
||||
|= wol=(list tape)
|
||||
^+ +>
|
||||
=. +>
|
||||
%- curb
|
||||
%- flop
|
||||
|- ^- (list blit)
|
||||
?~ wol ~
|
||||
[[%lin (tuba i.wol)] [%mor ~] $(wol t.wol)]
|
||||
?~ q.q.yar +>
|
||||
(edit(q.q.yar ~) u.q.q.yar)
|
||||
::
|
||||
++ gore :: move in history
|
||||
|= hup=@ud
|
||||
^+ +>
|
||||
=+ but=(goth hup)
|
||||
=+ bul=(lent but)
|
||||
%- edit
|
||||
?> ?=(^ q.q.yar)
|
||||
%= u.q.q.yar
|
||||
hiz hup
|
||||
hym %+ ~(put by hym.u.q.q.yar)
|
||||
hiz.u.q.q.yar
|
||||
but.u.q.q.yar
|
||||
bus bul
|
||||
bul bul
|
||||
but but
|
||||
==
|
||||
::
|
||||
++ goth :: extract history
|
||||
|= hup=@ud
|
||||
?> ?=(^ q.q.yar)
|
||||
=+ byt=(~(get by hym.u.q.q.yar) hup)
|
||||
?^ byt u.byt
|
||||
(tuba (rip 3 (snag hup q.hyt.u.q.q.yar)))
|
||||
::
|
||||
++ kill :: add to kill ring
|
||||
|= txt=(list ,@c)
|
||||
^+ +>
|
||||
=> ?. =(16 p.r.q.yar) .
|
||||
.(p.r.q.yar 15, r.r.q.yar (scag 15 r.r.q.yar))
|
||||
%= +>
|
||||
p.r.q.yar +(p.r.q.yar)
|
||||
q.r.q.yar 0
|
||||
r.r.q.yar [txt r.r.q.yar]
|
||||
==
|
||||
::
|
||||
++ look :: search in history
|
||||
|= [hup=@ud txt=(list ,@c)]
|
||||
^+ +>
|
||||
=+ ^= beg
|
||||
|= [a=(list ,@c) b=(list ,@c)] ^- ?
|
||||
?~(a & ?~(b | &(=(i.a i.b) $(a t.a, b t.b))))
|
||||
=+ ^= mid
|
||||
|= [a=(list ,@c) b=(list ,@c)] ^- ?
|
||||
?~(a & ?~(b | |((beg a b) $(b t.b))))
|
||||
?> ?=(^ q.q.yar)
|
||||
?: =(hup p.hyt.u.q.q.yar)
|
||||
beep
|
||||
=+ but=(goth hup)
|
||||
?: (mid txt but)
|
||||
(gore(hyr.u.q.q.yar [~ txt]) hup)
|
||||
$(hup +(hup))
|
||||
::
|
||||
++ leap :: accept response
|
||||
|= [tea=wire sih=sign]
|
||||
^+ +>
|
||||
?- -.+.sih
|
||||
%crud :: error trace
|
||||
=. q.+.sih [[%leaf (trip p.+.sih)] q.+.sih]
|
||||
|- ^+ +>.^$
|
||||
?~ q.+.sih +>.^$
|
||||
(fume:$(q.+.sih t.q.+.sih) '!' `tank`i.q.+.sih)
|
||||
::
|
||||
%mean ~& %dill-mean +>.$
|
||||
%nice +>.$
|
||||
%note ?.(p.yar +>.$ (fume p.+.sih q.+.sih)) :: debug message
|
||||
?(%rush %rust) :: XX reset prompt
|
||||
=. mos :_(mos [hen %pass tea %g %took [our /terminal] our])
|
||||
?> ?=(%term-line +>-.sih)
|
||||
=. +>.$
|
||||
=+ lis=(scag 1.000 r.q.sih)
|
||||
=- (furl (zing (turn (flop lis) -)))
|
||||
|= a=tark
|
||||
^- wall
|
||||
?+ -.a (~(win re a) 0 p.q.yar)
|
||||
%stem
|
||||
?: =(q.s.yar p.a) ~
|
||||
~[(welp ~(ram re q.a) ~(ram re r.a))]
|
||||
==
|
||||
?. (levy r.q.sih |=(a=tark ?=(%stem -.a)))
|
||||
+>.$ :: XX separate prompt/history messages
|
||||
%- edit
|
||||
=| bed=bein
|
||||
=+ ^= hyt ^- hist
|
||||
=+ hyt=(~(get by r.yar) /)
|
||||
?~(hyt *hist u.hyt)
|
||||
?: &(?=(^ q.q.yar) =(/ hux.u.q.q.yar))
|
||||
=+ bun=(rip 5 (turf r.p.q.sih))
|
||||
%= u.q.q.yar
|
||||
bul ?~ r.p.q.sih bul.u.q.q.yar (lent bun)
|
||||
bus ?~ r.p.q.sih bus.u.q.q.yar (lent bun)
|
||||
but ?~ r.p.q.sih but.u.q.q.yar bun
|
||||
hyt [+(p.hyt) [%$ q.hyt]]
|
||||
pot (trip p.p.q.sih)
|
||||
pol (met 3 p.p.q.sih)
|
||||
buy q.p.q.sih
|
||||
==
|
||||
%_ bed
|
||||
bul (met 3 r.p.q.sih)
|
||||
bus (met 3 r.p.q.sih)
|
||||
but (rip 3 r.p.q.sih)
|
||||
buy q.p.q.sih
|
||||
hux /
|
||||
hiz 0
|
||||
hyt [+(p.hyt) [%$ q.hyt]]
|
||||
pot (trip p.p.q.sih)
|
||||
pol (met 3 p.p.q.sih)
|
||||
==
|
||||
::
|
||||
%sage :: write a jamfile
|
||||
%= +>.$
|
||||
mos :_(mos [hen [%give %blit [%sag p.+.sih q.+.sih] ~]])
|
||||
==
|
||||
?(%init %logo %veer %vega %verb) :: drop-throughs
|
||||
+>(mos :_(mos [hen %give +.sih]))
|
||||
%writ :: file exists
|
||||
%_ +>.$
|
||||
mos
|
||||
:_ mos
|
||||
[hen %pass /term-show %g %show [our /terminal] our /lines]
|
||||
==
|
||||
::
|
||||
%wake
|
||||
?: (lte (sub now ~s15) q.s.yar)
|
||||
%_ +>.$
|
||||
mos
|
||||
:_ mos
|
||||
[hen %pass /activity %t %wait (add q.s.yar ~s15)]
|
||||
==
|
||||
%_ +>.$
|
||||
p.s.yar |
|
||||
mos :_(mos (poke %term-in -:!>(*term-in) / %type %|))
|
||||
==
|
||||
==
|
||||
::
|
||||
++ lear :: handle request
|
||||
|= kyz=kiss
|
||||
^+ +>
|
||||
?- -.kyz
|
||||
%flog !!
|
||||
%noop +>
|
||||
%belt :: terminal input
|
||||
=. +>.$
|
||||
?. ?=(?(%bac %del %ret %txt) -.p.kyz) +>.$
|
||||
?: p.s.yar +>.$(s.yar [& now])
|
||||
%_ +>.$
|
||||
s.yar [& now]
|
||||
mos
|
||||
:_ :_ mos
|
||||
[hen %pass /activity %t %wait (add ?:(p.s.yar q.s.yar now) ~s15)]
|
||||
(poke %term-in -:!>(*term-in) / %type %&)
|
||||
==
|
||||
?~ q.q.yar
|
||||
%^ furl
|
||||
"Downloading files from ticketing ship, please wait until"
|
||||
"a prompt shows up. This could take several minutes."
|
||||
~
|
||||
?^ hyr.u.q.q.yar :: live search
|
||||
?+ p.kyz $(hiz.u.q.q.yar 0, hyr.u.q.q.yar ~)
|
||||
[%bac *]
|
||||
?: =(~ u.hyr.u.q.q.yar)
|
||||
(curb [[%bel ~] ~])
|
||||
%- edit
|
||||
%= u.q.q.yar
|
||||
hyr [~ (scag (dec (lent u.hyr.u.q.q.yar)) u.hyr.u.q.q.yar)]
|
||||
==
|
||||
::
|
||||
[%txt *] (look hiz.u.q.q.yar (weld u.hyr.u.q.q.yar p.p.kyz))
|
||||
[%ctl %g] (edit u.q.q.yar(bul 0, bus 0, but ~, hiz 0, hyr ~))
|
||||
[%ctl %r]
|
||||
?: =(p.hyt.u.q.q.yar hiz.u.q.q.yar)
|
||||
beep
|
||||
(look +(hiz.u.q.q.yar) u.hyr.u.q.q.yar)
|
||||
==
|
||||
?- -.p.kyz
|
||||
%aro :: arrow
|
||||
?- p.p.kyz
|
||||
%d :: down
|
||||
?: =(0 hiz.u.q.q.yar)
|
||||
beep
|
||||
(gore (dec hiz.u.q.q.yar))
|
||||
::
|
||||
%l :: left
|
||||
?: =(0 bus.u.q.q.yar)
|
||||
beep
|
||||
(edit u.q.q.yar(bus (dec bus.u.q.q.yar)))
|
||||
::
|
||||
%r :: right
|
||||
?: =(bul.u.q.q.yar bus.u.q.q.yar)
|
||||
beep
|
||||
(edit u.q.q.yar(bus +(bus.u.q.q.yar)))
|
||||
::
|
||||
%u
|
||||
=+ hup=+(hiz.u.q.q.yar)
|
||||
?: =(hup p.hyt.u.q.q.yar)
|
||||
beep
|
||||
(gore hup)
|
||||
==
|
||||
::
|
||||
%bac :: backspace
|
||||
^+ +>.$
|
||||
?: =(0 bus.u.q.q.yar)
|
||||
(curb `(list blit)`[[%bel ~] ~])
|
||||
%- edit
|
||||
%= u.q.q.yar
|
||||
bus (dec bus.u.q.q.yar)
|
||||
bul (dec bul.u.q.q.yar)
|
||||
but
|
||||
%+ weld
|
||||
(scag (dec bus.u.q.q.yar) but.u.q.q.yar)
|
||||
(slag bus.u.q.q.yar but.u.q.q.yar)
|
||||
==
|
||||
::
|
||||
%ctl :: control
|
||||
?+ p.p.kyz
|
||||
beep
|
||||
%a (edit u.q.q.yar(bus 0))
|
||||
%b $(kyz [%belt %aro %l])
|
||||
%d ?: ?& =(0 bul.u.q.q.yar)
|
||||
=(0 bus.u.q.q.yar)
|
||||
==
|
||||
+>.$(mos :_(mos (poke %term-in -:!>(*term-in) / %cmd %d)))
|
||||
$(kyz [%belt %del ~])
|
||||
%e (edit u.q.q.yar(bus bul.u.q.q.yar))
|
||||
%f $(kyz [%belt %aro %r])
|
||||
%g +>.$(mos :_(mos (poke %term-in -:!>(*term-in) / %cmd %g)))
|
||||
%k ?: =(bul.u.q.q.yar bus.u.q.q.yar)
|
||||
beep
|
||||
=> .(+>.$ (kill (slag bus.u.q.q.yar but.u.q.q.yar)))
|
||||
%- edit
|
||||
?> ?=(^ q.q.yar)
|
||||
%= u.q.q.yar
|
||||
bul bus.u.q.q.yar
|
||||
but (scag bus.u.q.q.yar but.u.q.q.yar)
|
||||
==
|
||||
%t ?: (lth bul.u.q.q.yar 2)
|
||||
beep
|
||||
=+ ^= pos
|
||||
?: =(bul.u.q.q.yar bus.u.q.q.yar)
|
||||
(sub bus.u.q.q.yar 2)
|
||||
?: =(0 bus.u.q.q.yar)
|
||||
bus.u.q.q.yar
|
||||
(dec bus.u.q.q.yar)
|
||||
%- edit
|
||||
%= u.q.q.yar
|
||||
bus (add 2 pos)
|
||||
but %+ weld
|
||||
%+ weld
|
||||
(scag pos but.u.q.q.yar)
|
||||
^- (list ,@c) :+
|
||||
(snag +(pos) but.u.q.q.yar)
|
||||
(snag pos but.u.q.q.yar)
|
||||
~
|
||||
(slag (add 2 pos) but.u.q.q.yar)
|
||||
==
|
||||
%l +>.$(mos :_(mos [hen %give %blit [[%clr ~] ~]]))
|
||||
%n $(kyz [%belt %aro %d])
|
||||
%o %_ +>.$
|
||||
mos
|
||||
:_ :_ mos
|
||||
[hen %pass /term-show %g %nuke [our /terminal] our]
|
||||
[hen %pass /term-show %g %show [our /terminal] our /lines]
|
||||
==
|
||||
%p $(kyz [%belt %aro %u])
|
||||
%u ?: =(0 bus.u.q.q.yar)
|
||||
beep
|
||||
=> .(+>.$ (kill (scag bus.u.q.q.yar but.u.q.q.yar)))
|
||||
%- edit
|
||||
?> ?=(^ q.q.yar)
|
||||
%= u.q.q.yar
|
||||
bus 0
|
||||
bul (sub bul.u.q.q.yar bus.u.q.q.yar)
|
||||
but (slag bus.u.q.q.yar but.u.q.q.yar)
|
||||
==
|
||||
%r (edit u.q.q.yar(hyr [~ ~]))
|
||||
%w ?: =(0 bus.u.q.q.yar)
|
||||
beep
|
||||
=+ bow=(wob u.q.q.yar)
|
||||
=+ sow=(sub bus.u.q.q.yar bow)
|
||||
=> .(+>.$ (kill (swag [bow sow] but.u.q.q.yar)))
|
||||
%- edit
|
||||
?> ?=(^ q.q.yar)
|
||||
%= u.q.q.yar
|
||||
bus bow
|
||||
bul (sub bul.u.q.q.yar sow)
|
||||
but %+ welp
|
||||
(scag bow but.u.q.q.yar)
|
||||
(slag bus.u.q.q.yar but.u.q.q.yar)
|
||||
==
|
||||
%x +>.$(mos :_(mos (poke %term-in -:!>(*term-in) / %cmd %x)))
|
||||
%y ?: =(0 p.r.q.yar)
|
||||
beep
|
||||
$(kyz [%belt %txt (snag q.r.q.yar r.r.q.yar)])
|
||||
==
|
||||
::
|
||||
%del :: delete
|
||||
?: =(bul.u.q.q.yar bus.u.q.q.yar)
|
||||
beep
|
||||
%- edit
|
||||
%= u.q.q.yar
|
||||
bul (dec bul.u.q.q.yar)
|
||||
but
|
||||
%+ weld
|
||||
(scag bus.u.q.q.yar but.u.q.q.yar)
|
||||
(slag +(bus.u.q.q.yar) but.u.q.q.yar)
|
||||
==
|
||||
::
|
||||
%met :: meta
|
||||
?+ p.p.kyz
|
||||
beep
|
||||
%f
|
||||
?: =(bul.u.q.q.yar bus.u.q.q.yar)
|
||||
beep
|
||||
(edit u.q.q.yar(bus (wod u.q.q.yar)))
|
||||
::
|
||||
%b
|
||||
?: =(0 bus.u.q.q.yar)
|
||||
beep
|
||||
(edit u.q.q.yar(bus (wob u.q.q.yar)))
|
||||
::
|
||||
%y
|
||||
?: =(0 p.r.q.yar)
|
||||
beep
|
||||
=+ dol=(snag q.r.q.yar r.r.q.yar)
|
||||
=+ leo=(lent dol)
|
||||
?. (gte bus.u.q.q.yar leo)
|
||||
beep
|
||||
=+ pey=(sub bus.u.q.q.yar leo)
|
||||
?. =(dol (swag [pey leo] but.u.q.q.yar))
|
||||
beep
|
||||
=. q.r.q.yar ?:(=(p.r.q.yar +(q.r.q.yar)) 0 +(q.r.q.yar))
|
||||
=+ ney=(snag q.r.q.yar r.r.q.yar)
|
||||
=+ lye=(lent ney)
|
||||
%- edit
|
||||
%= u.q.q.yar
|
||||
bus (sub (add bus.u.q.q.yar lye) leo)
|
||||
bul (sub (add bul.u.q.q.yar lye) leo)
|
||||
but %+ weld
|
||||
(scag pey but.u.q.q.yar)
|
||||
%+ weld
|
||||
`(list ,@c)`ney :: XX weird fuse-loop
|
||||
(slag bus.u.q.q.yar but.u.q.q.yar)
|
||||
==
|
||||
==
|
||||
::
|
||||
%ret :: return
|
||||
?: =(%none buy.u.q.q.yar) beep
|
||||
=+ jab=(rap 3 (tufa but.u.q.q.yar))
|
||||
%= +>.$
|
||||
q.q.yar ~
|
||||
r.yar
|
||||
?: |(=(%$ jab) =(%pass buy.u.q.q.yar))
|
||||
r.yar
|
||||
%+ ~(put by r.yar)
|
||||
hux.u.q.q.yar
|
||||
[p.hyt.u.q.q.yar [jab ?~(q.hyt.u.q.q.yar ~ +.q.hyt.u.q.q.yar)]]
|
||||
::
|
||||
mos
|
||||
:* (poke %term-ctrl -:!>(%hail) %hail)
|
||||
[hen %give [%bbye ~]]
|
||||
(poke %term-in -:!>(*term-in) / %line jab)
|
||||
[hen %give [%blit [[%mor ~] ~]]]
|
||||
mos
|
||||
==
|
||||
==
|
||||
::
|
||||
%txt :: text keys
|
||||
?: =(%none buy.u.q.q.yar) beep
|
||||
=+ let=(lent p.p.kyz)
|
||||
%- edit
|
||||
%= u.q.q.yar
|
||||
bus (add let bus.u.q.q.yar)
|
||||
bul (add let bul.u.q.q.yar)
|
||||
but
|
||||
;: weld
|
||||
(scag bus.u.q.q.yar but.u.q.q.yar)
|
||||
p.p.kyz
|
||||
(slag bus.u.q.q.yar but.u.q.q.yar)
|
||||
==
|
||||
==
|
||||
==
|
||||
::
|
||||
%blew +>.$(p.q.yar p.p.kyz) :: window size
|
||||
%boot
|
||||
%= +>.$
|
||||
mos
|
||||
:_(mos [hen %pass ~ (note %a p.kyz)])
|
||||
==
|
||||
::
|
||||
%crud :: error trace
|
||||
=. q.kyz [[%leaf (trip p.kyz)] q.kyz]
|
||||
|- ^+ +>.^$
|
||||
?~ q.kyz +>.^$
|
||||
(fume:$(q.kyz t.q.kyz) '!' `tank`i.q.kyz)
|
||||
::
|
||||
%flow
|
||||
+>.$
|
||||
::
|
||||
%hail :: refresh
|
||||
+>.$
|
||||
::+>.$(mos :_(mos (poke %term-ctrl -:!>(%hail) %hail)))
|
||||
::
|
||||
%harm :: all terms hung up
|
||||
=+ nug=((map duct yard) [[hen (~(get by dug) hen)] ~ ~])
|
||||
^+ +>.$
|
||||
%= +>.$
|
||||
dug nug
|
||||
::S mos :_(mos [hen %pass ~ %b kyz])
|
||||
==
|
||||
::
|
||||
%hook :: this term hung up
|
||||
~& %dill-hook-not-implemented
|
||||
+>.$
|
||||
::S +>.$(dug (~(del by dug) hen), mos :_(mos [hen %pass ~ %b kyz]))
|
||||
::
|
||||
%init
|
||||
=. def `(fall def +.hen)
|
||||
%= +>.$
|
||||
our p.kyz
|
||||
mos
|
||||
:_ mos
|
||||
[(need def) %pass / %c %warp [p.kyz p.kyz] %main `[%& %y [%ud 1] /]]
|
||||
==
|
||||
::
|
||||
%talk (furl (~(win re p.kyz) 0 p.q.yar)) :: program output
|
||||
%text $(kyz [%talk %leaf p.kyz]) :: simple message
|
||||
==
|
||||
::
|
||||
++ poke
|
||||
|= msg=mess
|
||||
^- move
|
||||
:^ hen %pass /term-mess
|
||||
:^ %g %mess [our /terminal]
|
||||
:- our msg
|
||||
::
|
||||
++ yerk :: complete core
|
||||
^- [p=(list move) q=ship r=(unit duct) s=(map duct yard)]
|
||||
:^ (flop mos) our def
|
||||
(~(put by dug) hen yar)
|
||||
--
|
||||
--
|
||||
=| $: %1 ::
|
||||
our=ship ::
|
||||
def=(unit duct) ::
|
||||
dug=(map duct yard) ::
|
||||
== ::
|
||||
|= [now=@da eny=@ ski=sled] :: current invocation
|
||||
|% :: poke/peek pattern
|
||||
++ call :: handle request
|
||||
|= $: hen=duct
|
||||
hic=(hypo (hobo kiss))
|
||||
==
|
||||
^- [p=(list move) q=_..^$]
|
||||
=> %= . :: XX temporary
|
||||
q.hic
|
||||
^- kiss
|
||||
?: ?=(%soft -.q.hic)
|
||||
:: ~& [%dill-call-soft (,@tas `*`-.p.q.hic)]
|
||||
((hard kiss) p.q.hic)
|
||||
?: (~(nest ut -:!>(*kiss)) | p.hic) q.hic
|
||||
~& [%dill-call-flub (,@tas `*`-.q.hic)]
|
||||
((hard kiss) q.hic)
|
||||
==
|
||||
?: ?=(%flog -.q.hic)
|
||||
:_ ..^$
|
||||
%+ turn (~(tap by dug) *(list ,[p=duct q=yard]))
|
||||
|=([a=duct b=yard] [a %slip %d p.q.hic])
|
||||
=+ res=yerk:(lear:(dy hen our now def dug) q.hic)
|
||||
[-.res ..^$(our +<.res, dug +>+.res, def +>-.res)]
|
||||
::
|
||||
++ doze
|
||||
|= [now=@da hen=duct]
|
||||
^- (unit ,@da)
|
||||
~
|
||||
::
|
||||
++ load :: XX LEGACY 12-16-2014
|
||||
|= $= old
|
||||
$% [%0 our=ship def=(unit duct) dug=(map duct yord)]
|
||||
[%1 our=ship def=(unit duct) dug=(map duct yard)]
|
||||
==
|
||||
^+ ..^$
|
||||
?- -.old
|
||||
%1 %_(..^$ our our.old, def def.old, dug dug.old)
|
||||
%0 %= $
|
||||
old
|
||||
%= old
|
||||
- %1
|
||||
dug (~(run by dug.old) |=(yor=yord [p q r | *@da]:yor))
|
||||
==
|
||||
==
|
||||
==
|
||||
::
|
||||
++ scry
|
||||
|= [fur=(unit (set monk)) ren=@tas his=ship syd=desk lot=coin tyl=path]
|
||||
^- (unit (unit (pair mark ,*)))
|
||||
[~ ~ [%tank >dug<]]
|
||||
::
|
||||
++ stay [%1 our def dug]
|
||||
++ take :: process move
|
||||
|= [tea=wire hen=duct hin=(hypo sign)]
|
||||
^- [p=(list move) q=_..^$]
|
||||
=+ res=yerk:(leap:(dy hen our now def dug) tea q.hin)
|
||||
[-.res ..^$(our +<.res, dug +>+.res, def +>-.res)]
|
||||
--
|
345
arvo/dull.hoon
345
arvo/dull.hoon
@ -1,345 +0,0 @@
|
||||
!:
|
||||
:: dill (4d), terminal handling
|
||||
::
|
||||
|= pit=vase
|
||||
=> |% :: interface tiles
|
||||
++ axle :: all dill state
|
||||
$: %2 ::
|
||||
ore=(unit ship) :: identity once set
|
||||
hey=(unit duct) :: default duct
|
||||
dug=(map duct axon) :: conversations
|
||||
== ::
|
||||
++ axon :: dill per duct
|
||||
$: ram=term :: console program
|
||||
wid=_80 :: terminal width
|
||||
pos=@ud :: cursor position
|
||||
see=(list ,@c) :: current line
|
||||
== ::
|
||||
-- ::
|
||||
=> |% :: console protocol
|
||||
++ console-action :: console to app
|
||||
$% [%det console-change] :: edit prompt line
|
||||
[%inn ~] :: enter session
|
||||
[%out ~] :: exit session
|
||||
[%ret ~] :: submit and clear
|
||||
== ::
|
||||
++ console-buffer (list ,@c) :: command state
|
||||
++ console-change :: network change
|
||||
$: ler=console-clock :: destination clock
|
||||
haw=@uvH :: source hash
|
||||
ted=console-edit :: state change
|
||||
== ::
|
||||
++ console-clock ,[own=@ud his=@ud] :: vector clock
|
||||
++ console-edit :: shared state change
|
||||
$% [%del p=@ud] :: delete one at
|
||||
[%ins p=@ud q=@c] :: insert at
|
||||
[%mor p=(list console-edit)] :: combination
|
||||
[%nop ~] :: no-op
|
||||
[%set p=console-buffer] :: discontinuity
|
||||
== ::
|
||||
++ console-effect :: app to console
|
||||
$% [%bel ~] :: beep
|
||||
[%blk p=@ud q=@c] :: blink/match char at
|
||||
[%clr ~] :: clear screen
|
||||
[%det console-change] :: edit input
|
||||
[%nex ~] :: save and clear input
|
||||
[%tan p=(list tank)] :: classic tank
|
||||
:: [%taq p=tanq] :: modern tank
|
||||
[%txt p=tape] :: text line
|
||||
== ::
|
||||
++ dill-belt :: console input
|
||||
$% [%aro p=?(%d %l %r %u)] :: arrow key
|
||||
[%bac ~] :: true backspace
|
||||
[%cru p=@tas q=(list tank)] :: echo error
|
||||
[%ctl p=@ud] :: control-key
|
||||
[%del ~] :: true delete
|
||||
[%met p=@ud] :: meta-key
|
||||
[%ret ~] :: return
|
||||
[%rez p=@ud q=@ud] :: resize, cols, rows
|
||||
[%txt p=(list ,@c)] :: utf32 text
|
||||
[%yow p=gill] :: connect to app
|
||||
== ::
|
||||
++ dill-blit :: console output
|
||||
$% [%bel ~] :: make a noise
|
||||
[%clr ~] :: clear the screen
|
||||
[%hop p=@ud] :: set cursor position
|
||||
[%pro p=(list ,@c)] :: show as cursor/line
|
||||
[%out p=(list ,@c)] :: send output line
|
||||
[%sag p=path q=*] :: save to jamfile
|
||||
[%sav p=path q=@] :: save to file
|
||||
== ::
|
||||
++ gill ,@tas :: general contact
|
||||
-- => ::
|
||||
|% :: protocol below
|
||||
++ blew ,[p=@ud q=@ud] :: columns rows
|
||||
++ belt :: raw console input
|
||||
$% [%aro p=?(%d %l %r %u)] :: arrow key
|
||||
[%bac ~] :: true backspace
|
||||
[%ctl p=@ud] :: control-key
|
||||
[%del ~] :: true delete
|
||||
[%met p=@ud] :: meta-key
|
||||
[%ret ~] :: return
|
||||
[%txt p=(list ,@c)] :: utf32 text
|
||||
== ::
|
||||
++ blit :: raw console output
|
||||
$% [%bel ~] :: make a noise
|
||||
[%clr ~] :: clear the screen
|
||||
[%hop p=@ud] :: set cursor position
|
||||
[%lin p=(list ,@c)] :: set current line
|
||||
[%mor ~] :: newline
|
||||
[%sag p=path q=*] :: save to jamfile
|
||||
[%sav p=path q=@] :: save to file
|
||||
== ::
|
||||
++ flog :: sent to %dill
|
||||
$% [%crud p=@tas q=(list tank)] ::
|
||||
[%text p=tape] ::
|
||||
[%veer p=@ta q=path r=@t] :: install vane
|
||||
[%vega p=path] :: reboot by path
|
||||
[%verb ~] :: verbose mode
|
||||
== ::
|
||||
++ gift :: out result <-$
|
||||
$% [%bbye ~] :: reset prompt
|
||||
[%blit p=(list blit)] :: terminal output
|
||||
[%init p=@p] :: set owner
|
||||
[%logo ~] :: logout
|
||||
[%veer p=@ta q=path r=@t] :: install vane
|
||||
[%vega p=path] :: reboot by path
|
||||
[%verb ~] :: verbose mode
|
||||
== ::
|
||||
++ kiss :: in request ->$
|
||||
$% [%belt p=belt] :: terminal input
|
||||
[%blew p=blew] :: terminal config
|
||||
[%boot p=*] :: weird %dill boot
|
||||
[%crud p=@tas q=(list tank)] :: error with trace
|
||||
[%flog p=flog] :: wrapped error
|
||||
[%flow p=@tas q=(list gill)] :: terminal config
|
||||
[%hail ~] :: terminal refresh
|
||||
[%hook ~] :: this term hung up
|
||||
[%harm ~] :: all terms hung up
|
||||
[%init p=ship] :: after gall ready
|
||||
[%noop ~] :: no operation
|
||||
[%talk p=tank] ::
|
||||
[%text p=tape] ::
|
||||
[%veer p=@ta q=path r=@t] :: install vane
|
||||
[%vega p=path] :: reboot by path
|
||||
[%verb ~] :: verbose mode
|
||||
== ::
|
||||
-- => ::
|
||||
|% :: protocol outward
|
||||
++ mess ::
|
||||
$% [%dill-belt p=(hypo dill-belt)] ::
|
||||
== ::
|
||||
++ move ,[p=duct q=(mold note gift)] :: local move
|
||||
++ note-ames :: weird ames move
|
||||
$% [%make p=(unit ,@t) q=@ud r=@ s=?] ::
|
||||
[%sith p=@p q=@uw r=?] ::
|
||||
== ::
|
||||
++ note-dill :: note to self, odd
|
||||
$% [%crud p=@tas q=(list tank)] ::
|
||||
[%text p=tape] ::
|
||||
[%veer p=@ta q=path r=@t] :: install vane
|
||||
[%vega p=path] :: reboot by path
|
||||
[%verb ~] :: verbose mode
|
||||
== ::
|
||||
++ note-gall :: outbound message
|
||||
$% [%mess p=[ship q=path] q=ship r=mess] ::
|
||||
[%nuke p=[p=ship q=path] q=ship] ::
|
||||
[%show p=[p=ship q=path] q=ship r=path] ::
|
||||
[%took p=[p=ship q=path] q=ship] ::
|
||||
== ::
|
||||
++ note ::
|
||||
$% [%a note-ames] :: out request $->
|
||||
[%d note-dill] ::
|
||||
[%g note-gall] ::
|
||||
== ::
|
||||
++ riff ,[p=desk q=(unit rave)] :: see %clay
|
||||
++ sign-ames ::
|
||||
$% [%nice ~] ::
|
||||
== ::
|
||||
++ sign-clay ::
|
||||
$% [%note p=@tD q=tank] ::
|
||||
== ::
|
||||
++ sign-gall ::
|
||||
$% [%crud p=@tas q=(list tank)] ::
|
||||
[%mean p=ares] ::
|
||||
[%nice ~] ::
|
||||
[%rush %dill-blit dill-blit] ::
|
||||
== ::
|
||||
++ sign-time ::
|
||||
$% [%wake ~] ::
|
||||
== ::
|
||||
++ sign :: in result $<-
|
||||
$% [%a sign-ames] ::
|
||||
[%c sign-clay] ::
|
||||
[%g sign-gall] ::
|
||||
[%t sign-time] ::
|
||||
== ::
|
||||
:::::::: :: dill tiles
|
||||
--
|
||||
=| all=axle
|
||||
|= [now=@da eny=@ ski=sled] :: current invocation
|
||||
=> |%
|
||||
++ as :: per cause
|
||||
|_ $: [moz=(list move) hen=duct our=ship]
|
||||
axon
|
||||
==
|
||||
++ abet :: resolve
|
||||
^- [(list move) axle]
|
||||
[(flop moz) all(dug (~(put by dug.all) hen +<+))]
|
||||
::
|
||||
++ call :: receive input
|
||||
|= kyz=kiss
|
||||
^+ +>
|
||||
?+ -.kyz ~& [%strange-kiss -.kyz] +>
|
||||
%flow +>
|
||||
%belt (send `dill-belt`p.kyz)
|
||||
%crud (send `dill-belt`[%cru p.kyz q.kyz])
|
||||
%blew (send %rez p.p.kyz q.p.kyz)
|
||||
%veer (dump kyz)
|
||||
%vega (dump kyz)
|
||||
%verb (dump kyz)
|
||||
==
|
||||
::
|
||||
++ dump :: pass down to hey
|
||||
|= git=gift
|
||||
?> ?=(^ hey.all)
|
||||
+>(moz [[u.hey.all %give git] moz])
|
||||
::
|
||||
++ done :: return gift
|
||||
|= git=gift
|
||||
+>(moz :_(moz [hen %give git]))
|
||||
::
|
||||
++ from :: receive belt
|
||||
|= bit=dill-blit
|
||||
^+ +>
|
||||
?: ?=(%out -.bit)
|
||||
%+ done %blit
|
||||
:~ [%lin p.bit]
|
||||
[%mor ~]
|
||||
[%lin see]
|
||||
[%hop pos]
|
||||
==
|
||||
?: ?=(%pro -.bit)
|
||||
(done(see p.bit) %blit [[%lin p.bit] [%hop pos] ~])
|
||||
?: ?=(%hop -.bit)
|
||||
(done(pos p.bit) %blit [bit ~])
|
||||
(done %blit [bit ~])
|
||||
::
|
||||
++ init :: initialize
|
||||
|= gyl=(list gill)
|
||||
^+ +>
|
||||
=. moz :_(moz [hen %pass ~ %g %show [our [ram ~]] our ~])
|
||||
|- ^+ +>.^$
|
||||
?~ gyl +>.^$
|
||||
$(gyl t.gyl, +>.^$ (send %yow i.gyl))
|
||||
::
|
||||
++ send :: send action
|
||||
|= bet=dill-belt
|
||||
%_ +>
|
||||
moz
|
||||
:_ moz
|
||||
[hen %pass ~ %g %mess [our [ram ~]] our [%dill-belt -:!>(bet) bet]]
|
||||
==
|
||||
::
|
||||
++ take :: receive
|
||||
|= sih=sign
|
||||
^+ +>
|
||||
?- sih
|
||||
[%a %nice *]
|
||||
:: ~& [%take-nice-ames sih]
|
||||
+>
|
||||
::
|
||||
[%c %note *]
|
||||
(from %out (tuba ~(ram re q.+.sih)))
|
||||
::
|
||||
[%g %crud *]
|
||||
(send %cru p.+.sih q.+.sih)
|
||||
::
|
||||
[%g %mean *]
|
||||
+>(moz [[hen %give %logo ~] moz])
|
||||
::
|
||||
[%g %nice *]
|
||||
:: ~& [%take-nice sih]
|
||||
+>
|
||||
::
|
||||
[%g %rush %dill-blit *]
|
||||
=. moz :_(moz `move`[hen %pass ~ %g %took [our [ram ~]] our])
|
||||
(from +>+.sih)
|
||||
::
|
||||
[%t %wake *]
|
||||
:: ~& %dill-wake
|
||||
+>
|
||||
==
|
||||
--
|
||||
::
|
||||
++ ax :: make ++as
|
||||
|= [hen=duct kyz=kiss] ::
|
||||
?~ ore.all ~
|
||||
=+ nux=(~(get by dug.all) hen)
|
||||
?^ nux (some ~(. as [~ hen u.ore.all] u.nux))
|
||||
?. ?=(%flow -.kyz) ~
|
||||
%- some
|
||||
%. q.kyz
|
||||
~(init as [~ hen u.ore.all] [p.kyz 80 0 (tuba "<{(trip p.kyz)}>")])
|
||||
--
|
||||
|% :: poke/peek pattern
|
||||
++ call :: handle request
|
||||
|= $: hen=duct
|
||||
hic=(hypo (hobo kiss))
|
||||
==
|
||||
^- [p=(list move) q=_..^$]
|
||||
=> %= . :: XX temporary
|
||||
q.hic
|
||||
^- kiss
|
||||
?: ?=(%soft -.q.hic)
|
||||
:: ~& [%dill-call-soft (,@tas `*`-.p.q.hic)]
|
||||
((hard kiss) p.q.hic)
|
||||
?: (~(nest ut -:!>(*kiss)) | p.hic) q.hic
|
||||
~& [%dill-call-flub (,@tas `*`-.q.hic)]
|
||||
((hard kiss) q.hic)
|
||||
==
|
||||
?: ?=(%boot -.q.hic)
|
||||
:_(..^$ [hen %pass ~ (note %a p.q.hic)]~)
|
||||
?: ?=(%flog -.q.hic)
|
||||
:_(..^$ ?~(hey.all ~ [u.hey.all %slip %d p.q.hic]~))
|
||||
?: ?=(%init -.q.hic)
|
||||
[~ ..^$(ore.all `p.q.hic)]
|
||||
=. hey.all ?^(hey.all hey.all `hen)
|
||||
=+ nus=(ax hen q.hic)
|
||||
?~ nus
|
||||
~& [%dill-no-flow q.hic]
|
||||
[~ ..^$]
|
||||
=^ moz all abet:(call:u.nus q.hic)
|
||||
[moz ..^$]
|
||||
::
|
||||
++ doze
|
||||
|= [now=@da hen=duct]
|
||||
^- (unit ,@da)
|
||||
~
|
||||
::
|
||||
++ load :: totally disabled
|
||||
|= old=*
|
||||
..^$(ore.all `~zod)
|
||||
::
|
||||
++ scry
|
||||
|= [fur=(unit (set monk)) ren=@tas his=ship syd=desk lot=coin tyl=path]
|
||||
^- (unit (unit (pair mark ,*)))
|
||||
[~ ~]
|
||||
::
|
||||
++ stay all
|
||||
::
|
||||
++ take :: process move
|
||||
|= [tea=wire hen=duct hin=(hypo sign)]
|
||||
^- [p=(list move) q=_..^$]
|
||||
?: =(~ ore.all)
|
||||
~& [%take-back q.hin]
|
||||
[~ ..^$]
|
||||
?. (~(has by dug.all) hen)
|
||||
~& [%take-weird-sign q.hin]
|
||||
~& [%take-weird-hen hen]
|
||||
[~ ..^$]
|
||||
=+ our=?>(?=(^ ore.all) u.ore.all)
|
||||
=^ moz all
|
||||
abet:(~(take as [~ hen our] (~(got by dug.all) hen)) q.hin)
|
||||
[moz ..^$]
|
||||
--
|
@ -123,7 +123,7 @@
|
||||
[%vale p=mark q=ship r=*] :: validate [our his]
|
||||
== ::
|
||||
++ note-ford :: note to ford
|
||||
$% [%exec p=@p q=(unit silk)] :: make / kill
|
||||
$% [%exec p=@p q=beak r=(unit silk)] :: make / kill
|
||||
== ::
|
||||
++ note-gall :: note to %gall
|
||||
$% [%mess p=[p=ship q=path] q=ship r=cage] ::
|
||||
@ -133,7 +133,7 @@
|
||||
[%nice ~] ::
|
||||
== ::
|
||||
++ sign-ford :: sign from ford
|
||||
$% [%made p=@uvH q=(each cage tang)] :: computed result
|
||||
$% [%made p=@uvH q=(each gage tang)] :: computed result
|
||||
== ::
|
||||
++ note :: out request $->
|
||||
$% [%f note-ford] ::
|
||||
@ -270,12 +270,14 @@
|
||||
|= [pax=path kas=silk]
|
||||
^+ +>+>
|
||||
?> ?=(~ pux)
|
||||
(he-pass(poy `+>+<(pux `pax)) pax %f %exec our.hid `kas)
|
||||
=+ bek=[our.hid %home %da lat.hid]
|
||||
(he-pass(poy `+>+<.$(pux `pax)) pax %f %exec our.hid bek `kas)
|
||||
::
|
||||
++ dy-stop :: stop work
|
||||
^+ +>
|
||||
?~ pux +>
|
||||
(he-pass(poy ~) u.pux %f %exec our.hid ~)
|
||||
=+ bek=[our.hid %home %da lat.hid]
|
||||
(he-pass(poy ~) u.pux %f %exec our.hid bek ~)
|
||||
::
|
||||
++ dy-slam :: call by ford
|
||||
|= [pax=path gat=vase sam=vase]
|
||||
@ -607,12 +609,13 @@
|
||||
[& %$ "> "]
|
||||
::
|
||||
++ he-made :: result from ford
|
||||
|= [pax=path dep=@uvH rey=(each cage tang)]
|
||||
|= [pax=path dep=@uvH rey=(each gage tang)]
|
||||
^+ +>
|
||||
?> ?=(^ poy)
|
||||
=< he-pine
|
||||
?- -.rey
|
||||
%& %. p.rey
|
||||
%& ?> ?=(@ p.p.rey)
|
||||
%. p.rey
|
||||
=+ dye=~(. dy u.poy(pux ~))
|
||||
?+ pax !!
|
||||
[%hand ~] dy-hand:dye
|
||||
@ -699,7 +702,7 @@
|
||||
:- [ost ~]
|
||||
^- session
|
||||
:* *sole-share :: say=sole-share
|
||||
%main :: syd=desk
|
||||
%home :: syd=desk
|
||||
~ :: luc=(unit case)
|
||||
~ :: poy=(unit dojo-project)
|
||||
~ :: var=(map term cage)
|
492
base/app/helm/core.hook
Normal file
492
base/app/helm/core.hook
Normal file
@ -0,0 +1,492 @@
|
||||
:: :: ::
|
||||
:::: /hook/core/helm/app :: ::
|
||||
:: :: ::
|
||||
/? 314 :: zuse version
|
||||
/- *sole, *talk :: structures
|
||||
/+ sole, talk :: libraries
|
||||
:: :: ::
|
||||
:::: :: ::
|
||||
!: :: ::
|
||||
=> |% :: principal structures
|
||||
++ helm-house :: all state
|
||||
$: %0 :: state version
|
||||
bur=(unit (pair ship mace)) :: requesting ticket
|
||||
hoc=(map bone helm-session) :: consoles
|
||||
rem=(map desk merge-state) :: active merges
|
||||
== ::
|
||||
++ helm-session ::
|
||||
$: say=sole-share ::
|
||||
mud=(unit (sole-dialog ,@ud)) ::
|
||||
== ::
|
||||
++ merge-state :: merge data
|
||||
$: auto=? :: escalate on failure
|
||||
gem=germ :: strategy
|
||||
her=@p :: from ship
|
||||
sud=@tas :: from desk
|
||||
cas=case :: at case
|
||||
== ::
|
||||
++ funk (pair ,@ ,@) ::
|
||||
++ begs ,[his=@p tic=@p eny=@t ges=gens] :: begin data
|
||||
++ helm-wish ::
|
||||
$| $? %reset :: reset kernel
|
||||
%verb :: verbose mode
|
||||
== ::
|
||||
$% [%reload p=(list term)] :: reload vanes
|
||||
[%sync p=@tas q=@p r=@tas ~] ::
|
||||
== ::
|
||||
++ dill-flog :: sent to %dill
|
||||
$% [%crud p=%hax-init [%leaf p=tape] ~] :: initialize ship
|
||||
[%veer p=@ta q=path r=@t] :: install vane
|
||||
[%vega p=path] :: reboot by path
|
||||
[%verb ~] :: verbose mode
|
||||
== ::
|
||||
:: ::
|
||||
++ gift :: out result <-$
|
||||
$% [%mean p=ares] :: error
|
||||
[%nice ~] :: acknowledge
|
||||
[%rush %sole-effect sole-effect] :: effect
|
||||
== ::
|
||||
++ hapt ,[p=ship q=path] ::
|
||||
++ milk (trel ship desk silk) ::
|
||||
++ silk ::
|
||||
$& [p=silk q=silk] :: cons
|
||||
$% [%diff p=silk q=silk] :: diff
|
||||
[%done p=(set beam) q=gage] :: literal
|
||||
[%file p=beam] :: from clay
|
||||
[%mash p=mark q=milk r=milk] :: merge
|
||||
[%tabl p=(list (pair silk silk))] :: list
|
||||
== ::
|
||||
++ tage :: %tabl gage
|
||||
,[[%tabl p=(list (pair marc marc))] q=vase] ::
|
||||
++ move ,[p=bone q=(mold note gift)] ::
|
||||
++ note-clay :: filesystem command
|
||||
$% [%font p=@p q=@tas r=@p s=@tas] ::
|
||||
[%info p=@p q=@tas r=nori] ::
|
||||
[%lynx p=@p q=@tas r=(unit ,?)] ::
|
||||
[%merg p=@p q=@tas r=@p s=@tas t=germ] ::
|
||||
== ::
|
||||
++ note-dill :: system command
|
||||
$% [%flog p=dill-flog] ::
|
||||
== ::
|
||||
++ note-ford ::
|
||||
$% [%exec p=@p q=beak r=(unit silk)] ::
|
||||
== ::
|
||||
++ note-gall :: note to %gall
|
||||
$% [%mess p=[p=ship q=path] q=ship r=cage] ::
|
||||
[%show p=[p=ship q=path] q=ship r=path] ::
|
||||
[%took p=[p=ship q=path] q=ship] ::
|
||||
== ::
|
||||
++ note :: out request $->
|
||||
$% [%c note-clay] ::
|
||||
[%d note-dill] ::
|
||||
[%f note-ford] ::
|
||||
[%g note-gall] ::
|
||||
== ::
|
||||
++ sign-clay ::
|
||||
$% [%mere are=(each (set path) (pair term tang))]::
|
||||
== ::
|
||||
++ sign-ford ::
|
||||
$% [%made p=@uvH q=(each gage tang)] ::
|
||||
== ::
|
||||
++ sign-gall ::
|
||||
$% [%mean p=ares] ::
|
||||
[%nice ~] ::
|
||||
== ::
|
||||
++ sign ::
|
||||
$% [%c sign-clay] ::
|
||||
[%f sign-ford] ::
|
||||
[%g sign-gall] ::
|
||||
== ::
|
||||
-- ::
|
||||
:: ::
|
||||
:::: ::
|
||||
:: ::
|
||||
|_ $: hid=hide :: system state
|
||||
helm-house :: program state
|
||||
== ::
|
||||
++ he :: per session
|
||||
|_ [[ost=bone moz=(list move)] helm-session] ::
|
||||
++ he-abet :: resolve
|
||||
[(flop moz) %_(+> hoc (~(put by hoc) ost +<+))] ::
|
||||
:: ::
|
||||
++ he-give :: emit gift
|
||||
|= git=gift
|
||||
%_(+> moz [[ost %give git] moz])
|
||||
::
|
||||
++ he-wish-reset
|
||||
^+ .
|
||||
=- %_(+ moz (weld (flop zum) moz))
|
||||
^- zum=(list move)
|
||||
=+ top=`path`/(scot %p our.hid)/home/(scot %da lat.hid)/arvo
|
||||
:- [ost %pass /reset %d %flog %vega (weld top `path`/hoon)]
|
||||
%+ turn
|
||||
^- (list ,[p=@tas q=@tas])
|
||||
:~ [%$ %zuse]
|
||||
[%a %ames]
|
||||
[%c %clay]
|
||||
[%d %dill]
|
||||
[%e %eyre]
|
||||
[%f %ford]
|
||||
[%g %gall]
|
||||
[%t %time]
|
||||
==
|
||||
|= [p=@tas q=@tas]
|
||||
=+ pax=`path`(welp top /[q])
|
||||
=+ txt=((hard ,@) .^(%cx (welp pax /hoon)))
|
||||
[ost %pass /reset %d %flog %veer p pax txt]
|
||||
::
|
||||
++ he-wish-reload
|
||||
|= all=(list term)
|
||||
=- %_(+ moz (weld (flop zum) moz))
|
||||
^- zum=(list move)
|
||||
=+ top=`path`/(scot %p our.hid)/home/(scot %da lat.hid)/arvo
|
||||
%+ turn all
|
||||
=+ ark=(arch .^(%cy /(scot %p our.hid)/home/(scot %da lat.hid)/arvo))
|
||||
=+ van=(~(tap by r.ark))
|
||||
|= nam=@tas
|
||||
=. nam
|
||||
?. =(1 (met 3 nam))
|
||||
nam
|
||||
=+ ^- zaz=(list ,[p=span ~])
|
||||
(skim van |=([a=term ~] =(nam (end 3 1 a))))
|
||||
?> ?=([[@ ~] ~] zaz)
|
||||
`term`p.i.zaz
|
||||
=+ tip=(end 3 1 nam)
|
||||
=. tip ?:(=('z' tip) %$ tip)
|
||||
=+ pax=`path`(welp top /[nam])
|
||||
=+ txt=((hard ,@) .^(%cx (welp pax /hoon)))
|
||||
[ost %pass /reload %d %flog %veer tip pax txt]
|
||||
::
|
||||
++ he-wish-sync
|
||||
|= [syd=desk her=ship sud=desk ~]
|
||||
%_ .
|
||||
moz
|
||||
:_ moz
|
||||
[ost %pass /sync %c %font our.hid syd her sud]
|
||||
==
|
||||
::
|
||||
++ he-wish-unix
|
||||
|= [syd=desk syn=(unit ,?)]
|
||||
%_ .
|
||||
moz
|
||||
:_ moz
|
||||
[ost %pass /unix %c %lynx our.hid syd syn]
|
||||
==
|
||||
::
|
||||
++ he-wish-verb
|
||||
%_ .
|
||||
moz
|
||||
:_ moz
|
||||
[ost %pass /verb %d %flog %verb ~]
|
||||
==
|
||||
::
|
||||
++ he-wish-init
|
||||
|= him=ship
|
||||
%_ +>.$
|
||||
moz
|
||||
:_ moz
|
||||
[ost %pass /init %d %flog %crud %hax-init leaf/(scow %p him) ~]
|
||||
==
|
||||
::
|
||||
++ he-wish-merge
|
||||
|= syd=desk
|
||||
=+ ^- merge-state
|
||||
%+ fall (~(get by rem) syd)
|
||||
=+ *merge-state
|
||||
%_(- cas [%da lat.hid])
|
||||
|%
|
||||
++ merge-abet
|
||||
..he-wish-merge(rem (~(put by rem) syd auto gem her sud cas))
|
||||
::
|
||||
++ blab
|
||||
|= new=(list move)
|
||||
^+ +>
|
||||
+>.$(moz (welp new moz))
|
||||
::
|
||||
++ win (blab [ost %give %nice ~] ~)
|
||||
++ lose (blab [ost %give %mean ~] ~)
|
||||
::
|
||||
++ gage-to-tage
|
||||
|= res=gage
|
||||
^- tage
|
||||
?@ p.res
|
||||
~|(%bad-marc !!)
|
||||
res
|
||||
::
|
||||
++ tage-to-cages
|
||||
|= tab=tage
|
||||
^- (list (pair cage cage))
|
||||
?~ p.tab
|
||||
~
|
||||
:_ $(p.tab t.p.tab, q.tab (slot 3 q.tab))
|
||||
~| %strange-gage
|
||||
:- [?^(p.i.p.tab !! p.i.p.tab) (slot 4 q.tab)]
|
||||
[?^(q.i.p.tab !! q.i.p.tab) (slot 5 q.tab)]
|
||||
::
|
||||
++ merge
|
||||
^+ .
|
||||
(blab [ost %pass /merge/[syd]/merge %c %merg our.hid syd her sud gem] ~)
|
||||
::
|
||||
++ fancy-merge :: recurse
|
||||
|= [syd=desk her=@p sud=desk gem=?(%auto germ)]
|
||||
^+ +>
|
||||
%- blab :_ ~
|
||||
:* ost %pass /merge/[^syd]/fancy %g %mess [our.hid imp.hid]
|
||||
our.hid %helm-merge !>([syd her sud gem])
|
||||
==
|
||||
::
|
||||
++ spam
|
||||
|= mes=(list tank)
|
||||
%- blab :_ ~
|
||||
:* ost %pass /merge/[syd]/spam %g %mess
|
||||
[our.hid /talk] our.hid %talk-command -:!>(*command)
|
||||
%publish
|
||||
%- flop
|
||||
=< acc
|
||||
%+ roll mes
|
||||
=< .(eny eny.hid)
|
||||
|= [tan=tank acc=(list thought) eny=@uvI]
|
||||
^- [acc=(list thought) eny=@uvI]
|
||||
=+ (sham eny mes)
|
||||
:_ -
|
||||
:_ acc
|
||||
^- thought
|
||||
:+ -
|
||||
[[[%& our.hid (main our.hid)] [*envelope %pending]] ~ ~]
|
||||
[lat.hid *bouquet [%app (crip ~(ram re tan))]]
|
||||
==
|
||||
++ start
|
||||
|= [her=@p sud=@tas gim=?(%auto germ)]
|
||||
^+ +>
|
||||
=. cas [%da lat.hid]
|
||||
?. ?=(%auto gim)
|
||||
merge(auto |, gem gim, her her, sud sud)
|
||||
?: =(0 .^(%cw /(scot %p our.hid)/[syd]/(scot %da lat.hid)))
|
||||
=> $(gim %init)
|
||||
.(auto &)
|
||||
=> $(gim %fine)
|
||||
.(auto &)
|
||||
::
|
||||
++ work
|
||||
|= sih=sign
|
||||
^+ +>
|
||||
~| [%working auto=auto gem=gem syd=syd her=her sud=sud]
|
||||
?: ?=(%meld gem)
|
||||
?- -.sih
|
||||
%g
|
||||
?: ?=(%nice +<.sih)
|
||||
=> (spam leaf/"%melding %{(trip sud)} into scratch space" ~)
|
||||
%- blab :_ ~
|
||||
:* ost %pass /merge/[syd]/scratch %c %merg our.hid
|
||||
(cat 3 syd '-scratch') her sud gem
|
||||
==
|
||||
=+ :- "failed to set up conflict resolution scratch space"
|
||||
"I'm out of ideas"
|
||||
lose:(spam leaf/-< leaf/-> ~)
|
||||
::
|
||||
%c
|
||||
?: ?=(%& -.are.sih)
|
||||
?. auto
|
||||
=+ "successfully merged with strategy {<gem>}"
|
||||
win:(spam leaf/- ?~(p.are.sih ~ [>`(set path)`p.are.sih< ~]))
|
||||
=+ "mashing conflicts"
|
||||
=> .(+>.$ (spam leaf/- ~))
|
||||
=+ tic=(cat 3 syd '-scratch')
|
||||
%- blab :_ ~
|
||||
:* ost %pass /merge/[syd]/mash
|
||||
%f %exec our.hid [our.hid tic %da lat.hid] ~ %tabl
|
||||
^- (list (pair silk silk))
|
||||
%+ turn (~(tap in p.are.sih))
|
||||
|= pax=path
|
||||
^- (pair silk silk)
|
||||
:- [%done ~ %path -:!>(*path) pax]
|
||||
=+ base=[%file [our.hid tic %da lat.hid] (flop pax)]
|
||||
=+ alis=[%file [her sud cas] (flop pax)]
|
||||
=+ bobs=[%file [our.hid syd %da lat.hid] (flop pax)]
|
||||
=+ dali=[%diff base alis]
|
||||
=+ dbob=[%diff base bobs]
|
||||
=+ ^- for=mark
|
||||
=+ (slag (dec (lent pax)) pax)
|
||||
?~(- %$ i.-)
|
||||
[%mash for [her sud dali] [our.hid syd dbob]]
|
||||
==
|
||||
=+ "failed to merge with strategy {<p.p.are.sih>}"
|
||||
lose:(spam leaf/- q.p.are.sih)
|
||||
::
|
||||
%f
|
||||
?: ?=(%| -.q.sih)
|
||||
=+ "failed to mash"
|
||||
lose:(spam leaf/- p.q.sih)
|
||||
=+ ^- can=(list (pair path (unit miso)))
|
||||
%+ turn (tage-to-cages (gage-to-tage p.q.sih))
|
||||
|= [pax=cage dif=cage]
|
||||
^- (pair path (unit miso))
|
||||
?. ?=(%path p.pax)
|
||||
~| "strange path mark: {<p.pax>}"
|
||||
!!
|
||||
[((hard path) q.q.pax) ?:(?=(%null p.dif) ~ `[%dif dif])]
|
||||
=+ notated=(skid can |=([path a=(unit miso)] ?=(^ a)))
|
||||
=+ annotated=(turn `(list (pair path ,*))`-.notated head)
|
||||
=+ unnotated=(turn `(list (pair path ,*))`+.notated head)
|
||||
=+ (trip (cat 3 syd '-scratch'))
|
||||
=+ ^- tan=(list tank)
|
||||
%- zing
|
||||
^- (list (list tank))
|
||||
:~ :~ leaf/""
|
||||
leaf/"done setting up scratch space in %{-}"
|
||||
leaf/"please resolve the following conflicts and run"
|
||||
leaf/":helm+merge %{(trip syd)} {<our.hid>} %{-}"
|
||||
==
|
||||
?~ annotated
|
||||
~
|
||||
:~ leaf/""
|
||||
leaf/"annotated conflicts in:"
|
||||
>`(list path)`annotated<
|
||||
==
|
||||
?~ unnotated
|
||||
~
|
||||
:~ leaf/""
|
||||
leaf/"some conflicts could not be annotated."
|
||||
leaf/"for these, the scratch space contains"
|
||||
leaf/"the most recent common ancestor of the"
|
||||
leaf/"conflicting content."
|
||||
leaf/""
|
||||
leaf/"unannotated conflicts in:"
|
||||
>`(list path)`unnotated<
|
||||
==
|
||||
==
|
||||
=< win
|
||||
%- blab:(spam tan)
|
||||
:_ ~
|
||||
:* ost %pass /merge/[syd]/dash %c %info
|
||||
our.hid (cat 3 syd '-scratch')
|
||||
%& *cart
|
||||
%+ murn can
|
||||
|= [p=path q=(unit miso)]
|
||||
`(unit (pair path miso))`?~(q ~ `[p u.q])
|
||||
==
|
||||
==
|
||||
?> ?=(%c -.sih)
|
||||
?: ?=(%& -.are.sih)
|
||||
=+ "successfully merged with strategy {<gem>}"
|
||||
win:(spam leaf/- ?~(p.are.sih ~ [>`(set path)`p.are.sih< ~]))
|
||||
?. auto
|
||||
=+ "failed to merge with strategy {<p.p.are.sih>}"
|
||||
lose:(spam leaf/- q.p.are.sih)
|
||||
?+ gem
|
||||
(spam leaf/"strange auto" >gem< ~)
|
||||
::
|
||||
%init
|
||||
=+ :- "auto merge failed on strategy %init"
|
||||
"I'm out of ideas"
|
||||
lose:(spam leaf/-< leaf/-> [>p.p.are.sih< q.p.are.sih])
|
||||
::
|
||||
%fine
|
||||
?. ?=(%bad-fine-merge p.p.are.sih)
|
||||
=+ "auto merge failed on strategy %fine"
|
||||
lose:(spam leaf/- >p.p.are.sih< q.p.are.sih)
|
||||
=> (spam leaf/"%fine merge failed, trying %meet" ~)
|
||||
merge(gem %meet)
|
||||
::
|
||||
%meet
|
||||
?. ?=(%meet-conflict p.p.are.sih)
|
||||
=+ "auto merge failed on strategy %meet"
|
||||
lose:(spam leaf/- >p.p.are.sih< q.p.are.sih)
|
||||
=> (spam leaf/"%meet merge failed, trying %mate" ~)
|
||||
merge(gem %mate)
|
||||
::
|
||||
%mate
|
||||
?. ?=(%mate-conflict p.p.are.sih)
|
||||
=+ "auto merge failed on strategy %mate"
|
||||
lose:(spam leaf/- >p.p.are.sih< q.p.are.sih)
|
||||
=> .(gem %meld)
|
||||
=+ tic=(cat 3 syd '-scratch')
|
||||
=> =+ :- "%mate merge failed with conflicts,"
|
||||
"setting up scratch space at %{(trip tic)}"
|
||||
[tic=tic (spam leaf/-< leaf/-> ~)]
|
||||
(fancy-merge tic our.hid syd %auto)
|
||||
==
|
||||
--
|
||||
--
|
||||
::
|
||||
++ hake :: poke core
|
||||
|= [ost=bone her=ship]
|
||||
?> =(her our.hid)
|
||||
~(. he [ost [ost %give %nice ~]~] (fall (~(get by hoc) ost) *helm-session))
|
||||
::
|
||||
++ hoke :: poke sans ack
|
||||
|= [ost=bone her=ship]
|
||||
?> =(her our.hid)
|
||||
~(. he [ost ~] (fall (~(get by hoc) ost) *helm-session))
|
||||
::
|
||||
++ poke-helm-reset
|
||||
|= [ost=bone her=ship ~]
|
||||
~& %poke-helm-reset
|
||||
he-abet:he-wish-reset:(hake ost her)
|
||||
::
|
||||
++ poke-helm-verb
|
||||
|= [ost=bone her=ship ~]
|
||||
~& %poke-helm-verb
|
||||
he-abet:he-wish-verb:(hake ost her)
|
||||
::
|
||||
++ poke-helm-init
|
||||
|= [ost=bone her=ship him=ship]
|
||||
~& %poke-helm-init
|
||||
he-abet:(he-wish-init:(hake ost her) him)
|
||||
::
|
||||
++ poke-helm-reload
|
||||
|= [ost=bone her=ship all=(list term)]
|
||||
~& %poke-helm-reload
|
||||
he-abet:(he-wish-reload:(hake ost her) all)
|
||||
::
|
||||
++ poke-helm-merge
|
||||
|= [ost=bone her=ship syd=@tas ali=@p sud=@tas gem=?(%auto germ)]
|
||||
~& %poke-helm-merge
|
||||
he-abet:merge-abet:(start:(he-wish-merge:(hoke ost her) syd) ali sud gem)
|
||||
::
|
||||
++ poke-helm-sync
|
||||
|= [ost=bone her=ship all=[desk ship desk ~]]
|
||||
~& %poke-helm-sync
|
||||
he-abet:(he-wish-sync:(hake ost her) all)
|
||||
::
|
||||
++ poke-helm-unix
|
||||
|= [ost=bone her=ship all=[desk (unit ,?)]]
|
||||
~& %poke-helm-unix
|
||||
he-abet:(he-wish-unix:(hake ost her) all)
|
||||
::
|
||||
++ poke-helm-begin
|
||||
|= [ost=bone you=ship begs]
|
||||
~& %poke-helm-begin
|
||||
?> ?=(~ bur)
|
||||
=+ buz=(shax :(mix (jam ges) eny))
|
||||
=+ loy=(bruw 2.048 buz)
|
||||
:_ +>.$(bur `[his [0 sec:ex:loy]~])
|
||||
:~ :* ost %pass /ticketing %a %want [our.hid (sein his)] /q/ta
|
||||
his tic ges pub:ex:loy
|
||||
==
|
||||
[ost %give %nice ~]
|
||||
==
|
||||
::
|
||||
++ poke-will
|
||||
|= [ost=bone you=ship wil=(unit will)]
|
||||
?> ?=(^ bur)
|
||||
:_ +>.$(bur ~)
|
||||
?~ wil
|
||||
[ost %give %mean ~ %rejected ~]~
|
||||
:~ [ost %pass / %a %cash p.u.bur q.u.bur u.wil]
|
||||
[ost %pass / %c %plug our.hid %home (sein our.hid) %kids]
|
||||
[ost %give %nice ~]
|
||||
==
|
||||
::
|
||||
++ pour
|
||||
|= [ost=bone pax=path sih=*]
|
||||
^- [(list move) _+>]
|
||||
=+ sih=((soft sign) sih)
|
||||
?~ sih [~ +>.$]
|
||||
?+ pax [~ +>.$]
|
||||
[%merge @tas @ ~]
|
||||
?: ?=(%spam i.t.t.pax)
|
||||
[~ +>.$]
|
||||
he-abet:merge-abet:(work:(he-wish-merge:(hoke ost our.hid) i.t.pax) u.sih)
|
||||
==
|
||||
--
|
@ -5,7 +5,7 @@
|
||||
|_ [hid=hide ~]
|
||||
++ peer ,_`.
|
||||
++ poke-into-args
|
||||
|= [ost=bone you=ship pax=path dat=@ ~]
|
||||
|= [ost=bone you=ship pax=path dat=cage ~]
|
||||
:_ +>.$
|
||||
:* [ost %pass /into %c %info our.hid (foal pax dat)]
|
||||
[ost %pass / %g %cide %$]
|
@ -18,7 +18,7 @@
|
||||
"mousetrap/1.4.6/mousetrap.js"
|
||||
"react/0.11.0/react.js"
|
||||
==
|
||||
;script(src "/~/at/main/lib/urb.js");
|
||||
;script(src "/~/at/home/lib/urb.js");
|
||||
;script: urb.appl = 'sole'
|
||||
;style:'''
|
||||
#term {
|
@ -16,7 +16,7 @@
|
||||
%- turn
|
||||
:_ |= [tip=@tasD nam=@tas]
|
||||
=+ pax=[(scot %p our.hid) %arvo (scot %da lat.hid) nam %hoon ~]
|
||||
[%veer tip pax (,@ .^(%cx pax))]
|
||||
[%veer tip pax (,@ +:.^(%cx pax))]
|
||||
^- (list ,[p=@tas q=@tas])
|
||||
:~ [%$ %zuse]
|
||||
[%a %ames]
|
@ -14,7 +14,7 @@
|
||||
%+ args-into-resp .
|
||||
|= all=(list ,@tas)
|
||||
%+ turn all
|
||||
=+ ark=(arch .^(%cy /(scot %p our.hid)/arvo/(scot %da lat.hid)))
|
||||
=+ ark=(arch .^(%cy /(scot %p our.hid)/main/(scot %da lat.hid)/arvo))
|
||||
=+ van=(~(tap by r.ark))
|
||||
|= nam=@tas
|
||||
=. nam
|
||||
@ -25,6 +25,6 @@
|
||||
?> ?=([[@ ~] ~] zaz)
|
||||
`term`p.i.zaz
|
||||
=+ tip=(end 3 1 nam)
|
||||
=+ pax=[(scot %p our.hid) %arvo (scot %da lat.hid) nam ~]
|
||||
=+ pax=[(scot %p our.hid) %main (scot %da lat.hid) %arvo nam ~]
|
||||
[%veer ?:(=('z' tip) %$ tip) pax (,@ .^(%cx (welp pax /hoon)))]
|
||||
--
|
@ -7,14 +7,14 @@
|
||||
/= pit /~ !>(+) :: kernel vase
|
||||
::
|
||||
:::: structures
|
||||
::
|
||||
!:
|
||||
|% ::
|
||||
++ axle ::
|
||||
$: %1 :: version
|
||||
tiv=? :: typing?
|
||||
wit=[p=@u q=(map ,@u coma)] :: waiting commands
|
||||
pid=@u :: next process id
|
||||
pax=_`path`/=try= :: working directory
|
||||
pax=_`path`/=base=/try :: working directory
|
||||
act=(unit span) :: active child
|
||||
pip=(jar span span) :: pipe out->in
|
||||
pop=(jar span span) :: pipe in->out
|
||||
@ -85,7 +85,7 @@
|
||||
--
|
||||
::
|
||||
:::: parsers
|
||||
::
|
||||
!:
|
||||
|%
|
||||
++ maybe |*(fel=_rule (cook |*(a=(unit) (fall a ~)) (opts fel)))
|
||||
++ opts :: parse unit
|
||||
@ -145,7 +145,7 @@
|
||||
--
|
||||
::
|
||||
:::: per event
|
||||
::
|
||||
!:
|
||||
|%
|
||||
++ ve
|
||||
|= [hid=hide ost=bone axle]
|
||||
@ -233,7 +233,8 @@
|
||||
?^ (file paf) (chew-file paf '! exists')
|
||||
%+ with (fall gen [%bczp atom/%t])
|
||||
|= new=vase
|
||||
(chew-file paf (foal paf q.new))
|
||||
=+ for=((hard mark) -:(flop paf))
|
||||
(chew-file paf (foal paf for new))
|
||||
::
|
||||
++ eat-mut
|
||||
|= [paf=path gen=(unit twig)]
|
||||
@ -243,7 +244,8 @@
|
||||
?~ gen
|
||||
(blab (stray (crip ": {(spud paf)} {<(,@t u.fel)>}")))
|
||||
%+ with u.gen |= new=vase
|
||||
(chew-file paf (foal paf q.new))
|
||||
=+ for=((hard mark) -:(flop paf))
|
||||
(chew-file paf (foal paf for new))
|
||||
=+ ark=;;(arch .^(%cy paf))
|
||||
?- r.ark
|
||||
~ (chew-file paf '! none')
|
||||
@ -510,7 +512,7 @@
|
||||
--
|
||||
::
|
||||
:::: formal interface
|
||||
::
|
||||
!:
|
||||
|_ [hid=hide vat=axle]
|
||||
::
|
||||
++ peer :: handle subscription
|
@ -556,6 +556,7 @@
|
||||
^+ +>
|
||||
?^ ris
|
||||
(ta-ser txt)
|
||||
:: ~& ven.say.inp
|
||||
%- ta-hom(pos.inp (add (lent txt) pos.inp))
|
||||
:- %mor
|
||||
|- ^- (list sole-edit)
|
||||
@ -573,18 +574,10 @@
|
||||
=- [(add pos.inp (lent p.vew)) (weld (tuba p.vew) q.vew)]
|
||||
^= vew ^- (pair tape (list ,@c))
|
||||
?: vis.pom [cad.pom buf.say.inp]
|
||||
:- ;: welp
|
||||
cad.pom
|
||||
?~ buf.say.inp ~
|
||||
;: welp
|
||||
"<"
|
||||
(scow %p (end 4 1 (sham buf.say.inp)))
|
||||
"> "
|
||||
==
|
||||
==
|
||||
=+ len=(lent buf.say.inp)
|
||||
|- ^- (list ,@c)
|
||||
?:(=(0 len) ~ [`@c`'*' $(len (dec len))])
|
||||
:- %+ welp cad.pom
|
||||
?~ buf.say.inp ~
|
||||
"<{(scow %p (end 4 1 (sham buf.say.inp)))}> "
|
||||
(turn buf.say.inp ,_`@c`'*')
|
||||
--
|
||||
--
|
||||
++ peer
|
41
base/app/solid/core.hook
Normal file
41
base/app/solid/core.hook
Normal file
@ -0,0 +1,41 @@
|
||||
!:
|
||||
::::
|
||||
::
|
||||
|_ [hid=hide ~]
|
||||
++ peer ,_`.
|
||||
++ poke-solid-args
|
||||
|= [ost=bone you=ship ~]
|
||||
:_ +>.$
|
||||
=+ top=`path`/(scot %p our.hid)/main/(scot %da lat.hid)/arvo
|
||||
=+ pax=`path`(weld top `path`[%hoon ~])
|
||||
~& %solid-start
|
||||
=+ gen=(reck pax)
|
||||
~& %solid-parsed
|
||||
=+ ken=q:(~(mint ut %noun) %noun gen)
|
||||
~& %solid-compiled
|
||||
=+ ^= all
|
||||
=+ all=.*(0 ken)
|
||||
=+ ^= vay ^- (list ,[p=@tas q=@tas])
|
||||
:~ [%$ %zuse]
|
||||
[%g %gall]
|
||||
[%f %ford]
|
||||
[%a %ames]
|
||||
[%c %clay]
|
||||
[%d %dill]
|
||||
[%e %eyre]
|
||||
[%t %time]
|
||||
==
|
||||
|- ^+ all
|
||||
?~ vay all
|
||||
=+ pax=(weld top `path`[q.i.vay ~])
|
||||
=+ txt=((hard ,@) .^(%cx (weld pax `path`[%hoon ~])))
|
||||
=+ sam=[lat.hid `ovum`[[%gold ~] [%veer p.i.vay pax txt]]]
|
||||
~& [%solid-veer i.vay]
|
||||
=+ gat=.*(all .*(all [0 42]))
|
||||
=+ nex=+:.*([-.gat [sam +>.gat]] -.gat)
|
||||
$(vay t.vay, all nex)
|
||||
:~ [ost %give %sage [%urbit %pill ~] [ken all]]
|
||||
[ost %pass / %g %cide %$]
|
||||
[ost %give %nice ~]
|
||||
==
|
||||
--
|
@ -105,7 +105,7 @@
|
||||
:: ::
|
||||
++ work :: interface action
|
||||
$% [%number p=? q=@ud] :: activate by number
|
||||
[%join p=(set partner)] ::
|
||||
[%join p=(set partner)] ::
|
||||
[%say p=speech] ::
|
||||
[%invite p=span q=(list partner)] ::
|
||||
[%banish p=span q=(list partner)] ::
|
||||
@ -1737,7 +1737,13 @@
|
||||
|= oug=?
|
||||
^- tape
|
||||
?+ -.sep ""
|
||||
%url (weld ": " (scag 62 (earn p.sep)))
|
||||
%url
|
||||
=+ txt=(earn p.sep)
|
||||
%+ weld "/ "
|
||||
?: (gte 62 (lent txt))
|
||||
txt
|
||||
(weld (scag 61 (earn p.sep)) "…")
|
||||
::
|
||||
%lin
|
||||
=+ txt=(trip q.sep)
|
||||
?: p.sep
|
||||
@ -1745,6 +1751,9 @@
|
||||
?: oug
|
||||
(weld "@ " txt)
|
||||
(weld " " txt)
|
||||
::
|
||||
%app
|
||||
[' ' (trip p.sep)]
|
||||
==
|
||||
--
|
||||
::
|
||||
@ -1814,17 +1823,21 @@
|
||||
|= [ost=bone you=ship ~]
|
||||
^- [(list move) _+>]
|
||||
:_ +>.$
|
||||
=+ paf=/(scot %p our.hid)/try/(scot %da lat.hid)/talk/backlog/jam
|
||||
[ost %pass /jamfile %c %info our.hid (foal paf (jam +<+.+>.$))]~
|
||||
=+ paf=/(scot %p our.hid)/home/(scot %da lat.hid)/talk/backlog/mime
|
||||
:_ ~
|
||||
:* ost %pass /jamfile %c %info our.hid
|
||||
(foal paf %mime !>([/mime/jam (taco (jam +<+.+>.$))]))
|
||||
==
|
||||
::
|
||||
++ prep
|
||||
|= old=(unit (unit house-any))
|
||||
^- [(list move) _+>]
|
||||
~& %talk-prep
|
||||
?> ?=(^ old)
|
||||
=| moz=(list move)
|
||||
|-
|
||||
?~ u.old
|
||||
=+ paf=/(scot %p our.hid)/try/(scot %da lat.hid)/talk/backlog/jam
|
||||
=+ paf=/(scot %p our.hid)/home/(scot %da lat.hid)/talk/backlog/mime
|
||||
?. ?=([%0 %0 %0] [.^(%cy paf)])
|
||||
~& %talk-prep-restore
|
||||
$(u.old (some ((hard house-any) (cue ((hard ,@) .^(%cx paf))))))
|
@ -4,7 +4,7 @@
|
||||
::
|
||||
/? 314 :: need urbit 314
|
||||
/- term-line, term-in, term-ctrl, kyev
|
||||
/= stat /:/%%/:/hymn/
|
||||
::/= stat /:/%%/:/hymn/
|
||||
::
|
||||
:::: structures
|
||||
::
|
||||
@ -57,6 +57,36 @@
|
||||
[%vega p=path] ::
|
||||
== == ==
|
||||
--
|
||||
::
|
||||
:::: from future import wick, pack, pick XX remove on breach or kelvin bump
|
||||
::
|
||||
|%
|
||||
++ wick :: span format
|
||||
|= a=@
|
||||
^- (unit ,@ta)
|
||||
=+ b=(rip 3 a)
|
||||
=- ?^(b ~ (some (rap 3 (flop c))))
|
||||
=| c=tape
|
||||
|- ^- [b=tape c=tape]
|
||||
?~ b [~ c]
|
||||
?. =('~' i.b)
|
||||
$(b t.b, c [i.b c])
|
||||
?~ t.b [b ~]
|
||||
?- i.t.b
|
||||
%'~' $(b t.t.b, c ['~' c])
|
||||
%'-' $(b t.t.b, c ['_' c])
|
||||
@ [b ~]
|
||||
==
|
||||
::
|
||||
++ pack :: light path encoding
|
||||
|= [a=term b=path] ^- span
|
||||
%+ rap 3 :- (wack a)
|
||||
(turn b |=(c=span (cat 3 '_' (wack c))))
|
||||
::
|
||||
++ pick :: light path decoding
|
||||
|= a=span ^- (unit ,[p=term q=path])
|
||||
(rush a (most cab (sear wick urt:ab)))
|
||||
--
|
||||
!:
|
||||
:::: helpers
|
||||
::
|
||||
@ -98,18 +128,18 @@
|
||||
[(flop mow) (~(put by hiz) pax tel)]
|
||||
::
|
||||
++ page
|
||||
:: ;html
|
||||
:: ;head
|
||||
:: ;title: Not yet
|
||||
:: ==
|
||||
:: ;body;
|
||||
:: ==
|
||||
%. stat
|
||||
%+ inject
|
||||
~[%html %head]
|
||||
;= ;script: urb.appl = "{(trip app.hid)}"
|
||||
;script: urb.term = \{pax: "{(spud pax)}"}
|
||||
;html
|
||||
;head
|
||||
;title: Not yet
|
||||
==
|
||||
;body;
|
||||
==
|
||||
:: %. stat
|
||||
:: %+ inject
|
||||
:: ~[%html %head]
|
||||
:: ;= ;script: urb.appl = "{(trip app.hid)}"
|
||||
:: ;script: urb.term = \{pax: "{(spud pax)}"}
|
||||
:: ==
|
||||
::
|
||||
++ peer
|
||||
|= gal=glas
|
||||
@ -255,7 +285,7 @@
|
||||
++ pour
|
||||
|= [ost=bone pax=path sih=*]
|
||||
^- [(list move) _+>]
|
||||
=+ sih=((hard sign) sih)
|
||||
=+ sih=~|([%term-pour (,[term term ~] sih)] ((hard sign) sih))
|
||||
?: ?=(?(%sage %init %logo %verb %veer %vega) &2.sih) :: vomit
|
||||
[[ost %give +.sih]~ +>.$]
|
||||
?~ pax !!
|
@ -13,7 +13,7 @@
|
||||
;head
|
||||
;title: Hi
|
||||
;script: window.urb = window.urb || \{};
|
||||
;script@"/~/at/main/lib/urb.js";
|
||||
;script@"/~/at/base/lib/urb.js";
|
||||
;script@"//cdnjs.cloudflare.com/ajax/libs/jquery/2.1.1/jquery.min.js";
|
||||
;script@"//cdnjs.cloudflare.com/ajax/libs/mousetrap/1.4.6/mousetrap.js";
|
||||
;script@"//use.typekit.net/fkv0sjk.js";
|
@ -440,7 +440,7 @@
|
||||
vix=(bex +((cut 0 [25 2] mag))) :: width of sender
|
||||
tay=(cut 0 [27 5] mag) :: message type
|
||||
==
|
||||
?> =(2 vez)
|
||||
?> =(3 vez)
|
||||
?> =(chk (end 0 20 (mug bod)))
|
||||
:+ [(end 3 wix bod) (cut 3 [wix vix] bod)]
|
||||
(kins tay)
|
||||
@ -460,7 +460,7 @@
|
||||
=+ tay=(ksin q.kec)
|
||||
%+ mix
|
||||
%+ can 0
|
||||
:~ [3 2]
|
||||
:~ [3 3]
|
||||
[20 (mug bod)]
|
||||
[2 yax]
|
||||
[2 qax]
|
||||
@ -1043,7 +1043,7 @@
|
||||
++ gnaw :: gnaw:am
|
||||
|= [kay=cape ryn=lane pac=rock] :: process packet
|
||||
^- [p=(list boon) q=fort]
|
||||
?. =(2 (end 0 3 pac)) [~ fox]
|
||||
?. =(3 (end 0 3 pac)) [~ fox]
|
||||
=+ kec=(bite pac)
|
||||
?: (goop p.p.kec) [~ fox]
|
||||
?. (~(has by urb.ton.fox) q.p.kec)
|
||||
@ -1625,7 +1625,7 @@
|
||||
::
|
||||
++ scry
|
||||
|= [fur=(unit (set monk)) ren=@tas who=ship syd=desk lot=coin tyl=path]
|
||||
^- (unit (unit (pair mark ,*)))
|
||||
^- (unit (unit cage))
|
||||
?~ tyl [~ ~]
|
||||
=+ hun=(slaw %p i.tyl)
|
||||
?~ hun [~ ~]
|
||||
@ -1637,13 +1637,13 @@
|
||||
[%$ %ud @]
|
||||
%+ bind
|
||||
(perm who u.hun q.p.lot [syd t.tyl])
|
||||
|=(a=* [%noun a])
|
||||
|=(a=* [%noun !>(a)])
|
||||
::
|
||||
[%$ %da @]
|
||||
?. =(now q.p.lot) ~
|
||||
%+ bind
|
||||
(temp who u.hun [syd t.tyl])
|
||||
|=(a=* [%noun a])
|
||||
|=(a=* [%noun !>(a)])
|
||||
==
|
||||
::
|
||||
++ stay fox
|
2856
base/arvo/clay.hoon
Normal file
2856
base/arvo/clay.hoon
Normal file
File diff suppressed because it is too large
Load Diff
@ -137,8 +137,9 @@
|
||||
$% [%make p=(unit ,@t) q=@ud r=@ s=?] ::
|
||||
[%sith p=@p q=@uw r=?] ::
|
||||
== ::
|
||||
++ note-clay :: wait for clay, hack
|
||||
$% [%warp p=sock q=riff] ::
|
||||
++ note-clay ::
|
||||
$% [%font p=@p q=@tas r=@p s=@tas] ::
|
||||
[%warp p=sock q=riff] :: wait for clay, hack
|
||||
== ::
|
||||
++ note-dill :: note to self, odd
|
||||
$% [%crud p=@tas q=(list tank)] ::
|
||||
@ -166,7 +167,8 @@
|
||||
[%init p=ship] ::
|
||||
== ::
|
||||
++ sign-clay ::
|
||||
$% [%note p=@tD q=tank] ::
|
||||
$% [%mere p=(each (set path) (pair term tang))] ::
|
||||
[%note p=@tD q=tank] ::
|
||||
[%writ p=riot] ::
|
||||
== ::
|
||||
++ sign-dill ::
|
||||
@ -262,7 +264,8 @@
|
||||
~& [%dill-init our]
|
||||
=+ myt=(flop (need tem))
|
||||
=. tem ~
|
||||
=. moz :_(moz [hen %pass ~ %g %show [our [ram ~]] our ~])
|
||||
=. moz :_(moz [hen %pass / %c %font our %home our %base])
|
||||
=. moz :_(moz [hen %pass / %g %show [our [ram ~]] our ~])
|
||||
|- ^+ +>
|
||||
?~ myt +>
|
||||
$(myt t.myt, +> (send i.myt))
|
||||
@ -274,10 +277,10 @@
|
||||
moz
|
||||
:_ moz
|
||||
:* hen
|
||||
%pass
|
||||
/
|
||||
%c
|
||||
[%warp [our our] %main `[%& %y [%ud 1] /]]
|
||||
%pass
|
||||
/
|
||||
%c
|
||||
[%warp [our our] %base `[%sing %y [%ud 1] /]]
|
||||
==
|
||||
==
|
||||
::
|
||||
@ -307,6 +310,16 @@
|
||||
::
|
||||
[%a %init *]
|
||||
+>(moz :_(moz [hen %give +.sih]))
|
||||
::
|
||||
[%c %mere *]
|
||||
?: ?=(%& -.p.sih)
|
||||
+>.$
|
||||
~| %dill-mere-fail
|
||||
~| p.p.p.sih
|
||||
|-
|
||||
?~ q.p.p.sih !!
|
||||
~> %mean.|.(i.q.p.p.sih) :: interpolate ford fail into stack trace
|
||||
$(q.p.p.sih t.q.p.p.sih)
|
||||
::
|
||||
[%c %note *]
|
||||
(from %out (tuba ~(ram re q.+.sih)))
|
||||
@ -419,7 +432,7 @@
|
||||
::
|
||||
++ scry
|
||||
|= [fur=(unit (set monk)) ren=@tas his=ship syd=desk lot=coin tyl=path]
|
||||
^- (unit (unit (pair mark ,*)))
|
||||
^- (unit (unit cage))
|
||||
[~ ~]
|
||||
::
|
||||
++ stay all
|
@ -41,7 +41,7 @@
|
||||
$% [%this p=? q=clip r=httq] :: proxied request
|
||||
== == ::
|
||||
$: %f :: to %ford
|
||||
$% [%exec p=@p q=(unit silk)] ::
|
||||
$% [%exec p=@p q=beak r=(unit silk)] ::
|
||||
[%wasp p=@p q=@uvH] ::
|
||||
== == ::
|
||||
$: %g :: to %gall
|
||||
@ -74,7 +74,7 @@
|
||||
$% [%thou p=httr] :: response for proxy
|
||||
== == ::
|
||||
$: %f :: by %ford
|
||||
$% [%made p=@uvH q=(each cage tang)] ::
|
||||
$% [%made p=@uvH q=(each gage tang)] ::
|
||||
[%news ~] ::
|
||||
== == ::
|
||||
$: %g :: by %gall
|
||||
@ -102,10 +102,11 @@
|
||||
-- ::
|
||||
|% :: models
|
||||
++ bolo :: eyre state
|
||||
$: %0 :: version
|
||||
$: %1 :: version
|
||||
gub=@t :: random identity
|
||||
hov=(unit ship) :: master for remote
|
||||
ged=duct :: client interface
|
||||
ded=(set duct) :: killed requests
|
||||
pox=(map ,@uvH duct) :: proxied sessions
|
||||
ask=[p=@ud q=(map ,@ud ,[p=duct q=hiss])] :: outgoing by number
|
||||
kes=(map duct ,@ud) :: outgoing by duct
|
||||
@ -251,7 +252,7 @@
|
||||
;html
|
||||
;head
|
||||
;meta(charset "utf-8");
|
||||
;link(rel "stylesheet", href "/main/lib/base.css");
|
||||
;link(rel "stylesheet", href "/home/lib/base.css");
|
||||
;title: server error
|
||||
==
|
||||
;body:div#c.err:pre:code:"{(wush 80 tan)}"
|
||||
@ -333,7 +334,7 @@
|
||||
;pre:code#err;
|
||||
;script@"/~/at/~/auth.js";
|
||||
==
|
||||
;link(rel "stylesheet", href "/main/lib/base.css");
|
||||
;link(rel "stylesheet", href "/home/lib/base.css");
|
||||
==
|
||||
::
|
||||
++ logout-page
|
||||
@ -344,7 +345,7 @@
|
||||
;pre:code#err;
|
||||
;script@"/~/at/~/auth.js";
|
||||
==
|
||||
;link(rel "stylesheet", href "/main/lib/base.css");
|
||||
;link(rel "stylesheet", href "/home/lib/base.css");
|
||||
==
|
||||
::
|
||||
++ poke-test
|
||||
@ -443,7 +444,7 @@
|
||||
::
|
||||
%thud :: cancel request
|
||||
:: ford-kill :: XX discriminate
|
||||
+>.$
|
||||
+>.$(ded (~(put in ded) hen))
|
||||
::
|
||||
%wart :: remote request
|
||||
=+ mez=((soft gram) r.kyz)
|
||||
@ -520,6 +521,7 @@
|
||||
==
|
||||
::
|
||||
%made
|
||||
?> ?=(?([%| *] [%& @ *]) q.sih)
|
||||
=. our (need hov) :: XX
|
||||
|- ^+ ..axon
|
||||
?- tee
|
||||
@ -566,6 +568,7 @@
|
||||
==
|
||||
==
|
||||
::
|
||||
++ root-beak `beak`[our %home da/now] :: XX
|
||||
++ emule
|
||||
|= a=_|?(..emule) ^+ ..emule
|
||||
=+ mul=(mule a)
|
||||
@ -596,10 +599,10 @@
|
||||
::
|
||||
++ back :: %ford bounce
|
||||
|= [tea=whir dep=@uvH mar=mark cay=cage]
|
||||
(pass-note tea (ford-req [%cast mar %done ~ cay])) :: XX deps
|
||||
(pass-note tea (ford-req root-beak [%cast mar %done ~ cay])) :: XX deps
|
||||
::
|
||||
++ ford-kill (pass-note ~ %f [%exec our ~]) :: XX unused
|
||||
++ ford-req |=(kas=silk [%f [%exec our `kas]])
|
||||
++ ford-kill (pass-note ~ %f [%exec our *beak ~]) :: XX unused
|
||||
++ ford-req |=([bek=beak kas=silk] [%f [%exec our bek `kas]])
|
||||
::
|
||||
++ fail
|
||||
|= [sas=@ud dep=@uvH mez=tang]
|
||||
@ -621,6 +624,8 @@
|
||||
::
|
||||
++ give-thou :: done request
|
||||
|= hit=httr
|
||||
?: (~(has in ded) hen) :: request closed
|
||||
+>(ded (~(del in ded) hen))
|
||||
+>(mow :_(mow [hen %give %thou hit]))
|
||||
::
|
||||
++ mean-json |=([sas=@uG err=ares] (give-json sas ~ (ares-to-json err)))
|
||||
@ -665,7 +670,7 @@
|
||||
=: s.bem [%web ~(rent co (fcgi quy fcgi-cred:for-client)) s.bem]
|
||||
r.bem ?+(r.bem r.bem [%ud %0] da/now)
|
||||
==
|
||||
(ford-req [%boil ext bem ~])
|
||||
(ford-req -.bem [%boil ext bem ~])
|
||||
::
|
||||
::
|
||||
++ apex
|
||||
@ -714,7 +719,6 @@
|
||||
%.(q.u.bod ;~(biff poja a))
|
||||
::
|
||||
++ need-body |*(a=fist:jo (need (grab-body a)))
|
||||
++ root-beak `beak`[our %main ud/0] :: XX
|
||||
++ to-oryx (ot oryx/so ~):jo
|
||||
::
|
||||
::
|
||||
@ -894,7 +898,7 @@
|
||||
?: ?=(%json q.hem)
|
||||
[%| ((teba new-mess:for-view) p.hem r.hem cay)]
|
||||
:^ %& %| [%to need-ixor (scot %p p.p.hem) q.p.hem r.hem]
|
||||
(ford-req [%cast q.hem %done ~ cay])
|
||||
(ford-req root-beak [%cast q.hem %done ~ cay])
|
||||
::
|
||||
%poll
|
||||
?. ?=([~ %js] p.pok) :: XX treat non-json cases?
|
||||
@ -1139,8 +1143,9 @@
|
||||
=. eve (add-even ven)
|
||||
=< abet
|
||||
?~ ude done
|
||||
:: ~& got-even/ude
|
||||
(give-even(hen p.u.ude, ude ~) q.u.ude num ven)
|
||||
=. hen p.u.ude
|
||||
=. ..ix (pass-note of//[ire] [%t %rest era])
|
||||
(give-even(ude ~) q.u.ude num ven)
|
||||
::
|
||||
++ give-even
|
||||
|= [pol=? num=@u ven=even] ^+ done
|
||||
@ -1164,7 +1169,7 @@
|
||||
++ poll
|
||||
|= a=@u ^+ ..ix
|
||||
?: =(a p.eve)
|
||||
?^ ude ~&(e/ix/wait/%replaced abet(u.ude [hen &]))
|
||||
?^ ude ~&(e/ix/wait/replaced=p.u.ude abet(u.ude [hen &]))
|
||||
=. era (add ~s30 now)
|
||||
(pass-note:abet(ude [~ hen &]) of//[ire] [%t %wait era])
|
||||
?: (gth a p.eve) ~|(seq-high/cur=p.eve !!)
|
||||
@ -1218,10 +1223,15 @@
|
||||
^- (unit ,@da)
|
||||
~
|
||||
::
|
||||
++ load :: clam previous state
|
||||
|= old=bolo ::_[.(wix **)]:*bolo
|
||||
++ load :: take previous state
|
||||
=+ bol0=*bolo
|
||||
=> .(-.bol0 %0, |4.bol0 |5.bol0) :: missing ded
|
||||
|= old=?(bolo _bol0)
|
||||
^+ ..^$
|
||||
..^$(+>- old) ::(wix ~))
|
||||
?- -.old
|
||||
%1 ..^$(+>- old)
|
||||
%0 $(-.old %1, |4.old [*(set duct) |4.old])
|
||||
==
|
||||
::
|
||||
++ scry
|
||||
|= [our=(unit (set monk)) ren=@tas who=ship syd=desk lot=coin tyl=path]
|
@ -1,5 +1,5 @@
|
||||
!:::::
|
||||
:: :: %ford, new execution control
|
||||
:: :: %ford, new execution control
|
||||
!? 164
|
||||
::::
|
||||
|= pit=vase
|
||||
@ -7,10 +7,10 @@
|
||||
:: structures
|
||||
|%
|
||||
::
|
||||
++ bead ,[p=(set beam) q=cage] :: computed result
|
||||
++ bead ,[p=(set beam) q=gage] :: computed result
|
||||
++ gift :: out result <-$
|
||||
$% [%made p=@uvH q=(each cage tang)] :: computed result
|
||||
[%news ~] :: fresh depends
|
||||
$% [%made p=@uvH q=(each gage tang)] :: computed result
|
||||
[%news ~] :: fresh depends
|
||||
== ::
|
||||
++ heel path :: functional ending
|
||||
++ hock :: standard label
|
||||
@ -49,18 +49,15 @@
|
||||
[%toy p=mark] :: /mark/ static
|
||||
== ::
|
||||
++ kiss :: in request ->$
|
||||
$% [%exec p=@p q=(unit silk)] :: make / kill
|
||||
$% [%exec p=@p q=beak r=(unit silk)] :: make / kill
|
||||
[%wasp p=@p q=@uvH] :: depends query
|
||||
== ::
|
||||
++ milk (trel ship desk silk) :: sourced silk
|
||||
++ move ,[p=duct q=(mold note gift)] :: local move
|
||||
++ note :: out request $->
|
||||
$% $: %c :: to %clay
|
||||
$% [%warp p=sock q=riff] ::
|
||||
== == == ::
|
||||
++ rave :: see %clay
|
||||
$% [& p=mood] :: single request
|
||||
[| p=moat] :: change range
|
||||
== ::
|
||||
++ riff ,[p=desk q=(unit rave)] :: see %clay
|
||||
++ sign :: in result $<-
|
||||
$% $: %c :: by %clay
|
||||
@ -70,16 +67,24 @@
|
||||
$& [p=silk q=silk] :: cons
|
||||
$% [%bake p=mark q=beam r=path] :: local synthesis
|
||||
[%boil p=mark q=beam r=path] :: general synthesis
|
||||
[%bunt p=mark] :: example of mark
|
||||
[%call p=silk q=silk] :: slam
|
||||
[%cast p=mark q=silk] :: translate
|
||||
[%done p=(set beam) q=cage] :: literal
|
||||
[%diff p=silk q=silk] :: diff
|
||||
[%done p=(set beam) q=gage] :: literal
|
||||
[%dude p=tank q=silk] :: error wrap
|
||||
[%dune p=(set beam) q=(unit cage)] :: unit literal
|
||||
[%dune p=(set beam) q=(unit gage)] :: unit literal
|
||||
[%file p=beam] :: from clay
|
||||
[%join p=mark q=silk r=silk] :: merge
|
||||
[%mash p=mark q=milk r=milk] :: annotate
|
||||
[%mute p=silk q=(list (pair wing silk))] :: mutant
|
||||
[%pact p=silk q=silk] :: patch
|
||||
[%plan p=beam q=spur r=hood] :: structured assembly
|
||||
[%reef ~] :: kernel reef
|
||||
[%ride p=twig q=silk] :: silk thru twig
|
||||
[%tabl p=(list (pair silk silk))] :: list
|
||||
[%vale p=mark q=ship r=*] :: validate [our his]
|
||||
[%volt p=(set beam) q=(cask ,*)] :: unsafe add type
|
||||
== ::
|
||||
-- ::
|
||||
|% :: structures
|
||||
@ -90,7 +95,7 @@
|
||||
++ baby :: state by ship
|
||||
$: tad=[p=@ud q=(map ,@ud task)] :: tasks by number
|
||||
dym=(map duct ,@ud) :: duct to task number
|
||||
deh=deps :: depends by hash
|
||||
deh=(map ,@uvH deps) :: depends by hash
|
||||
jav=(map ,* calx) :: cache
|
||||
== ::
|
||||
++ bolt :: gonadic edge
|
||||
@ -110,7 +115,6 @@
|
||||
++ cafe :: live cache
|
||||
$: p=(set calx) :: used
|
||||
q=(map ,* calx) :: cache
|
||||
r=deps :: dependencies
|
||||
== ::
|
||||
:: ::
|
||||
++ calm :: cache metadata
|
||||
@ -118,17 +122,22 @@
|
||||
dep=(set beam) :: dependencies
|
||||
== ::
|
||||
++ calx :: concrete cache line
|
||||
$% [%hood p=calm q=(pair beam cage) r=hood] :: compile
|
||||
$% [%hood p=calm q=(pair beam gage) r=hood] :: compile
|
||||
[%bake p=calm q=(trel mark beam heel) r=(unit vase)]:: load
|
||||
[%slit p=calm q=[p=type q=type] r=type] :: slam type
|
||||
[%slim p=calm q=[p=type q=twig] r=(pair type nock)]:: mint
|
||||
[%slap p=calm q=[p=vase q=twig] r=vase] :: compute
|
||||
[%slam p=calm q=[p=vase q=vase] r=vase] :: compute
|
||||
== ::
|
||||
++ deps (map ,@uvH (set beam)) :: hashed depends
|
||||
++ deps :: depend state
|
||||
$% [%init p=(set beam)] :: given out
|
||||
[%sent p=(set duct) q=(set beam)] :: listener exists
|
||||
[%done ~] :: change seen
|
||||
== ::
|
||||
++ task :: problem in progress
|
||||
$: nah=duct :: cause
|
||||
kas=silk :: problem
|
||||
keg=(map (pair term beam) cage) :: block results
|
||||
kig=[p=@ud q=(map ,@ud ,[p=care q=beam])] :: blocks
|
||||
== ::
|
||||
-- ::
|
||||
@ -161,17 +170,16 @@
|
||||
++ chub :: cache merge
|
||||
|= [a=cafe b=cafe] ::
|
||||
^- cafe ::
|
||||
[(grom p.a p.b) (grum q.a q.b) (grum r.a r.b)] ::
|
||||
[(grom p.a p.b) (grum q.a q.b)] ::
|
||||
:: ::
|
||||
++ faun |=([a=cafe b=vase] (fine a `cage`noun/b)) :: vase to cage
|
||||
++ feel |=([a=cafe b=cage] (fine a q.b)) :: cage to vase
|
||||
++ faun |=([a=cafe b=vase] (fine a `gage`[%noun b])) :: vase to cage
|
||||
++ feel |=([a=cafe b=gage] (fine a q.b)) :: cage to vase
|
||||
++ fest :: bolt to success
|
||||
|= a=beam ::
|
||||
|*([b=cafe c=*] (flag a (fine b [~ u=c]))) ::
|
||||
:: ::
|
||||
++ fine |* [a=cafe b=*] :: bolt from data
|
||||
[p=`cafe`a q=[%0 p=*(set beam) q=b]] ::
|
||||
:: ::
|
||||
++ flaw |= [a=cafe b=tang] :: bolt from error
|
||||
[p=a q=[%2 p=*(set beam) q=b]] ::
|
||||
++ flag :: beam into deps
|
||||
@ -208,11 +216,12 @@
|
||||
::
|
||||
++ za :: per event
|
||||
=| $: $: $: our=ship :: computation owner
|
||||
bek=beak :: desk context
|
||||
hen=duct :: event floor
|
||||
== ::
|
||||
$: now=@da :: event date
|
||||
eny=@ :: unique entropy
|
||||
ska=$+(* (unit (unit))) :: system namespace
|
||||
ska=sled :: system namespace
|
||||
== ::
|
||||
mow=(list move) :: pending actions
|
||||
== ::
|
||||
@ -238,14 +247,8 @@
|
||||
=: p.tad.bay +(p.tad.bay)
|
||||
dym.bay (~(put by dym.bay) hen num)
|
||||
==
|
||||
~(exec zo [num `task`[hen u.kus 0 ~]])
|
||||
~(exec zo [num `task`[hen u.kus ~ 0 ~]])
|
||||
::
|
||||
::++ apel :: stateless
|
||||
:: |= [hen=duct kus=silk]
|
||||
:: ^- (unit gift)
|
||||
:: =+ num=0 :: XX
|
||||
:: ~(exit zo [num `task`[hen kus 0 ~]])
|
||||
::::
|
||||
++ axon :: take
|
||||
|= [num=@ud tik=@ud sih=sign]
|
||||
^+ +>
|
||||
@ -259,32 +262,54 @@
|
||||
==
|
||||
::
|
||||
++ axun :: take rev update
|
||||
|= [dep=@uvH sih=sign]
|
||||
|= [tea=wire dep=@uvH sup=spur sih=sign]
|
||||
^+ +>
|
||||
?- -.+.sih
|
||||
%writ
|
||||
+>.$(mow :_(mow [hen %give %news ~]))
|
||||
?~ p.sih +>.$
|
||||
=+ [dap=(~(got by deh.bay) dep) bem=`beam`[bek sup]]
|
||||
=- ?~(dop con con(deh.bay (~(put by deh.bay) dep dop)))
|
||||
^- [dop=$|(~ _dap) con=_+>.$]
|
||||
?- -.dap
|
||||
%done `+>.$ :: writ redundant
|
||||
%init ~|(never-subscribed/dep !!)
|
||||
%sent
|
||||
=- [[%done ~] +>.$(mow (weld - mow))]
|
||||
^- (list move)
|
||||
%+ weld (turn (~(tap in p.dap)) |=(hen=duct [hen %give %news ~]))
|
||||
=. q.dap (~(del in q.dap) bem)
|
||||
%+ turn (~(tap in q.dap)) :: cancel outstanding
|
||||
|= bem=beam
|
||||
=. tea [(scot %p our) (scot %uv dep) (tope bem)]
|
||||
[hen %pass tea %c %warp [our p.bem] q.bem ~]
|
||||
==
|
||||
==
|
||||
::
|
||||
++ awap :: get next revision
|
||||
~% %ford-w ..is ~
|
||||
|= dep=@uvH
|
||||
%_ +>.$
|
||||
mow
|
||||
%- welp :_ mow
|
||||
%+ turn ~|(dep-missed/dep (~(tap in (~(got by deh.bay) dep))))
|
||||
|= a=beam
|
||||
:^ hen %pass [(scot %p our) (scot %uv dep) ~]
|
||||
=- [%c [%warp [our p.a] q.a ~ [%& %y ud/+(`@ud`-) s.a]]]
|
||||
?. ?=(%ud -.r.a)
|
||||
;;(@ (need (need (ska %cw (tope -.a /)))))
|
||||
?: =(0 p.r.a)
|
||||
;;(@ (need (need (ska %cw (tope -.a(r da/now) /)))))
|
||||
p.r.a
|
||||
==
|
||||
?~ dep
|
||||
~&(dep-empty/hen +>.$)
|
||||
=+ dap=~|(dep-missed/dep (~(got by deh.bay) dep))
|
||||
?- -.dap
|
||||
%done +>.$(mow :_(mow [hen %give %news ~]))
|
||||
%sent
|
||||
=. p.dap (~(put in p.dap) hen)
|
||||
+>.$(deh.bay (~(put by deh.bay) dep dap))
|
||||
%init
|
||||
%_ +>.$
|
||||
deh.bay
|
||||
(~(put by deh.bay) dep [%sent [hen ~ ~] p.dap])
|
||||
::
|
||||
mow
|
||||
=< (welp :_(mow (turn (~(tap in p.dap)) .)))
|
||||
|= bem=beam
|
||||
:^ hen %pass [(scot %p our) (scot %uv dep) (tope bem)]
|
||||
[%c [%warp [our p.bem] q.bem ~ [%next %y r.bem (flop s.bem)]]]
|
||||
== ==
|
||||
::
|
||||
++ zo
|
||||
~% %ford-z
|
||||
~% %ford-z
|
||||
..is
|
||||
==
|
||||
%fade fade
|
||||
@ -311,9 +336,11 @@
|
||||
?~ kiz +>
|
||||
%= $
|
||||
kiz t.kiz
|
||||
mow :_ mow
|
||||
mow
|
||||
:_ mow
|
||||
:- hen
|
||||
:^ %pass [(scot %p our) (scot %ud num) (scot %ud p.i.kiz) ~]
|
||||
:^ %pass
|
||||
[(scot %p our) (scot %ud num) (scot %ud p.i.kiz) (tope bek ~)]
|
||||
%c
|
||||
[%warp [our p.q.q.i.kiz] q.q.q.i.kiz ~]
|
||||
==
|
||||
@ -323,11 +350,14 @@
|
||||
^+ +>
|
||||
%= +>
|
||||
kig [+(p.kig) (~(put by q.kig) p.kig [ren bem])]
|
||||
mow :_ mow
|
||||
mow
|
||||
:_ mow
|
||||
:- hen
|
||||
:^ %pass [(scot %p our) (scot %ud num) (scot %ud p.kig) ~]
|
||||
:^ %pass
|
||||
[(scot %p our) (scot %ud num) (scot %ud p.kig) (tope bek ~)]
|
||||
%c
|
||||
[%warp [our p.bem] q.bem [~ %& ren r.bem (flop s.bem)]]
|
||||
:: ~& >> [%camping bem]
|
||||
[%warp [our p.bem] q.bem [~ %sing ren r.bem (flop s.bem)]]
|
||||
==
|
||||
::
|
||||
++ clef :: cache a result
|
||||
@ -442,28 +472,67 @@
|
||||
++ dash :: process cache
|
||||
|= cof=cafe
|
||||
^+ +>
|
||||
%_(+> jav.bay q.cof, deh.bay r.cof)
|
||||
%_(+> jav.bay q.cof)
|
||||
::
|
||||
++ diff :: diff
|
||||
|= [cof=cafe kas=silk kos=silk]
|
||||
^- (bolt gage)
|
||||
%. [cof kas kos]
|
||||
;~ cope
|
||||
;~ coax
|
||||
|=([cof=cafe p=silk q=silk] (make cof p))
|
||||
|=([cof=cafe p=silk q=silk] (make cof q))
|
||||
==
|
||||
|= [cof=cafe cay=gage coy=gage]
|
||||
?. &(?=(@ p.cay) ?=(@ p.coy))
|
||||
(flaw cof leaf/"bad diff marc" ~)
|
||||
?. =(p.cay p.coy)
|
||||
%+ flaw cof :_ ~
|
||||
leaf/"diff on data of different marks: {(trip p.cay)} {(trip p.coy)}"
|
||||
?: =(q.q.cay q.q.coy)
|
||||
(fine cof %null [%atom %n] ~)
|
||||
%+ cope (fang cof p.cay)
|
||||
|= [cof=cafe pro=vase]
|
||||
?. (slab %grad p.pro)
|
||||
(flaw cof leaf/"no ++grad" ~)
|
||||
=+ gar=(slap pro [%cnzy %grad])
|
||||
?. (slab %form p.gar)
|
||||
?. (slab %sted p.gar)
|
||||
(flaw cof leaf/"no ++form:grad nor ++sted:grad" ~)
|
||||
=+ for=((soft ,@tas) q:(slap gar [%cnzy %sted]))
|
||||
?~ for
|
||||
(flaw cof leaf/"bad ++sted:grad" ~)
|
||||
%^ make cof %diff
|
||||
:- [%cast u.for [%done ~ cay]]
|
||||
[%cast u.for [%done ~ coy]]
|
||||
?. (slab %diff p.gar)
|
||||
(flaw cof leaf/"no ++diff:grad" ~)
|
||||
%+ cope (keel cof pro [[%& 6]~ q.cay]~)
|
||||
|= [cof=cafe pox=vase]
|
||||
%+ cope
|
||||
%^ maul cof
|
||||
(slap (slap pox [%cnzy %grad]) [%cnzy %diff])
|
||||
q.coy
|
||||
|= [cof=cafe dif=vase]
|
||||
=+ for=((soft ,@tas) q:(slap gar [%cnzy %form]))
|
||||
?~ for
|
||||
(flaw cof leaf/"bad ++form:grad" ~)
|
||||
(fine cof u.for dif)
|
||||
==
|
||||
::
|
||||
++ daze :: remember depends
|
||||
|= dep=(set beam)
|
||||
^+ [*@uvH deh.bay]
|
||||
?~ dep [0v0 deh.bay]
|
||||
=+ hap=(sham dep)
|
||||
[hap (~(put by deh.bay) hap dep)]
|
||||
::++ exit :: stateless exec
|
||||
:: ^- (unit gift)
|
||||
:: =+ bot=(make [~ jav.bay deh.bay] kas)
|
||||
:: :: =. ..exec (dash p.bot)
|
||||
:: ?- -.q.bot
|
||||
:: %0 `[%made p.q.bot %& q.q.bot]
|
||||
:: %2 `[%made p.q.bot %| q.q.bot]
|
||||
:: %1 ~
|
||||
:: ==
|
||||
::::
|
||||
?: (~(has by deh.bay) hap)
|
||||
[hap deh.bay]
|
||||
[hap (~(put by deh.bay) hap [%init dep])]
|
||||
::
|
||||
++ exec :: execute app
|
||||
^+ ..zo
|
||||
?: !=(~ q.kig) ..zo
|
||||
=+ bot=(make [~ jav.bay deh.bay] kas)
|
||||
=+ bot=(make [~ jav.bay] kas)
|
||||
=. ..exec (dash p.bot)
|
||||
?- -.q.bot
|
||||
%0 =^ dep deh.bay (daze p.q.bot)
|
||||
@ -487,11 +556,11 @@
|
||||
^- (bolt hood)
|
||||
%+ cool |.(leaf/"ford: fade {<[(tope bem)]>}")
|
||||
%+ cope (make cof [%bake for bem ~])
|
||||
|= [cof=cafe cay=cage]
|
||||
|= [cof=cafe cay=gage]
|
||||
%+ (clef %hood) (fine cof bem cay)
|
||||
^- (burg (pair beam cage) hood)
|
||||
|= [cof=cafe bum=beam cay=cage]
|
||||
:: ~& fade/clef-miss/bem
|
||||
^- (burg (pair beam gage) hood)
|
||||
|= [cof=cafe bum=beam cay=gage]
|
||||
:: ~& fade/clef-miss/bem
|
||||
=+ rul=(fair bem)
|
||||
?. ?=(@ q.q.cay)
|
||||
(flaw cof ~)
|
||||
@ -501,18 +570,10 @@
|
||||
(fine cof p.u.q.vex)
|
||||
::
|
||||
++ fang :: protocol door
|
||||
|= [cof=cafe for=mark bek=beak]
|
||||
|= [cof=cafe for=mark]
|
||||
^- (bolt vase)
|
||||
=+ pax=/door/[for]/mar
|
||||
=+ ^= bem ^- beam
|
||||
:_ pax
|
||||
?: &(=(p.bek our) =(q.bek %main) !=(r.bek [%da now]))
|
||||
bek
|
||||
=+ oak=-:(norm [our %main %da now] ~) :: XX at requested one
|
||||
?: ?=([~ ~ *] (ska %cy (tope [oak pax])))
|
||||
oak
|
||||
bek
|
||||
(cope (fade cof %hook bem) abut:(meow bem ~))
|
||||
(cope (fade cof %hook [bek pax]) abut:(meow [bek pax] ~))
|
||||
::
|
||||
++ fair :: hood parsing rule
|
||||
|= bem=beam
|
||||
@ -666,20 +727,114 @@
|
||||
--
|
||||
--
|
||||
::
|
||||
++ join
|
||||
|= [cof=cafe for=mark kas=silk kos=silk]
|
||||
^- (bolt gage)
|
||||
%. [cof kas kos]
|
||||
;~ cope
|
||||
;~ coax
|
||||
|=([cof=cafe p=silk q=silk] (make cof p))
|
||||
|=([cof=cafe p=silk q=silk] (make cof q))
|
||||
==
|
||||
|= [cof=cafe cay=gage coy=gage]
|
||||
?. &(?=(@ p.cay) ?=(@ p.coy))
|
||||
(flaw cof leaf/"bad join marc: {<p.cay>} {<p.coy>}" ~)
|
||||
%+ cope (fang cof for)
|
||||
|= [cof=cafe pro=vase]
|
||||
?. (slab %grad p.pro)
|
||||
(flaw cof leaf/"no ++grad" ~)
|
||||
=+ gar=(slap pro [%cnzy %grad])
|
||||
?. (slab %form p.gar)
|
||||
?. (slab %sted p.gar)
|
||||
(flaw cof leaf/"no ++form:grad nor ++sted:grad" ~)
|
||||
=+ too=((soft ,@tas) q:(slap gar [%cnzy %sted]))
|
||||
?~ too
|
||||
(flaw cof leaf/"bad ++sted:grad" ~)
|
||||
(make cof %join u.too [%done ~ cay] [%done ~ coy])
|
||||
=+ fom=((soft ,@tas) q:(slap gar [%cnzy %form]))
|
||||
?~ fom
|
||||
(flaw cof leaf/"bad ++form:grad" ~)
|
||||
?. &(=(u.fom p.cay) =(u.fom p.coy))
|
||||
%+ flaw cof :_ :_ ~
|
||||
leaf/"join on data of bad marks: {(trip p.cay)} {(trip p.coy)}"
|
||||
leaf/"expected mark {(trip u.fom)}"
|
||||
?: =(q.q.cay q.q.coy)
|
||||
(fine cof cay)
|
||||
?. (slab %join p.gar)
|
||||
(flaw cof leaf/"no ++join:grad" ~)
|
||||
%+ cope
|
||||
%^ maul cof
|
||||
(slap (slap pro [%cnzy %grad]) [%cnzy %join])
|
||||
(slop q.cay q.coy)
|
||||
|= [cof=cafe dif=vase]
|
||||
?@ q.dif
|
||||
(fine cof %null dif)
|
||||
(fine cof u.fom (slot 3 dif))
|
||||
==
|
||||
::
|
||||
++ mash
|
||||
|= [cof=cafe for=mark mas=milk mos=milk]
|
||||
^- (bolt gage)
|
||||
%. [cof r.mas r.mos]
|
||||
;~ cope
|
||||
;~ coax
|
||||
|=([cof=cafe p=silk q=silk] (make cof p))
|
||||
|=([cof=cafe p=silk q=silk] (make cof q))
|
||||
==
|
||||
|= [cof=cafe cay=gage coy=gage]
|
||||
?. &(?=(@ p.cay) ?=(@ p.coy))
|
||||
(flaw cof leaf/"bad mash marc: {<p.cay>} {<p.coy>}" ~)
|
||||
%+ cope (fang cof for)
|
||||
|= [cof=cafe pro=vase]
|
||||
?. (slab %grad p.pro)
|
||||
(flaw cof leaf/"no ++grad" ~)
|
||||
=+ gar=(slap pro [%cnzy %grad])
|
||||
?. (slab %form p.gar)
|
||||
?. (slab %sted p.gar)
|
||||
(flaw cof leaf/"no ++form:grad nor ++sted:grad" ~)
|
||||
=+ too=((soft ,@tas) q:(slap gar [%cnzy %sted]))
|
||||
?~ too
|
||||
(flaw cof leaf/"bad ++sted:grad" ~)
|
||||
%+ make cof
|
||||
[%mash u.too [p.mas q.mas [%done ~ cay]] [p.mos q.mos [%done ~ coy]]]
|
||||
=+ fom=((soft ,@tas) q:(slap gar [%cnzy %form]))
|
||||
?~ fom
|
||||
(flaw cof leaf/"bad ++form:grad" ~)
|
||||
?. &(=(u.fom p.cay) =(u.fom p.coy))
|
||||
%+ flaw cof :_ :_ ~
|
||||
leaf/"mash on data of bad marks: {(trip p.cay)} {(trip p.coy)}"
|
||||
leaf/"expected mark {(trip u.fom)}"
|
||||
?: =(q.q.cay q.q.coy)
|
||||
(fine cof cay)
|
||||
?. (slab %mash p.gar)
|
||||
(fine cof %null [%atom %n] ~)
|
||||
%+ cope
|
||||
%^ maul cof
|
||||
(slap (slap pro [%cnzy %grad]) [%cnzy %mash])
|
||||
;: slop
|
||||
(slop [[%atom %p] p.mas] [[%atom %tas] q.mas])
|
||||
(slop [[%atom %p] p.mos] [[%atom %tas] q.mos])
|
||||
q.cay
|
||||
q.coy
|
||||
==
|
||||
|= [cof=cafe dif=vase]
|
||||
(fine cof u.fom dif)
|
||||
==
|
||||
::
|
||||
++ kale :: mutate
|
||||
|= [cof=cafe kas=silk muy=(list (pair wing silk))]
|
||||
^- (bolt cage)
|
||||
^- (bolt gage)
|
||||
%+ cope
|
||||
|- ^- (bolt (list (pair wing vase)))
|
||||
?~ muy (flue cof)
|
||||
%+ cope (make cof q.i.muy)
|
||||
|= [cof=cafe cay=cage]
|
||||
|= [cof=cafe cay=gage]
|
||||
%+ cope ^$(muy t.muy)
|
||||
|= [cof=cafe rex=(list (pair wing vase))]
|
||||
(fine cof [[p.i.muy q.cay] rex])
|
||||
|= [cof=cafe yom=(list (pair wing vase))]
|
||||
%+ cope (make cof kas)
|
||||
|= [cof=cafe cay=cage]
|
||||
|= [cof=cafe cay=gage]
|
||||
%+ cope (keel cof q.cay yom)
|
||||
|= [cof=cafe vax=vase]
|
||||
(fine cof p.cay vax)
|
||||
@ -703,27 +858,31 @@
|
||||
++ lace :: load and check
|
||||
|= [cof=cafe for=mark bem=beam arg=heel]
|
||||
^- (bolt (unit vase))
|
||||
=+ bek=`beak`[p.bem q.bem r.bem]
|
||||
%+ cope (lend cof bem)
|
||||
|= [cof=cafe arc=arch]
|
||||
?^ q.arc
|
||||
(cope (cope (liar cof bem) (lake for bek)) (fest (norm bem)))
|
||||
(cope (cope (liar cof bem) (lake for)) (fest (norm bem)))
|
||||
?: (~(has by r.arc) %hook)
|
||||
%+ cope (fade cof %hook bem)
|
||||
|= [cof=cafe hyd=hood]
|
||||
%+ cope (cope (abut:(meow bem arg) cof hyd) (lake for bek))
|
||||
%+ cope (cope (abut:(meow bem arg) cof hyd) (lake for))
|
||||
(fest (norm bem))
|
||||
(flue cof)
|
||||
::
|
||||
++ lake :: check/coerce
|
||||
|= [for=mark bek=beak]
|
||||
|= for=mark
|
||||
|= [cof=cafe sam=vase]
|
||||
^- (bolt vase)
|
||||
%+ cool |.(leaf/"ford: check {<[for bek `@p`(mug q.sam)]>}")
|
||||
?: ?=(?(%gate %core %door %hoon %hook) for)
|
||||
?: ?=(?(%gate %core %door) for)
|
||||
:: ~& [%lake-easy for bek]
|
||||
(fine cof sam)
|
||||
%+ cope (fang cof for bek)
|
||||
?: ?=(?(%hoon %hook) for)
|
||||
=+ mas=((soft ,@t) q.sam)
|
||||
?~ mas
|
||||
(flaw cof [leaf/"ford: bad hoon or hook: {<[for bek]>}"]~)
|
||||
(fine cof [%atom %t] u.mas)
|
||||
%+ cope (fang cof for)
|
||||
|= [cof=cafe tux=vase]
|
||||
=+ bob=(slot 6 tux)
|
||||
?: (~(nest ut p.bob) | p.sam)
|
||||
@ -744,14 +903,14 @@
|
||||
|= [cof=cafe bem=beam]
|
||||
^- (bolt beam)
|
||||
?: ?=(%ud -.r.bem) (fine cof bem)
|
||||
=+ von=(ska %cw (tope bem(s ~)))
|
||||
=+ von=(save ~ %cw bem(s ~))
|
||||
?~ von [p=cof q=[%1 [%w bem ~] ~ ~]]
|
||||
(fine cof bem(r [%ud ((hard ,@) (need u.von))]))
|
||||
(fine cof bem(r [%ud ((hard ,@) +.+:(need u.von))]))
|
||||
::
|
||||
++ lave :: validate
|
||||
|= [cof=cafe for=mark his=ship som=*]
|
||||
^- (bolt vase)
|
||||
((lake for [our %main [%da now]]) cof [%noun som])
|
||||
((lake for) cof [%noun som])
|
||||
::
|
||||
++ lane :: type infer
|
||||
|= [cof=cafe typ=type gen=twig]
|
||||
@ -766,27 +925,37 @@
|
||||
|= [cof=cafe arc=arch]
|
||||
(fine cof (lark wox arc))
|
||||
::
|
||||
++ lear :: load vase
|
||||
|= [cof=cafe bem=beam]
|
||||
^- (bolt cage)
|
||||
=+ von=(save ~ %cx bem)
|
||||
?~ von
|
||||
[p=*cafe q=[%1 [[%x bem ~] ~ ~]]]
|
||||
?~ u.von
|
||||
(flaw cof leaf/"lear: file unavailable" (smyt (tope bem)) ~)
|
||||
(fine cof u.u.von)
|
||||
::
|
||||
++ lend :: load arch
|
||||
|= [cof=cafe bem=beam]
|
||||
^- (bolt arch)
|
||||
=+ von=(ska %cy (tope bem))
|
||||
=+ von=(save ~ %cy bem)
|
||||
?~ von [p=cof q=[%1 [%y bem ~] ~ ~]]
|
||||
(fine cof ((hard arch) (need u.von)))
|
||||
(fine cof ((hard arch) q.q:(need u.von)))
|
||||
::
|
||||
++ liar :: load vase
|
||||
|= [cof=cafe bem=beam]
|
||||
^- (bolt vase)
|
||||
=+ von=(ska %cx (tope bem))
|
||||
=+ von=(save ~ %cx bem)
|
||||
?~ von
|
||||
[p=*cafe q=[%1 [[%x bem ~] ~ ~]]]
|
||||
?~ u.von
|
||||
(flaw cof (smyt (tope bem)) ~)
|
||||
(fine cof ?^(u.u.von [%cell %noun %noun] [%atom %$]) u.u.von)
|
||||
(flaw cof leaf/"liar: file unavailable" (smyt (tope bem)) ~)
|
||||
(fine cof q.u.u.von)
|
||||
::
|
||||
++ lily :: translation targets
|
||||
|= [cof=cafe for=mark bek=beak]
|
||||
|= [cof=cafe for=mark]
|
||||
^- (bolt (list ,@tas))
|
||||
=+ raf=(fang cof for bek)
|
||||
=+ raf=(fang cof for)
|
||||
?: =(%2 -.q.raf) (fine p.raf ~)
|
||||
%+ cope raf
|
||||
|= [cof=cafe vax=vase]
|
||||
@ -812,12 +981,12 @@
|
||||
(lace cof for bem(s [for s.bem]) arg)
|
||||
=+ haz=(turn (~(tap by r.arc) ~) |=([a=@tas b=~] a))
|
||||
?~ haz (flue cof)
|
||||
%+ cope (lion cof for -.bem haz)
|
||||
%+ cope (lion cof for haz)
|
||||
|= [cof=cafe wuy=(list ,@tas)]
|
||||
?~ wuy (flue cof)
|
||||
%+ cope (make cof %bake i.wuy bem arg)
|
||||
|= [cof=cafe hoc=cage]
|
||||
%+ cope (lope cof i.wuy t.wuy -.bem q.hoc)
|
||||
|= [cof=cafe hoc=gage]
|
||||
%+ cope (lope cof i.wuy t.wuy q.hoc)
|
||||
|= [cof=cafe vax=vase]
|
||||
((fest bem) cof vax)
|
||||
::
|
||||
@ -829,22 +998,24 @@
|
||||
|= [cof=cafe vux=(unit vase)]
|
||||
?^ vux (fine cof u.vux)
|
||||
?~ s.mob
|
||||
(flag (norm mob) (flaw cof (smyt (tope bem)) ~))
|
||||
%+ flag
|
||||
(norm mob)
|
||||
(flaw cof leaf/"beam unavailable" (smyt (tope bem)) ~)
|
||||
^$(s.mob t.s.mob, mer [i.s.mob mer])
|
||||
::
|
||||
++ link :: translate
|
||||
|= [cof=cafe too=mark for=mark bek=beak vax=vase]
|
||||
|= [cof=cafe too=mark for=mark vax=vase]
|
||||
^- (bolt vase)
|
||||
?: =(too for) (fine cof vax)
|
||||
?: |(=(%noun for) =(%$ for))
|
||||
((lake too bek) cof vax)
|
||||
%+ cope (fang cof for bek)
|
||||
((lake too) cof vax)
|
||||
%+ cope (fang cof for)
|
||||
|= [cof=cafe pro=vase]
|
||||
?: &((slob %grow p.pro) (slob too p:(slap pro [%cnzy %grow])))
|
||||
%+ cope (keel cof pro [[%& 6]~ vax]~)
|
||||
|= [cof=cafe pox=vase]
|
||||
(maim cof pox [%tsgr [%cnzy %grow] [%cnzy too]])
|
||||
%+ cope (fang cof too bek)
|
||||
%+ cope (fang cof too)
|
||||
|= [cof=cafe pro=vase]
|
||||
=+ ^= zat ^- (unit vase)
|
||||
?. (slob %grab p.pro) ~
|
||||
@ -856,7 +1027,7 @@
|
||||
(maul cof u.zat vax)
|
||||
::
|
||||
++ lion :: translation search
|
||||
|= [cof=cafe too=@tas bek=beak fro=(list ,@tas)]
|
||||
|= [cof=cafe too=@tas fro=(list ,@tas)]
|
||||
^- (bolt (list ,@tas))
|
||||
=| war=(set ,@tas)
|
||||
=< -:(apex (fine cof fro))
|
||||
@ -881,7 +1052,7 @@
|
||||
[(fine cof [too ~]) +>.$]
|
||||
?: (~(has in war) for) [(flue cof) +>]
|
||||
=. war (~(put in war) for)
|
||||
=^ hoc +>.$ (apex (lily cof for bek))
|
||||
=^ hoc +>.$ (apex (lily cof for))
|
||||
:_ +>.$
|
||||
%+ cope hoc
|
||||
|= [cof=cafe ked=(list ,@tas)]
|
||||
@ -889,10 +1060,10 @@
|
||||
--
|
||||
::
|
||||
++ lope :: translation pipe
|
||||
|= [cof=cafe for=mark yaw=(list mark) bek=beak vax=vase]
|
||||
|= [cof=cafe for=mark yaw=(list mark) vax=vase]
|
||||
^- (bolt vase)
|
||||
?~ yaw (fine cof vax)
|
||||
%+ cope (link cof i.yaw for bek vax)
|
||||
%+ cope (link cof i.yaw for vax)
|
||||
|= [cof=cafe yed=vase]
|
||||
^$(cof cof, for i.yaw, yaw t.yaw, vax yed)
|
||||
::
|
||||
@ -912,12 +1083,12 @@
|
||||
^- (bolt vase)
|
||||
%+ cope (mail cof p.vax gen)
|
||||
|= [cof=cafe typ=type fol=nock]
|
||||
%+ (coup cof) (mock [q.vax fol] (mole ska))
|
||||
%+ (coup cof) (mock [q.vax fol] (mole (slod save)))
|
||||
|=(val=* `vase`[typ val])
|
||||
::
|
||||
++ make :: reduce silk
|
||||
|= [cof=cafe kas=silk]
|
||||
^- (bolt cage)
|
||||
^- (bolt gage)
|
||||
:: ~& [%make (,@tas -.kas)]
|
||||
?- -.kas
|
||||
^
|
||||
@ -928,7 +1099,7 @@
|
||||
|=([cof=cafe p=silk q=silk] ^$(cof cof, kas q.kas))
|
||||
==
|
||||
::
|
||||
|= [cof=cafe bor=cage heg=cage] ^- (bolt cage)
|
||||
|= [cof=cafe bor=gage heg=gage] ^- (bolt gage)
|
||||
[p=cof q=[%0 ~ [%$ (slop q.bor q.heg)]]]
|
||||
==
|
||||
::
|
||||
@ -938,7 +1109,7 @@
|
||||
%+ cope (lima cof p.kas q.kas r.kas)
|
||||
|= [cof=cafe vux=(unit vase)]
|
||||
?~ vux
|
||||
(flaw cof (smyt (tope q.kas)) ~)
|
||||
(flaw cof leaf/"bake failed" (smyt (tope q.kas)) ~)
|
||||
(fine cof [p.kas u.vux])
|
||||
::
|
||||
%boil
|
||||
@ -947,7 +1118,15 @@
|
||||
|= [cof=cafe bem=beam]
|
||||
%+ cope (lime cof p.kas bem r.kas)
|
||||
|= [cof=cafe vax=vase]
|
||||
(fine cof `cage`[p.kas vax])
|
||||
(fine cof `gage`[p.kas vax])
|
||||
::
|
||||
%bunt
|
||||
%+ cool |.(leaf/"ford: bunt {<p.kas>}")
|
||||
?: ?=(?(%hoon %hook) p.kas)
|
||||
(fine cof p.kas [%atom %t] '')
|
||||
%+ cope (fang cof p.kas)
|
||||
|= [cof=cafe tux=vase]
|
||||
(fine cof [p.kas (slot 6 tux)])
|
||||
::
|
||||
%call
|
||||
:: %+ cool |.(leaf/"ford: call {<`@p`(mug kas)>}")
|
||||
@ -958,7 +1137,7 @@
|
||||
|=([cof=cafe p=silk q=silk] ^$(cof cof, kas q))
|
||||
==
|
||||
::
|
||||
|= [cof=cafe gat=cage sam=cage]
|
||||
|= [cof=cafe gat=gage sam=gage]
|
||||
(maul cof q.gat q.sam)
|
||||
::
|
||||
|= [cof=cafe vax=vase]
|
||||
@ -968,27 +1147,47 @@
|
||||
%cast
|
||||
%+ cool |.(leaf/"ford: cast {<p.kas>}")
|
||||
%+ cope $(kas q.kas)
|
||||
|= [cof=cafe cay=cage]
|
||||
=+ bek=[our %main %da now] :: XX
|
||||
:: VV ::
|
||||
%+ cope (link cof p.kas p.cay bek q.cay)
|
||||
|= [cof=cafe cay=gage]
|
||||
^- (bolt gage)
|
||||
%+ cool |.(leaf/"ford: casting {<p.cay>} to {<p.kas>}")
|
||||
?. ?=(@ p.cay)
|
||||
(flaw cof leaf/"bad cast marc" ~)
|
||||
%+ cope (link cof p.kas p.cay q.cay)
|
||||
|= [cof=cafe vax=vase]
|
||||
(fine cof [p.kas vax])
|
||||
::
|
||||
:: %+ cope (lion cof p.kas bek [p.cay]~)
|
||||
:: |= [cof=cafe wuy=(list ,@tas)]
|
||||
:: ?~ wuy (flaw cof [%leaf "ford: no path: {<[p.cay p.kas]>}"]~)
|
||||
:: %+ cope (lope cof i.wuy t.wuy bek q.cay)
|
||||
:: |= [cof=cafe vax=vase]
|
||||
:: (fine cof [p.kas vax])
|
||||
::
|
||||
%diff
|
||||
%+ cool |.(leaf/"ford: diff {<`@p`(mug p.kas)>} {<`@p`(mug q.kas)>}")
|
||||
(diff cof p.kas q.kas)
|
||||
::
|
||||
%done [cof %0 p.kas q.kas]
|
||||
%dude (cool |.(p.kas) $(kas q.kas))
|
||||
%dune
|
||||
?~ q.kas [cof [%2 p.kas [%leaf "no data"]~]]
|
||||
$(kas [%done p.kas u.q.kas])
|
||||
::
|
||||
%file
|
||||
|
||||
%+ cool |.(leaf/"ford: file {<p.kas>}")
|
||||
(lear cof p.kas)
|
||||
::
|
||||
%join
|
||||
%+ cool
|
||||
|.
|
||||
leaf/"ford: join {<p.kas>} {<`@p`(mug q.kas)>} {<`@p`(mug r.kas)>}"
|
||||
(join cof p.kas q.kas r.kas)
|
||||
::
|
||||
%mash
|
||||
%+ cool
|
||||
|.
|
||||
leaf/"ford: mash {<p.kas>} {<`@p`(mug q.kas)>} {<`@p`(mug r.kas)>}"
|
||||
(mash cof p.kas q.kas r.kas)
|
||||
::
|
||||
%mute (kale cof p.kas q.kas)
|
||||
%pact
|
||||
%+ cool |.(leaf/"ford: pact {<`@p`(mug p.kas)>} {<`@p`(mug q.kas)>}")
|
||||
(pact cof p.kas q.kas)
|
||||
::
|
||||
%plan
|
||||
%+ cope (abut:(meow p.kas q.kas) cof r.kas)
|
||||
|= [cof=cafe vax=vase]
|
||||
@ -998,16 +1197,37 @@
|
||||
%ride
|
||||
%+ cool |.(leaf/"ford: ride {<`@p`(mug kas)>}")
|
||||
%+ cope $(kas q.kas)
|
||||
|= [cof=cafe cay=cage]
|
||||
|= [cof=cafe cay=gage]
|
||||
%+ cope (maim cof q.cay p.kas)
|
||||
|= [cof=cafe vax=vase]
|
||||
(fine cof %noun vax)
|
||||
::
|
||||
%tabl
|
||||
%+ cope
|
||||
|- ^- (bolt (pair (list (pair marc marc)) vase))
|
||||
?~ p.kas (fine cof ~ *vase)
|
||||
%+ cope (make cof p.i.p.kas)
|
||||
|= [cof=cafe key=gage]
|
||||
%+ cope (make cof q.i.p.kas)
|
||||
|= [cof=cafe val=gage]
|
||||
%+ cope ^^$(p.kas t.p.kas)
|
||||
|= [cof=cafe rex=(list (pair marc marc)) rey=vase]
|
||||
(fine cof [[p.key p.val] rex] (slop (slop q.key q.val) rey))
|
||||
|= [cof=cafe rex=(list (pair marc marc)) rey=vase]
|
||||
(fine cof [%tabl rex] rey)
|
||||
::
|
||||
%vale
|
||||
%+ cool |.(leaf/"ford: vale {<p.kas>} {<q.kas>} {<`@p`(mug r.kas)>}")
|
||||
%+ cope (lave cof p.kas q.kas r.kas)
|
||||
|= [cof=cafe vax=vase]
|
||||
(fine cof `cage`[p.kas vax])
|
||||
::
|
||||
%volt
|
||||
%+ cool |.(leaf/"ford: volt {<p.q.kas>}")
|
||||
%+ cope $(kas [%bunt p.q.kas])
|
||||
|= [cof=cafe cay=gage]
|
||||
^- (bolt gage)
|
||||
[cof %0 p.kas p.q.kas p.q.cay q.q.kas]
|
||||
==
|
||||
::
|
||||
++ malt :: cached slit
|
||||
@ -1026,7 +1246,7 @@
|
||||
^- (bolt vase)
|
||||
%+ cope (malt cof p.gat p.sam)
|
||||
|= [cof=cafe typ=type]
|
||||
%+ (coup cof) (mong [q.gat q.sam] (mole ska))
|
||||
%+ (coup cof) (mong [q.gat q.sam] (mole (slod save)))
|
||||
|=(val=* `vase`[typ val])
|
||||
::
|
||||
++ meow :: assemble
|
||||
@ -1262,7 +1482,7 @@
|
||||
^- beam
|
||||
?~ q.huf
|
||||
how(s ~[for p.huf way])
|
||||
[[q.u.q.huf %main p.u.q.huf] ~[for p.huf way]]
|
||||
[[q.u.q.huf q.how p.u.q.huf] ~[for p.huf way]]
|
||||
::
|
||||
++ neck :: consume libraries
|
||||
|= [cof=cafe bir=(list hoof)]
|
||||
@ -1332,20 +1552,85 @@
|
||||
|= bem=beam
|
||||
%_ bem
|
||||
r ?: ?=(%ud -.r.bem) r.bem
|
||||
=+ num=(ska %cw (tope bem(s ~)))
|
||||
?. ?=([~ ~ @u] num) r.bem :: XX
|
||||
[%ud u.u.num]
|
||||
=+ num=(ska ~ %cw bem(s ~))
|
||||
?. ?=([~ ~ * * @u] num) r.bem :: XX
|
||||
[%ud q.q.u.u.num]
|
||||
==
|
||||
::
|
||||
++ pact :: patch
|
||||
|= [cof=cafe kas=silk kos=silk]
|
||||
^- (bolt gage)
|
||||
%. [cof kas kos]
|
||||
;~ cope
|
||||
;~ coax
|
||||
|=([cof=cafe p=silk q=silk] (make cof p))
|
||||
|=([cof=cafe p=silk q=silk] (make cof q))
|
||||
==
|
||||
|= [cof=cafe cay=gage coy=gage]
|
||||
?. &(?=(@ p.cay) ?=(@ p.coy))
|
||||
(flaw cof leaf/"bad pact marc" ~)
|
||||
?: ?=(?(%hoon %hook) p.cay)
|
||||
?. ?=(%txt-diff p.coy)
|
||||
(flaw cof leaf/"{<p.cay>} mark with bad diff type: {<p.coy>}" ~)
|
||||
=+ txt=((soft ,@t) q.q.cay)
|
||||
?~ txt
|
||||
(flaw cof leaf/"{<p.cay>} mark on bad data" ~)
|
||||
=+ dif=((soft (urge cord)) q.q.coy)
|
||||
?~ dif
|
||||
=- (flaw cof leaf/"{<p.cay>} data with bad diff" -)
|
||||
[>type=p.q.coy< >shouldbe=-:!>(*(urge cord))< ~]
|
||||
=+ pac=(role (lurk (lore (cat 3 u.txt '\0a')) u.dif))
|
||||
(fine cof p.cay [%atom %t] (end 3 (dec (met 3 pac)) pac))
|
||||
%+ cope (fang cof p.cay)
|
||||
|= [cof=cafe pro=vase]
|
||||
?. (slab %grad p.pro)
|
||||
(flaw cof leaf/"no ++grad" ~)
|
||||
=+ gar=(slap pro [%cnzy %grad])
|
||||
?. (slab %form p.gar)
|
||||
?. (slab %sted p.gar)
|
||||
(flaw cof leaf/"no ++form:grad nor ++sted:grad" ~)
|
||||
=+ for=((soft ,@tas) q:(slap gar [%cnzy %sted]))
|
||||
?~ for
|
||||
(flaw cof leaf/"bad ++sted:grad" ~)
|
||||
(make cof %cast p.cay %pact [%cast u.for [%done ~ cay]] [%done ~ coy])
|
||||
=+ for=((soft ,@tas) q:(slap gar [%cnzy %form]))
|
||||
?~ for
|
||||
(flaw cof leaf/"bad ++form:grad" ~)
|
||||
?. =(u.for p.coy)
|
||||
%+ flaw cof :_ ~
|
||||
=< leaf/"pact on data with wrong form: {-} {+<} {+>}"
|
||||
[(trip p.cay) (trip u.for) (trip p.coy)]
|
||||
?. (slab %pact p.gar)
|
||||
(flaw cof leaf/"no ++pact:grad" ~)
|
||||
%+ cope (keel cof pro [[%& 6]~ q.cay]~)
|
||||
|= [cof=cafe pox=vase]
|
||||
%+ cope
|
||||
%^ maul cof
|
||||
(slap (slap pox [%cnzy %grad]) [%cnzy %pact])
|
||||
q.coy
|
||||
|= [cof=cafe pat=vase]
|
||||
(fine cof p.cay pat)
|
||||
==
|
||||
::
|
||||
++ resp
|
||||
|= [tik=@ud rot=riot]
|
||||
^+ ..zo
|
||||
?> (~(has by q.kig) tik)
|
||||
=+ `[ren=care bem=beam]`(~(got by q.kig) tik)
|
||||
?~ rot
|
||||
=+ `[ren=care bem=beam]`(~(got by q.kig) tik)
|
||||
=^ dep deh.bay (daze ~) :: dependencies?
|
||||
=^ dep deh.bay (daze ~) :: dependencies?
|
||||
amok:(expo [%made dep %| (smyt ren (tope bem)) ~])
|
||||
exec(q.kig (~(del by q.kig) tik))
|
||||
=+ (cat 3 'c' ren)
|
||||
exec(q.kig (~(del by q.kig) tik), keg (~(put by keg) [- bem] r.u.rot))
|
||||
::
|
||||
++ save
|
||||
^- sled
|
||||
|= [(unit (set monk)) tem=term bem=beam]
|
||||
^- (unit (unit cage))
|
||||
=+ (~(get by keg) tem bem)
|
||||
?^ -
|
||||
``u.-
|
||||
(ska +<.$)
|
||||
--
|
||||
--
|
||||
::
|
||||
@ -1361,7 +1646,6 @@
|
||||
|= [hen=duct hic=(hypo (hobo kiss))]
|
||||
^- [p=(list move) q=_..^$]
|
||||
=> .(q.hic ?.(?=(%soft -.q.hic) q.hic ((hard kiss) p.q.hic)))
|
||||
=+ ska=(slod ski) :: XX depends
|
||||
=+ ^= our ^- @p
|
||||
?- -.q.hic
|
||||
%exec p.q.hic
|
||||
@ -1372,8 +1656,9 @@
|
||||
?~(buy *baby u.buy)
|
||||
=^ mos bay
|
||||
?: ?=(%wasp -.q.hic)
|
||||
abet:(~(awap za [[our hen] [now eny ska] ~] bay) q.q.hic)
|
||||
abet:(~(apex za [[our hen] [now eny ska] ~] bay) q.q.hic)
|
||||
abet:(~(awap za [[our *beak hen] [now eny ski] ~] bay) q.q.hic)
|
||||
=* bek q.q.hic
|
||||
abet:(~(apex za [[our bek hen] [now eny ski] ~] bay) r.q.hic)
|
||||
[mos ..^$(pol (~(put by pol) our bay))]
|
||||
::
|
||||
++ doze
|
||||
@ -1400,7 +1685,7 @@
|
||||
::
|
||||
++ scry
|
||||
|= [fur=(unit (set monk)) ren=@tas who=ship syd=desk lot=coin tyl=path]
|
||||
^- (unit (unit (pair mark ,*)))
|
||||
^- (unit (unit cage))
|
||||
[~ ~]
|
||||
::
|
||||
++ stay :: save w/o cache
|
||||
@ -1409,17 +1694,19 @@
|
||||
++ take :: response
|
||||
|= [tea=wire hen=duct hin=(hypo sign)]
|
||||
^- [p=(list move) q=_..^$]
|
||||
=+ ska=(slod ski)
|
||||
?. ?=([@ @ $|(~ [@ ~])] tea)
|
||||
[~ ..^$] :: XX remove on breach
|
||||
=+ our=(need (slaw %p i.tea))
|
||||
?> ?=([@ @ *] tea)
|
||||
=+ our=(slav %p i.tea)
|
||||
=+ bay=(~(got by pol.lex) our)
|
||||
=^ mos bay
|
||||
?~ t.t.tea
|
||||
abet:(~(axun za [[our hen] [now eny ska] ~] bay) (slav %uv i.t.tea) q.hin)
|
||||
=+ :* num=(need (slaw %ud i.t.tea))
|
||||
tik=(need (slaw %ud i.t.t.tea))
|
||||
=+ dep=(slaw %uv i.t.tea)
|
||||
?^ dep
|
||||
=+ [bek sup]=(need (tome t.t.tea))
|
||||
abet:(~(axun za [[our bek hen] [now eny ski] ~] bay) tea u.dep sup q.hin)
|
||||
?> ?=([@ @ @ @ ~] t.t.tea)
|
||||
=+ :* num=(slav %ud i.t.tea)
|
||||
tik=(slav %ud i.t.t.tea)
|
||||
bek=-:(need (tome t.t.t.tea))
|
||||
==
|
||||
abet:(~(axon za [[our hen] [now eny ska] ~] bay) num tik q.hin)
|
||||
abet:(~(axon za [[our bek hen] [now eny ski] ~] bay) num tik q.hin)
|
||||
[mos ..^$(pol (~(put by pol) our bay))]
|
||||
--
|
@ -8,7 +8,7 @@
|
||||
$: %0 :: state version
|
||||
pol=(map ship mast) :: apps by ship
|
||||
== ::
|
||||
++ bead ,[p=(set beam) q=cage] :: computed result
|
||||
++ bead ,[p=(set beam) q=gage] :: computed result
|
||||
++ bone ,@ud :: opaque duct
|
||||
++ gift :: out result <-$
|
||||
$% [%back p=?] :: %mess ack good/bad
|
||||
@ -57,12 +57,10 @@
|
||||
++ note :: out request $->
|
||||
$? $: %a :: to %ames
|
||||
$% [%wont p=sock q=path r=*] ::
|
||||
== == ::
|
||||
$: %c :: to %clay
|
||||
$% [%warp p=sock q=riff] ::
|
||||
== == ::
|
||||
$: %f :: to %ford
|
||||
$% [%exec p=@p q=(unit silk)] ::
|
||||
$% [%exec p=@p q=beak r=(unit silk)] ::
|
||||
[%wasp p=@p q=@uvH] ::
|
||||
== == ::
|
||||
$: %g :: to %gall
|
||||
$% [%show p=hapt q=ship r=path] ::
|
||||
@ -74,10 +72,6 @@
|
||||
$: @tas :: to any
|
||||
$% [%meta p=vase] ::
|
||||
== == == ::
|
||||
++ rave :: see %clay
|
||||
$% [& p=mood] :: single request
|
||||
[| p=moat] :: change range
|
||||
== ::
|
||||
++ riff ,[p=desk q=(unit rave)] :: see %clay
|
||||
++ scad :: opaque for foreign
|
||||
$: p=@ud :: index
|
||||
@ -120,7 +114,7 @@
|
||||
peq=(map bone ,@uvI) :: peekers
|
||||
qel=(map bone ,@ud) :: rush queue length
|
||||
== ::
|
||||
ped=(set (pair ship desk)) :: active depends
|
||||
ped=@uvH :: active depends
|
||||
zam=scar :: opaque ducts
|
||||
== ::
|
||||
++ silk :: see %ford
|
||||
@ -159,7 +153,8 @@
|
||||
[%vega p=path] ::
|
||||
== == ::
|
||||
$: %f :: by %ford
|
||||
$% [%made p=@uvH q=(each cage tang)] ::
|
||||
$% [%made p=@uvH q=(each gage tang)] ::
|
||||
[%news ~] ::
|
||||
== == == ::
|
||||
++ toil (pair duct knob) :: work in progress
|
||||
-- ::::::::::::::::::::::::::::::::::::::::::::::::::::::
|
||||
@ -302,7 +297,7 @@
|
||||
lot=coin
|
||||
tyl=path
|
||||
==
|
||||
^- (unit (unit (pair mark ,*)))
|
||||
^- (unit (unit cage))
|
||||
=+ ^= vew ^- lens :: XX future scry
|
||||
%. :- use
|
||||
:- [who syd ((hard case) p.lot)]
|
||||
@ -320,7 +315,7 @@
|
||||
%y y.vew
|
||||
%z z.vew
|
||||
==
|
||||
|=(a=(unit) (bind a |=(b=* [%noun b])))
|
||||
|=(a=(unit) (bind a |=(b=* [%noun !>(b)])))
|
||||
::
|
||||
++ doze
|
||||
|= [now=@da hen=duct]
|
||||
@ -337,6 +332,7 @@
|
||||
--
|
||||
|% :: inner core
|
||||
::
|
||||
++ leak |=(our=ship `beak`[our %home %da now]) :: default beak
|
||||
++ best :: cage to gift
|
||||
|= [sem=?(%rush %rust) cay=cage]
|
||||
^- gift
|
||||
@ -407,6 +403,8 @@
|
||||
[hen %give %mean u.q.sih]
|
||||
::
|
||||
%f
|
||||
?. ?=(%made +<.sih)
|
||||
~& [%gall-bad-gasp +<.sih] `..^$
|
||||
:_ ..^$
|
||||
:_ ~
|
||||
:- hen
|
||||
@ -415,6 +413,7 @@
|
||||
[%give %crud %gasp-crud p.q.+.sih]
|
||||
::
|
||||
%&
|
||||
?. ?=(@ p.p.q.+.sih) ~| %bad-marc !!
|
||||
=+ cay=`cage`p.q.+.sih
|
||||
?+ -.pax !!
|
||||
%d [%give (best %rush cay)]
|
||||
@ -440,10 +439,12 @@
|
||||
[%pass [%r pax] %g %took [our imp] you]
|
||||
::
|
||||
%f
|
||||
?< ?=(%news -.+.sih)
|
||||
:_ ~ :- hen
|
||||
?- -.q.+.sih
|
||||
%| [%give %mean ~ %ford-fail p.q.+.sih]
|
||||
%& [%pass [%r pax] %g %mess [our imp] you `cage`p.q.+.sih]
|
||||
%& ?. ?=(@ p.p.q.+.sih) ~| %bad-marc !!
|
||||
[%pass [%r pax] %g %mess [our imp] you `cage`p.q.+.sih]
|
||||
==
|
||||
::
|
||||
%g
|
||||
@ -479,9 +480,9 @@
|
||||
:- [hen %give %nice ~] :_ ~
|
||||
^- move :- neh
|
||||
?- -.ron
|
||||
%d [%pass /x/d `note`[%f %exec p.saq ~ %vale p.ron q.saq q.ron]]
|
||||
%d [%pass /x/d %f %exec p.saq (leak p.saq) ~ %vale p.ron q.saq q.ron]
|
||||
%e [%give %mean p.ron]
|
||||
%f [%pass /x/f `note`[%f %exec p.saq ~ %vale p.ron q.saq q.ron]]
|
||||
%f [%pass /x/f %f %exec p.saq (leak p.saq) ~ %vale p.ron q.saq q.ron]
|
||||
%k [%give %nice ~]
|
||||
==
|
||||
::
|
||||
@ -501,7 +502,7 @@
|
||||
==
|
||||
^- note
|
||||
?- -.rok
|
||||
%m [%f %exec p.saq ~ %vale p.rok q.saq q.rok]
|
||||
%m [%f %exec p.saq (leak p.saq) ~ %vale p.rok q.saq q.rok]
|
||||
%s [%g %show [p.saq imp] q.saq p.rok]
|
||||
%u [%g %nuke [p.saq imp] q.saq]
|
||||
==
|
||||
@ -695,44 +696,16 @@
|
||||
:: ~& [%deff imp cub.sat]
|
||||
[hon r.q.caq]
|
||||
::
|
||||
++ drug :: set dependencies
|
||||
|= pen=(set (pair ship desk))
|
||||
:: ~& [%drug ped=ped.sat]
|
||||
:: ~& [%drug pen=pen]
|
||||
^+ +>
|
||||
=+ ^= new ^- (list move)
|
||||
%+ turn
|
||||
%+ skip (~(tap in pen) ~)
|
||||
|=(a=(pair ship desk) (~(has in ped.sat) a))
|
||||
|= a=(pair ship desk)
|
||||
:- hun.mat
|
||||
:^ %pass (away %w %drug (scot %p p.a) q.a ~) %c
|
||||
:: ~& [%sync-subscribe our p.a q.a]
|
||||
[%warp [our p.a] q.a ~ %| [%da +(now)] [%da (add now ~d1000)] /]
|
||||
=+ ^= old ^- (list move)
|
||||
%+ turn
|
||||
%+ skip (~(tap in ped.sat) ~)
|
||||
|=(a=(pair ship desk) (~(has in pen) a))
|
||||
|= a=(pair ship desk)
|
||||
:- hun.mat
|
||||
:^ %pass (away %w %drug (scot %p p.a) q.a ~) %c
|
||||
~& [%sync-unsubscribe our p.a q.a]
|
||||
[%warp [our p.a] q.a ~]
|
||||
%_(+>.$ ped.sat pen, mow :(weld new old mow))
|
||||
::
|
||||
++ drum :: raw dependencies
|
||||
++ drum :: set dependencies
|
||||
|= dep=@uvH
|
||||
^+ +>
|
||||
?> ?=(^ orm.sat)
|
||||
%- drug
|
||||
=+ ped=`(set (pair ship desk))`[[our %main] ~ ~]
|
||||
ped
|
||||
::=+ mav=(~(tap by dep) ~)
|
||||
::|- ^+ ped
|
||||
::?~ mav ped
|
||||
::?: =(r.i.mav [%da u.orm.sat])
|
||||
:: $(mav t.mav, ped (~(put in ped) p.i.mav q.i.mav))
|
||||
::$(mav t.mav)
|
||||
?~ dep ~&(%drum-none +>.$)
|
||||
?: =(dep ped.sat) +>.$
|
||||
=+ pax=(away %w %drum (scot %uv dep) ~)
|
||||
%_ +>.$
|
||||
ped.sat dep
|
||||
mow :_(mow [hun.mat %pass pax %f %wasp our dep]) :: XX cancel old
|
||||
==
|
||||
::
|
||||
++ ford :: exec to ford
|
||||
|= [pax=path kas=silk]
|
||||
@ -741,9 +714,9 @@
|
||||
:+ %dude
|
||||
leaf/"error in app {<app.sat>} on {<our>} at instance {<imp>}"
|
||||
kas
|
||||
%_ +>
|
||||
mow :_(mow [hen %pass (away pax) %f [%exec our `kas]])
|
||||
onz.sat `[hen pax]
|
||||
%_ +>
|
||||
mow :_(mow [hen %pass (away pax) %f [%exec our (leak our) `kas]])
|
||||
onz.sat `[hen pax]
|
||||
==
|
||||
::
|
||||
++ give :: give a gift
|
||||
@ -757,7 +730,8 @@
|
||||
::
|
||||
++ home :: load application
|
||||
^- silk
|
||||
[%boil %core [[our %main [%da now]] app.sat %app ~] ~]
|
||||
=+ let=((hard ,@) q.q:(need (need (ska ~ %cw [our %home %da now] /))))
|
||||
[%boil %core [[our %home %ud ?:(=(let 0) 1 let)] app.sat %app ~] ~]
|
||||
::
|
||||
++ leav
|
||||
%_ .
|
||||
@ -774,7 +748,7 @@
|
||||
::
|
||||
++ mack :: apply standard
|
||||
|= sih=sign
|
||||
?> ?=(%f -.sih)
|
||||
?> ?=([%f %made *] sih)
|
||||
^- [(unit (list tank)) _+>]
|
||||
?- -.q.+.sih
|
||||
& :- ~
|
||||
@ -786,7 +760,7 @@
|
||||
++ meek :: apply peek
|
||||
|= sih=sign
|
||||
^- [(unit cage) _+>]
|
||||
?> ?=(%f -.sih)
|
||||
?> ?=([%f %made *] sih)
|
||||
?- -.q.+.sih
|
||||
& =+ vax=`vase`q.p.q.+.sih
|
||||
?. &(?=(^ q.vax) ?=(@ -.q.vax))
|
||||
@ -799,9 +773,9 @@
|
||||
::
|
||||
++ mick :: apply w/depends
|
||||
|= sih=sign
|
||||
?> ?=(%f -.sih)
|
||||
^- [[p=? q=@uvH] _+>]
|
||||
:- [-.q.+.sih p.+.sih]
|
||||
?> ?=([%f %made *] sih)
|
||||
^- [? _+>]
|
||||
:- -.q.+.sih
|
||||
?- -.q.+.sih
|
||||
& %- obey:(morn (slot 3 q.p.q.+.sih))
|
||||
(slot 2 q.p.q.+.sih)
|
||||
@ -811,7 +785,7 @@
|
||||
++ muck :: apply part
|
||||
|= sih=sign
|
||||
^- [(unit (list tank)) _+>]
|
||||
?> ?=(%f -.sih)
|
||||
?> ?=([%f %made *] sih)
|
||||
?- -.q.+.sih
|
||||
& [~ (obey q.p.q.+.sih)]
|
||||
| [`p.q.+.sih (give %crud %muck-made p.q.+.sih)]
|
||||
@ -819,11 +793,12 @@
|
||||
::
|
||||
++ murk :: apply park
|
||||
|= sih=sign
|
||||
^- [(unit cage) _+>]
|
||||
?> ?=(%f -.sih)
|
||||
^- [[p=@uvH q=(unit cage)] _+>]
|
||||
?> ?=([%f %made *] sih)
|
||||
?- -.q.+.sih
|
||||
& [`p.q.+.sih +>.$]
|
||||
| [~ (give %crud %murk-made p.q.+.sih)]
|
||||
& ?. ?=(@ p.p.q.+.sih) ~| %bad-marc !!
|
||||
[[p.+.sih `p.q.+.sih] +>.$]
|
||||
| [[p.+.sih ~] (give %crud %murk-made p.q.+.sih)]
|
||||
==
|
||||
::
|
||||
++ more :: domestic take
|
||||
@ -850,9 +825,9 @@
|
||||
::
|
||||
%park
|
||||
=^ gyd +>.$ (murk q.hin)
|
||||
?~ gyd
|
||||
+>.$
|
||||
(quen %load u.gyd)
|
||||
?~ q.gyd (drum p.gyd)
|
||||
=. +>.$ (drum p.gyd)
|
||||
(quen %load u.q.gyd)
|
||||
::
|
||||
%part
|
||||
=^ gud +>.$ (muck q.hin)
|
||||
@ -905,8 +880,8 @@
|
||||
::
|
||||
%prep
|
||||
=^ gad +>.$ (mick q.hin)
|
||||
?. p.gad (drum q.gad)
|
||||
deal:(drum q.gad)
|
||||
?. gad +>.$
|
||||
deal
|
||||
::
|
||||
%pull
|
||||
=^ gud +>.$ (mack q.hin)
|
||||
@ -921,15 +896,15 @@
|
||||
==
|
||||
::
|
||||
%w :: autoboot
|
||||
?> ?=([%drug @ @ ~] t.pax)
|
||||
=+ :* sin=((hard ,[%c %writ p=riot]) q.hin)
|
||||
our=(need (slaw %p i.t.t.pax))
|
||||
syd=(need ((sand %tas) i.t.t.t.pax))
|
||||
==
|
||||
::~& [%sync-notified `@p`our `@ta`syd]
|
||||
=. ped.sat (~(del by ped.sat) [our syd])
|
||||
?~ p.+.sin
|
||||
+>.$
|
||||
?> ?=([%drum @ ~] t.pax)
|
||||
?> ?=([%f %news ~] q.hin)
|
||||
:: ?> ?=([%drug @ @ ~] t.pax)
|
||||
:: =+ :- sin=((hard ,[%c %writ p=(unit)]) q.hin)
|
||||
:: [our syd]=(raid t.t.pax %p %tas ~)
|
||||
:: ::~& [%sync-notified `@p`our `@ta`syd]
|
||||
:: =. ped.sat (~(del by ped.sat) [our syd])
|
||||
:: ?~ p.+.sin
|
||||
:: +>.$
|
||||
+>.$(vey.sat (~(put to vey.sat) hen %boot ~))
|
||||
==
|
||||
::
|
||||
@ -973,7 +948,7 @@
|
||||
%= +>
|
||||
onz.sat ~
|
||||
mow
|
||||
:_(mow [hen %pass (away q.u.onz.sat) %f [%exec our ~]])
|
||||
:_(mow [hen %pass (away q.u.onz.sat) %f [%exec our (leak our) ~]])
|
||||
==
|
||||
+>.$(vey.sat (~(put to vey.sat) hen kon))
|
||||
::
|
||||
@ -1059,6 +1034,14 @@
|
||||
::
|
||||
++ work :: eat queue
|
||||
|- ^+ +
|
||||
:: ~& > :* %workeando
|
||||
:: our=our
|
||||
:: vey==(~ vey.sat)
|
||||
:: ^= qic
|
||||
:: ?: ?=(^ qic.sat)
|
||||
:: [p -.q]:u.qic.sat
|
||||
:: ~
|
||||
:: ==
|
||||
?: |(?=(^ qic.sat) =(~ vey.sat)) +.$ :: nothing to do
|
||||
=^ yev vey.sat [p q]:~(get to vey.sat)
|
||||
?: (~(has in nuc.sat) p.yev) $
|
||||
@ -1182,7 +1165,7 @@
|
||||
|= [a=term b=(list term)]
|
||||
[(cat 3 'pock-' a) (cat 3 'poke-' a) b]
|
||||
=+ ofs=(met 3 app.sat)
|
||||
?. .= (cat 3 app.sat '-') :: XX temporary, until /=main=/bin
|
||||
?. .= (cat 3 app.sat '-') :: XX temporary, until /=home=/bin
|
||||
(end 3 +(ofs) p.q.kon)
|
||||
(goc p.q.kon /pock)
|
||||
:(goc p.q.kon (rsh 3 ofs p.q.kon) /pock)
|
@ -50,7 +50,7 @@
|
||||
[std=term kel=@] :: kelvin version
|
||||
[ven=term pro=term kel=@] :: vendor and product
|
||||
[ven=term pro=term ver=@ kel=@] :: all of the above
|
||||
==
|
||||
== ::
|
||||
++ clue ,[p=chum q=nock r=(list (pair term nock))] :: battery definition
|
||||
++ coil $: p=?(%gold %iron %lead %zinc) :: core type
|
||||
q=type ::
|
||||
@ -649,8 +649,7 @@
|
||||
::
|
||||
++ need :: demand
|
||||
|* a=(unit)
|
||||
~| %need
|
||||
?~ a !!
|
||||
?~ a ~|(%need !!)
|
||||
u.a
|
||||
::
|
||||
++ some :: lift (pure)
|
||||
@ -1799,6 +1798,17 @@
|
||||
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
|
||||
:: section 2cI, almost macros ::
|
||||
::
|
||||
++ same |*(* +<) :: identity
|
||||
++ head |*(^ +<-) :: get head
|
||||
++ tail |*(^ +<+) :: get head
|
||||
++ test |=(^ =(+<- +<+)) :: equality
|
||||
++ cork |*([a=_,* b=gate] (corl b a)) :: compose forward
|
||||
++ corl :: compose backwards
|
||||
|* [a=gate b=_,*]
|
||||
=< +:|.((a (b))) :: type check
|
||||
|* c=_+<.b
|
||||
(a (b c))
|
||||
::
|
||||
++ cury :: curry left
|
||||
|* [a=_|=(^ **) b=*]
|
||||
|* c=_+<+.a
|
||||
@ -1809,14 +1819,6 @@
|
||||
|* b=_+<+.a
|
||||
(a b c)
|
||||
::
|
||||
++ cork |*([a=_,* b=gate] (corl b a)) :: compose forward
|
||||
::
|
||||
++ corl :: compose backwards
|
||||
|* [a=gate b=_,*]
|
||||
=< +:|.((a (b))) :: type check
|
||||
|* c=_+<.b
|
||||
(a (b c))
|
||||
::
|
||||
++ hard :: force coerce to type
|
||||
|* han=$+(* *)
|
||||
|= fud=* ^- han
|
||||
@ -1885,7 +1887,7 @@
|
||||
|- ^- (unit ,@)
|
||||
?~ a ~
|
||||
?: =(b n.a) [~ u=(peg c 2)]
|
||||
?: (gor b n.a)
|
||||
?: (hor b n.a)
|
||||
$(a l.a, c (peg c 6))
|
||||
$(a r.a, c (peg c 7))
|
||||
::
|
||||
@ -1991,8 +1993,8 @@
|
||||
|= a=(tree ,[p=* q=*])
|
||||
?~ a
|
||||
&
|
||||
?& ?~(l.a & ?&((vor p.n.a p.n.l.a) (hor p.n.l.a p.n.a)))
|
||||
?~(r.a & ?&((vor p.n.a p.n.r.a) (hor p.n.a p.n.r.a)))
|
||||
?& ?~(l.a & ?&((vor p.n.a p.n.l.a) (gor p.n.l.a p.n.a)))
|
||||
?~(r.a & ?&((vor p.n.a p.n.r.a) (gor p.n.a p.n.r.a)))
|
||||
==
|
||||
::
|
||||
++ ja :: jar engine
|
||||
@ -2124,12 +2126,12 @@
|
||||
?: (vor p.n.a p.n.b)
|
||||
?: =(p.n.b p.n.a)
|
||||
[n.b $(a l.a, b l.b) $(a r.a, b r.b)]
|
||||
?: (hor p.n.b p.n.a)
|
||||
?: (gor p.n.b p.n.a)
|
||||
%- uni(+< $(a l.a, b [n.b l.b ~])) $(b r.b)
|
||||
%- uni(+< $(a r.a, b [n.b ~ r.b])) $(b l.b)
|
||||
?: =(p.n.a p.n.b)
|
||||
[n.b $(b l.b, a l.a) $(b r.b, a r.a)]
|
||||
?: (hor p.n.a p.n.b)
|
||||
?: (gor p.n.a p.n.b)
|
||||
%- uni(+< $(b l.b, a [n.a l.a ~])) $(a r.a)
|
||||
%- uni(+< $(b r.b, a [n.a ~ r.a])) $(a l.a)
|
||||
::
|
||||
@ -2202,12 +2204,12 @@
|
||||
?: (vor p.n.a p.n.b)
|
||||
?: =(p.n.b p.n.a)
|
||||
[n.b $(a l.a, b l.b) $(a r.a, b r.b)]
|
||||
?: (hor p.n.b p.n.a)
|
||||
?: (gor p.n.b p.n.a)
|
||||
$(a [n.a $(a l.a, b [n.b l.b ~]) r.a], b r.b)
|
||||
$(a [n.a l.a $(a r.a, b [n.b ~ r.b])], b l.b)
|
||||
?: =(p.n.a p.n.b)
|
||||
[n.b $(b l.b, a l.a) $(b r.b, a r.a)]
|
||||
?: (hor p.n.a p.n.b)
|
||||
?: (gor p.n.a p.n.b)
|
||||
$(b [n.b $(b l.b, a [n.a l.a ~]) r.b], a r.a)
|
||||
$(b [n.b l.b $(b r.b, a [n.a ~ r.a])], a l.a)
|
||||
::
|
||||
@ -9393,13 +9395,14 @@
|
||||
== ::
|
||||
++ desk ,@tas :: ship desk case spur
|
||||
++ cage (cask vase) :: global metadata
|
||||
++ cask |*(a=$+(* *) (pair mark a)) :: global data
|
||||
++ cask |*(a=_,* (pair mark a)) :: global data
|
||||
++ cuff :: permissions
|
||||
$: p=kirk :: readers
|
||||
q=(set monk) :: authors
|
||||
== ::
|
||||
++ curd ,[p=@tas q=*] :: typeless card
|
||||
++ duct (list wire) :: causal history
|
||||
++ gage (pair marc vase) :: structured cage
|
||||
++ hide :: standard app state
|
||||
$: $: our=ship :: owner/operator
|
||||
app=term :: app identity
|
||||
@ -9429,6 +9432,10 @@
|
||||
++ y *(unit (unit arch)) :: directory
|
||||
++ z *(unit (unit cage)) :: current subtree
|
||||
-- ::
|
||||
++ marc :: structured mark
|
||||
$| mark :: plain mark
|
||||
$% [%tabl p=(list (pair marc marc))] :: map
|
||||
== ::
|
||||
++ mark ,@tas :: content type
|
||||
++ mill (each vase milt) :: vase/metavase
|
||||
++ milt ,[p=* q=*] :: metavase
|
||||
@ -9448,6 +9455,8 @@
|
||||
++ ship ,@p :: network identity
|
||||
++ sled $+ [(unit (set monk)) term beam] :: namespace function
|
||||
(unit (unit cage)) ::
|
||||
++ slad $+ [(unit (set monk)) term beam] :: undertyped
|
||||
(unit (unit (cask))) ::
|
||||
++ slut $+(* (unit (unit))) :: old namespace
|
||||
++ vile :: reflexive constants
|
||||
$: typ=type :: -:!>(*type)
|
||||
@ -9458,7 +9467,7 @@
|
||||
++ wire path :: event pretext
|
||||
::::: hacks
|
||||
++ slod
|
||||
|= sed=sled
|
||||
|= sed=slad
|
||||
^- slut
|
||||
|= raw=*
|
||||
=+ pux=((soft path) raw)
|
||||
@ -9479,7 +9488,7 @@
|
||||
=+ bop=(sed ~ ron bed)
|
||||
?~ bop ~
|
||||
?~ u.bop [~ ~]
|
||||
[~ ~ q.q.u.u.bop]
|
||||
[~ ~ +.q.u.u.bop]
|
||||
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
|
||||
:: section 3bE, Arvo core ::
|
||||
::
|
||||
@ -9498,7 +9507,7 @@
|
||||
+>.$(q.sew (slam (slap syg [%cnzy %load]) (slap rig [%cnzy %stay])))
|
||||
::
|
||||
++ wink :: deploy
|
||||
|= [now=@da eny=@ ski=sled]
|
||||
|= [now=@da eny=@ ski=slad]
|
||||
=+ rig=(slym q.sew +<) :: activate vane
|
||||
~% %wink +>+> ~
|
||||
|%
|
||||
@ -9645,7 +9654,7 @@
|
||||
ren=care
|
||||
bed=beam
|
||||
==
|
||||
^- (unit (unit cage))
|
||||
^- (unit (unit (cask)))
|
||||
:: ~& [%arvo-scry ren bed]
|
||||
=+ ^= old
|
||||
:* fur
|
||||
@ -9655,12 +9664,12 @@
|
||||
`coin`[%$ r.bed]
|
||||
(flop s.bed)
|
||||
==
|
||||
^- (unit (unit cage))
|
||||
^- (unit (unit (cask)))
|
||||
=+ pro=(slym (slap rig [%cnzy %scry]) old)
|
||||
?~ q.pro ~
|
||||
?~ +.q.pro [~ ~]
|
||||
=+ dat=(slot 7 pro)
|
||||
[~ ~ (mark q.dat) (slot 3 dat)]
|
||||
[~ ~ (mark -.q.dat) +.q.dat]
|
||||
::
|
||||
++ soar :: scrub vane
|
||||
|= sev=vase
|
||||
@ -9720,13 +9729,13 @@
|
||||
|= [vil=vile eny=@ bud=vase niz=(pair worm (list ,[p=@tas q=vase]))]
|
||||
|_ now=@da
|
||||
++ beck
|
||||
^- sled
|
||||
^- slad
|
||||
|= [fur=(unit (set monk)) ron=term bed=beam]
|
||||
^- (unit (unit cage))
|
||||
^- (unit (unit (cask)))
|
||||
=> .(fur ?^(fur fur `[[%& p.bed] ~ ~])) :: XX heinous
|
||||
=+ lal=(end 3 1 ron)
|
||||
=+ ren=(care (rsh 3 1 ron))
|
||||
|- ^- (unit (unit cage))
|
||||
|- ^- (unit (unit (cask)))
|
||||
?~ q.niz ~
|
||||
?. =(lal p.i.q.niz) $(q.niz t.q.niz)
|
||||
%- scry:(wink:(vent lal vil bud p.niz q.i.q.niz) now (shax now) ..^$)
|
||||
@ -9829,7 +9838,7 @@
|
||||
|- ^- [p=(list ovum) q=(pair worm (list ,[p=@tas q=vase]))]
|
||||
?~ mor [(flop ova) niz]
|
||||
=^ nyx niz (jack lac i.mor)
|
||||
$(ova (weld p.nyx ova), mor (weld t.mor q.nyx))
|
||||
$(ova (weld p.nyx ova), mor (weld q.nyx t.mor))
|
||||
--
|
||||
--
|
||||
:::::: ::::::::::::::::::::::::::::::::::::::::::::::::::::::
|
File diff suppressed because it is too large
Load Diff
12
base/cat/helm/merge/gate.hook
Normal file
12
base/cat/helm/merge/gate.hook
Normal file
@ -0,0 +1,12 @@
|
||||
::
|
||||
:::: /hook/gate/merge/helm/cat
|
||||
::
|
||||
/? 314
|
||||
::
|
||||
::::
|
||||
!:
|
||||
|= $: [now=@da eny=@uvI bec=beak]
|
||||
[[syd=@tas her=@p sud=@tas gem=?([?(%auto germ) ~] ~)] ~]
|
||||
==
|
||||
:- %helm-merge
|
||||
[syd her sud ?~(gem %auto -.gem)]
|
15
base/cat/helm/unix/gate.hook
Normal file
15
base/cat/helm/unix/gate.hook
Normal file
@ -0,0 +1,15 @@
|
||||
::
|
||||
:::: /hook/gate/unix/helm/cat
|
||||
::
|
||||
/? 314
|
||||
::
|
||||
::::
|
||||
!:
|
||||
|= $: [now=@da eny=@uvI bec=beak]
|
||||
[[syd=@tas syn=?(~ [? ~])] ~]
|
||||
==
|
||||
:+ %helm-unix
|
||||
syd
|
||||
?~ syn
|
||||
~
|
||||
`-.syn
|
@ -2,11 +2,11 @@
|
||||
:::: /hook/gate/reset/helm/gun
|
||||
::
|
||||
/? 314
|
||||
/- *console
|
||||
/- *sole
|
||||
::
|
||||
::::
|
||||
!:
|
||||
|= $: [now=@da eny=@uvI bec=beak]
|
||||
[~ ~]
|
||||
==
|
||||
(console-so %helm-reset ~)
|
||||
(sole-so %helm-reset ~)
|
@ -10,7 +10,7 @@
|
||||
[~ ~]
|
||||
==
|
||||
%+ sole-so %noun
|
||||
=+ top=`path`/(scot %p p.bec)/arvo/(scot %da now)
|
||||
=+ top=`path`/(scot %p p.bec)/home/(scot %da now)/arvo
|
||||
=+ pax=`path`(weld top `path`[%hoon ~])
|
||||
~& %solid-start
|
||||
=+ gen=(reck pax)
|
@ -144,4 +144,4 @@ input {
|
||||
#ship:focus,
|
||||
input:focus {
|
||||
background-color: #eee;
|
||||
}
|
||||
}
|
@ -32,8 +32,8 @@
|
||||
:: for any sole state +>, obeys
|
||||
::
|
||||
:: =+ [x=(transmute a b) y=(transmute b a)]
|
||||
:: .= (apply:(apply b) x)
|
||||
:: (apply:(apply a) y)
|
||||
:: .= (apply:(apply a) x)
|
||||
:: (apply:(apply b) y)
|
||||
::
|
||||
++ transmute :: dex as after sin
|
||||
|= [sin=sole-edit dex=sole-edit]
|
||||
@ -65,7 +65,7 @@
|
||||
?- -.dex
|
||||
%del ?:((lte p.sin p.dex) dex(p +(p.dex)) dex)
|
||||
%ins ?: =(p.sin p.dex)
|
||||
?:((gth q.sin q.dex) dex dex(p +(p.dex)))
|
||||
?:((lth q.sin q.dex) dex dex(p +(p.dex)))
|
||||
?:((lte p.sin p.dex) dex(p +(p.dex)) dex)
|
||||
==
|
||||
==
|
||||
@ -85,7 +85,8 @@
|
||||
++ inverse :: relative inverse
|
||||
|= ted=sole-edit
|
||||
^- sole-edit
|
||||
=. ted ?.(?=([%mor * ~] ted) ted i.p.ted)
|
||||
:: =. ted ?.(?=([%mor * ~] ted) ted i.p.ted) :: XX why?
|
||||
~| [ted abet]
|
||||
?- -.ted
|
||||
%del [%ins p.ted (snag p.ted buf)]
|
||||
%ins [%del p.ted]
|
||||
@ -102,13 +103,14 @@
|
||||
++ receive :: naturalize event
|
||||
|= sole-change
|
||||
^- [sole-edit sole-share]
|
||||
?> &(=(his.ler his.ven) (lte own.ler own.ven))
|
||||
~| [ler ven]
|
||||
?> &(=(his.ler his.ven) (lte own.ler own.ven))
|
||||
?> |(!=(own.ler own.ven) =(haw (sham buf)) =(haw 0)) :: trust the clock
|
||||
=. leg (scag (sub own.ven own.ler) leg)
|
||||
:: ~? !=(own.ler own.ven) [%miss-leg leg]
|
||||
=+ dat=(transmute [%mor leg] ted)
|
||||
=+ dat=(transmute [%mor (flop leg)] ted)
|
||||
:: ~? !=(~ leg) [%transmute from/ted to/dat ~]
|
||||
:: =- ~& (tufa buf) -
|
||||
[dat abet:(apply(his.ven +(his.ven)) dat)]
|
||||
::
|
||||
++ remit :: conditional accept
|
||||
@ -124,6 +126,7 @@
|
||||
++ transmit :: outgoing change
|
||||
|= ted=sole-edit
|
||||
^- [sole-change sole-share]
|
||||
:: =- ~& (tufa buf) -
|
||||
[[[his.ven own.ven] (sham buf) ted] (commit ted)]
|
||||
::
|
||||
++ transceive :: receive and invert
|
@ -33,7 +33,7 @@ window.urb.req = function(method,url,params,json,cb) {
|
||||
if(res.data.reload)
|
||||
res.reload = res.data.reload
|
||||
} catch(e) {
|
||||
if(urb.wall || true) document.write(this.responseText) // XX
|
||||
if(urb.wall !== false) document.write(this.responseText) // XX
|
||||
err = {
|
||||
message:"Failed to parse JSON",
|
||||
raw:this.responseText
|
20
base/mar/coffee/door.hook
Normal file
20
base/mar/coffee/door.hook
Normal file
@ -0,0 +1,20 @@
|
||||
::
|
||||
:::: /hoon/core/md/pro
|
||||
::
|
||||
/? 314
|
||||
|_ mud=@t
|
||||
++ garb [%down ~]
|
||||
++ grow
|
||||
|%
|
||||
++ mime [/text/coffeescript (taco mud)]
|
||||
--
|
||||
++ grab
|
||||
|%
|
||||
++ mime |=([p=mite q=octs] (,@t q.q))
|
||||
++ noun ,@t
|
||||
--
|
||||
++ grad
|
||||
|%
|
||||
++ sted %mime
|
||||
--
|
||||
--
|
@ -9,6 +9,13 @@
|
||||
==
|
||||
++ hymn ;html:(head:"{psal}" body)
|
||||
--
|
||||
++ grab |% :: convert from
|
||||
++ noun ,@t :: clam from %noun
|
||||
-- --
|
||||
++ grab
|
||||
|% :: convert from
|
||||
++ mime |=([p=mite q=octs] (,@t q.q))
|
||||
++ noun ,@t :: clam from %noun
|
||||
--
|
||||
++ grad
|
||||
|%
|
||||
++ sted %mime
|
||||
--
|
||||
--
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user