Merge remote-tracking branch 'origin/newunix' into test

Conflicts:
	urb/urbit.pill
	urb/zod/ape/hood.hoon
This commit is contained in:
Philip C Monk 2015-06-29 16:04:16 -04:00
commit 811c17a9ac
465 changed files with 790 additions and 614 deletions

View File

@ -4,7 +4,7 @@
::
/? 314
/- *talk, *bit-api
/+ talk, sole, http, mean
/+ talk, sole, http
!:
:::: sivtyv-barnel
:: be sure to have oauth2-code markk

View File

@ -369,7 +369,9 @@
::
++ dy-done :: dialog submit
|= txt=tape
?> ?=(^ pro)
?. ?=(^ pro)
~& %dy-no-prompt
(dy-diff %bel ~)
(dy-slam /dial u.pro !>(txt))
::
++ dy-over :: finish construction
@ -452,7 +454,7 @@
::
++ dy-twig-head :: dynamic state
^- vase
:(slop !>(`our=@p`our.hid) !>(`tym=@da`now.hid) !>(`eny=@uvI`eny.hid))
:(slop !>(`our=@p`our.hid) !>(`now=@da`now.hid) !>(`eny=@uvI`eny.hid))
::
++ dy-made-dial :: dialog product
|= cag=cage
@ -670,6 +672,7 @@
++ peer-sole
|= [pax=path]
^- (quip move +>)
:: ~& [%dojo-peer ost.hid pax]
~? !=(src.hid our.hid) [%dojo-peer-stranger ost.hid src.hid pax]
:: ?> =(src.hid our.hid)
~? (~(has by hoc) ost.hid) [%dojo-peer-replaced ost.hid pax]
@ -689,6 +692,7 @@
++ poke-sole-action
|= [act=sole-action]
^- (quip move +>)
~| [%dojo-poke ost.hid -.act (~(run by hoc) ,~)]
:: ~& [%dojo-poke ost.hid src.hid act]
:: ~? !=(src.hid our.hid) [%dojo-poke ost.hid src.hid]
he-abet:(~(he-type he [ost.hid ~] (~(got by hoc) ost.hid)) act)

View File

@ -71,37 +71,40 @@
++ from-helm (from-lib %helm [..$ ,_abet]:(helm-work))
++ from-kiln (from-lib %kiln [..$ ,_abet]:(kiln-work))
::
++ poke-dill-belt (wrap poke-dill-belt):from-drum
++ poke-helm-init (wrap poke-init):from-helm
++ poke-helm-verb (wrap poke-verb):from-helm
++ poke-helm-send-hi (wrap poke-send-hi):from-helm
++ poke-helm-hi (wrap poke-hi):from-helm
++ poke-hood-link (wrap poke-link):from-drum
++ poke-hood-mass (wrap poke-mass):from-helm
++ poke-hood-sync (wrap poke-sync):from-kiln
++ poke-hood-unsync (wrap poke-unsync):from-kiln
++ poke-hood-unix (wrap poke-unix):from-kiln
++ poke-hood-begin (wrap poke-begin):from-helm
++ poke-hood-invite (wrap poke-invite):from-helm
++ poke-hood-merge (wrap poke-merge):from-kiln
++ poke-hood-reload (wrap poke-reload):from-helm
++ poke-hood-reset (wrap poke-reset):from-helm
++ poke-hood-start (wrap poke-start):from-drum
++ poke-hood-reload-desk (wrap poke-reload-desk):from-helm
++ poke-kiln-cp (wrap poke-cp):from-kiln
++ poke-kiln-rm (wrap poke-rm):from-kiln
++ poke-kiln-mv (wrap poke-mv):from-kiln
++ poke-kiln-schedule (wrap poke-schedule):from-kiln
++ poke-will (wrap poke-will):from-helm
++ init-helm |=([way=wire *] [~ +>])
++ made-kiln (wrap take-made):from-kiln
++ mere-kiln (wrap take-mere):from-kiln
++ mere-kiln-sync (wrap take-mere-sync):from-kiln
++ made-kiln (wrap take-made):from-kiln
++ init-helm |=([way=wire *] [~ +>])
++ note-helm (wrap take-note):from-helm
++ reap-drum-phat (wrap reap-phat):from-drum
++ onto-drum (wrap take-onto):from-drum
++ peer-drum (wrap peer):from-drum
++ poke-dill-belt (wrap poke-dill-belt):from-drum
++ poke-drum-link (wrap poke-link):from-drum
++ poke-drum-start (wrap poke-start):from-drum
++ poke-helm-hi (wrap poke-hi):from-helm
++ poke-helm-init (wrap poke-init):from-helm
++ poke-helm-invite (wrap poke-invite):from-helm
++ poke-helm-mass (wrap poke-mass):from-helm
++ poke-helm-reload (wrap poke-reload):from-helm
++ poke-helm-reload-desk (wrap poke-reload-desk):from-helm
++ poke-helm-reset (wrap poke-reset):from-helm
++ poke-helm-send-hi (wrap poke-send-hi):from-helm
++ poke-helm-verb (wrap poke-verb):from-helm
++ poke-hood-begin (wrap poke-begin):from-helm
++ poke-hood-sync (wrap poke-sync):from-kiln
++ poke-kiln-cp (wrap poke-cp):from-kiln
++ poke-kiln-label (wrap poke-label):from-kiln
++ poke-kiln-merge (wrap poke-merge):from-kiln
++ poke-kiln-mount (wrap poke-mount):from-kiln
++ poke-kiln-mv (wrap poke-mv):from-kiln
++ poke-kiln-rm (wrap poke-rm):from-kiln
++ poke-kiln-schedule (wrap poke-schedule):from-kiln
++ poke-kiln-sync (wrap poke-sync):from-kiln
++ poke-kiln-unmount (wrap poke-unmount):from-kiln
++ poke-kiln-unsync (wrap poke-unsync):from-kiln
++ poke-will (wrap poke-will):from-helm
++ quit-drum-phat (wrap quit-phat):from-drum
++ reap-drum-phat (wrap reap-phat):from-drum
++ woot-helm (wrap take-woot):from-helm
++ writ-kiln-sync (wrap take-writ):from-kiln
--

View File

@ -782,7 +782,7 @@
%_(+> coz [cod coz])
::
++ sh-twig-head ^- vase :: eval data
:(slop !>(`our=@p`our.hid) !>(`tym=@da`now.hid) !>(`eny=@uvI`eny.hid))
:(slop !>(`our=@p`our.hid) !>(`now=@da`now.hid) !>(`eny=@uvI`eny.hid))
::
++ sh-work :: do work
|= job=work
@ -1659,6 +1659,7 @@
?+ -.sep ~&(tr-lost/sep "")
%fat
=+ rem=$(sep q.sep)
?: (gth (lent rem) 60) (trim 62 rem)
=- "{rem} {(trim (sub 60 (lent rem)) -)}"
?+ -.p.sep "..."
%tank ~(ram re %rose [" " `~] +.p.sep)
@ -1682,10 +1683,11 @@
++ peer :: accept subscription
|= [pax=path]
^- [(list move) _+>]
:: ~& [%talk-peer src.hid ost.hid pax]
~? !=(src.hid our.hid) [%peer-talk-stranger src.hid]
:: ~& [%talk-peer src ost pax]
?: ?=([%sole *] pax)
?> =(our.hid src.hid)
?< (~(has by shells) ost.hid)
~? (~(has by shells) ost.hid) [%talk-peer-replaced ost.hid pax]
ra-abet:(~(ra-console ra ost.hid ~) src.hid t.pax)
:: ~& [%talk-peer-data ost.hid src.hid pax]
ra-abet:(~(ra-subscribe ra ost.hid ~) src.hid pax)

View File

@ -1,4 +1,4 @@
!: :: ames (4a), networking
:: :: ames (4a), networking
::
|= pit=vase
=> =~
@ -413,7 +413,7 @@
vix=(bex +((cut 0 [25 2] mag))) :: width of sender
tay=(cut 0 [27 5] mag) :: message type
==
?> =(7 vez)
?> =(0 vez)
?> =(chk (end 0 20 (mug bod)))
:+ [(end 3 wix bod) (cut 3 [wix vix] bod)]
(kins tay)
@ -433,7 +433,7 @@
=+ tay=(ksin q.kec)
%+ mix
%+ can 0
:~ [3 7]
:~ [3 0]
[20 (mug bod)]
[2 yax]
[2 qax]
@ -1018,7 +1018,7 @@
++ gnaw :: gnaw:am
|= [kay=cape ryn=lane pac=rock] :: process packet
^- [p=(list boon) q=fort]
?. =(7 (end 0 3 pac)) [~ fox]
?. =(0 (end 0 3 pac)) [~ fox]
=+ kec=(bite pac)
?: (goop p.p.kec) [~ fox]
?. (~(has by urb.ton.fox) q.p.kec)

View File

@ -1,4 +1,4 @@
:: :: %time, just a timer
:: :: %behn, just a timer
!? 164
!:::
|= pit=vase
@ -12,7 +12,7 @@
== ::
++ broq |* [a=_,* b=_,*] :: brodal skew qeu
(list (sqeu a b)) ::
++ gift gift-time :: out result <-$
++ gift gift-behn :: out result <-$
++ kiss :: in request ->$
$% [%rest p=@da] :: cancel alarm
[%wait p=@da] :: set alarm
@ -161,10 +161,10 @@
q.hic
^- kiss
?: ?=(%soft -.q.hic)
:: ~& [%time-call-soft (,@tas `*`-.p.q.hic)]
:: ~& [%behn-call-soft (,@tas `*`-.p.q.hic)]
((hard kiss) p.q.hic)
?: (~(nest ut -:!>(*kiss)) | p.hic) q.hic
~& [%time-call-flub (,@tas `*`-.q.hic)]
~& [%behn-call-flub (,@tas `*`-.q.hic)]
((hard kiss) q.hic)
==
=^ mof tym
@ -193,7 +193,7 @@
%wegh
:_ tym :_ ~
:^ hen %give %mass
:- %time
:- %behn
:- %|
:~ tym/`tym
==

View File

@ -15,7 +15,6 @@
dom=dome :: desk data
dok=(unit dork) :: outstanding diffs
mer=(map (pair ship desk) mery) :: outstanding merges
syn=? :: sync to unix
== ::
++ gift gift-clay :: out result <-$
++ kiss kiss-clay :: in request ->$
@ -82,6 +81,8 @@
$: fat=(map ship room) :: domestic
hoy=(map ship rung) :: foreign
ran=rang :: hashes
mon=(map term beam) :: mount points
hez=(unit duct) :: sync duct
== ::
++ rede :: universal project
$: lim=@da :: complete to
@ -90,7 +91,6 @@
dom=dome :: revision state
dok=(unit dork) :: outstanding diffs
mer=(map (pair ship desk) mery) :: outstanding merges
syn=? :: sync to unix
== ::
++ rind :: request manager
$: nix=@ud :: request index
@ -101,7 +101,6 @@
== ::
++ room :: fs per ship
$: hun=duct :: terminal duct
hez=(unit duct) :: sync duct
dos=(map desk dojo) :: native desk
== ::
++ rove :: stored request
@ -113,12 +112,12 @@
== ::
++ tage ,[[%tabl p=(list (pair marc marc))] q=vase] :: %tabl gage
++ dork :: diff work
$: del=(list (pair path cage)) :: deletes
$: del=(list path) :: deletes
ink=(list (pair path cage)) :: hoo{n,k}
ins=(unit (list (pair path cage))) :: inserts
dig=(map path cage) :: store diffs
dif=(unit (list (trel path lobe cage))) :: changes
muc=(map path (pair cage cage)) :: store miso
muc=(map path cage) :: store miso
muh=(map path lobe) :: store hashes
mut=(unit (list (trel path lobe cage))) :: mutations
mim=(map path mime) :: mime cache
@ -132,7 +131,7 @@
|%
++ de :: per desk
|= [now=@da hen=duct hun=duct hez=(unit duct)]
|= [[who=@p for=@p] syd=@ta rede ran=rang]
|= [[who=@p for=@p] syd=@ta rede ran=rang mon=(map term beam)]
=* red +<+>-
=| yel=(list ,[p=duct q=gift])
=| byn=(list ,[p=duct q=riot])
@ -226,7 +225,7 @@
?. ?=(%path p.pax)
(mule |.(`~`~|([%expected-path got=p.pax] !!)))
$(tay t.tay, can (~(put by can) ((hard path) q.q.pax) q.i.tay))
::
++ balk :: read and send
|= [hen=duct cay=(unit (each cage lobe)) mun=mood]
^+ +>
@ -283,10 +282,42 @@
fod.u.ref (~(put by fod.u.ref) hen inx)
==
::
++ lynx
|= sun=(unit ,?)
++ must-ergo
|= can=(list path)
^- (map term (pair ,@ud (set path)))
%- mo ^- (list (trel term ,@ud (set path)))
%+ murn (~(tap by mon))
|= [nam=term bem=beam]
^- (unit (trel term ,@ud (set path)))
=- ?~(- ~ `[nam (lent s.bem) (sa -)])
%+ skim can
|= pax=path
&(=(p.bem for) =(q.bem syd) =((flop s.bem) (scag (lent s.bem) pax)))
::
++ mont
|= [pot=term pax=path]
^+ +>
+>.$(syn ?~(sun !syn u.sun))
=+ can=(turn (~(tap by q:(aeon-to-yaki:ze let.dom))) head)
=+ mus=(skim can |=(paf=path =(pax (scag (lent pax) paf))))
?~ mus
+>.$
%_ +>.$
tag
:_ tag
:* hen %pass [%ergoing (scot %p who) syd ~] %f
%exec who [who syd %da now] ~ %tabl
^- (list (pair silk silk))
%+ turn `(list path)`mus
|= a=path
^- (pair silk silk)
:- [%done ~ %path !>(a)]
:+ %cast %mime
=+ (need (need (read-x:ze let.dom a)))
?: ?=(%& -<)
[%done ~ p.-]
(lobe-to-silk:ze a p.-)
==
==
::
++ ease :: release request
^+ .
@ -349,7 +380,6 @@
=+ sar=(lobes-at-path:ze u.nab r.q.rav)
=+ ear=(lobes-at-path:ze top r.q.rav)
=. +>.$
?: =(sar ear) +>.$
(bleb hen u.nab ?:(p.rav ~ `[u.nab top]))
?^ huy
(blub hen)
@ -363,7 +393,6 @@
^+ +>
%= +>
reg ~& %merge-announce reg
:: ?~(hez reg :_(reg [u.hez [%ergo who syd let.dom]]))
:: yel [[hen %note '=' %leaf ~] yel] :: XX do better
==
::
@ -416,7 +445,7 @@
:* %+ turn del
|= [pax=path mis=miso]
?> ?=(%del -.mis)
[pax p.mis]
pax
::
%+ turn ink
|= [pax=path mis=miso]
@ -439,7 +468,7 @@
%+ turn mut
|= [pax=path mis=miso]
?> ?=(%mut -.mis)
[pax p.mis q.mis]
[pax p.mis]
::
~
::
@ -469,9 +498,9 @@
|= [pax=path mis=miso]
^- (unit (pair path mime))
?> ?=(%mut -.mis)
?. ?=(%mime p.q.mis)
?. ?=(%mime p.p.mis)
~
`[pax ((hard mime) q.q.q.mis)]
`[pax ((hard mime) q.q.p.mis)]
==
==
==
@ -507,7 +536,8 @@
|= [pax=path mis=miso]
?> ?=(%mut -.mis)
:- [%done ~ %path -:!>(*path) pax]
[%cast p.p.mis [%done ~ q.mis]]
=+ (lobe-to-mark:ze (~(got by q:(aeon-to-yaki:ze let.dom)) pax))
[%cast - [%done ~ p.mis]]
==
==
::
@ -521,10 +551,11 @@
:- [%diffing (scot %p who) syd (scot %da wen) pax]
:^ %f %exec who :+ [who syd %da wen] ~
^- silk
=+ =+ (slag (dec (lent pax)) pax)
=+ ?~(- %$ i.-)
[%cast - [%done ~ q.mis]]
[%diff [%done ~ p.mis] -]
:+ %diff
(lobe-to-silk:ze pax (~(got by q:(aeon-to-yaki:ze let.dom)) pax))
=+ (slag (dec (lent pax)) pax)
=+ ?~(- %$ i.-)
[%cast - [%done ~ p.mis]]
::
%ins
:- [%casting (scot %p who) syd (scot %da wen) pax]
@ -546,7 +577,7 @@
?> ?=(^ mut.u.dok)
;: welp
^- (list (pair path misu))
(turn del.u.dok |=([pax=path cay=cage] [pax %del cay]))
(turn del.u.dok |=(pax=path [pax %del ~]))
::
^- (list (pair path misu))
(turn ink.u.dok |=([pax=path cay=cage] [pax %ins cay]))
@ -635,7 +666,8 @@
%+ turn cat
|= [pax=path cay=cage]
:- [%done ~ %path -:!>(*path) pax]
[%diff [%done ~ p:(~(got by muc.u.dok) pax)] [%done ~ cay]]
=+ (lobe-to-silk:ze pax (~(got by q:(aeon-to-yaki:ze let.dom)) pax))
[%diff - [%done ~ cay]]
==
::
++ take-mutating
@ -681,7 +713,7 @@
?> ?=(^ mut.u.dok)
;: welp
^- (list (pair path misu))
(turn del.u.dok |=([pax=path cay=cage] [pax %del cay]))
(turn del.u.dok |=(pax=path [pax %del ~]))
::
^- (list (pair path misu))
(turn ink.u.dok |=([pax=path cay=cage] [pax %ins cay]))
@ -716,26 +748,29 @@
=. +>.$ =>(wake ?>(?=(^ dok) .))
:: ~& %checked-out
?~ hez +>.$(dok ~)
?. syn +>.$(dok ~)
=+ ^= ceq
|= a=miso
?| ?=(%del -.a)
&(?=(%ins -.a) ?=(%mime -.+.a))
&(?=(%mut -.a) ?=(%mime -.+>.a))
==
=+ mus=(must-ergo (turn sim head))
?: =(~ mus)
+>.$(dok ~)
=+ ^- sum=(set path)
=+ (turn (~(tap by mus)) (corl tail tail))
%+ roll -
|= [pak=(set path) acc=(set path)]
(~(uni in acc) pak)
=+ can=(mo sim)
:: ~& %forming-ergo
:: =- ~& %formed-ergo -
%_ +>.$
dok ~
tag :: ?~(hez reg :_(reg [u.hez [%ergo who syd let.dom]]))
tag
:_ tag
:* hen %pass [%ergoing (scot %p who) syd ~] %f
%exec who [who syd %da now] ~ %tabl
^- (list (pair silk silk))
%+ turn sim
|= [a=path b=misu]
%+ turn (~(tap in sum))
|= a=path
^- (pair silk silk)
:- [%done ~ %path !>(a)]
=+ b=(~(got by can) a)
?: ?=(%del -.b)
[%done ~ %null !>(~)]
=+ (~(get by mim.u.dok) a)
@ -757,20 +792,26 @@
[[hen %note '!' %rose [" " "" ""] leaf/"clay ergo failed" p.res] yel]
==
?~ hez ~|(%no-sync-duct !!)
?. syn ~|(%sync-off !!)
=+ ^- can=(map path (unit mime))
%- mo ^- mode
%+ turn (gage-to-cages res)
|= [pax=cage mim=cage]
?. ?=(%path p.pax)
~|(%ergo-bad-path-mark !!)
:- ((hard path) q.q.pax)
?. ?=(%mime p.mim)
~
`((hard mime) q.q.mim)
=+ mus=(must-ergo (turn (~(tap by can)) head))
%= +>.$
reg
:_ reg
:* u.hez %ergo who syd let.dom
^- (list ,[path (unit mime)])
%+ turn (gage-to-cages res)
|= [pax=cage mim=cage]
?. ?=(%path p.pax)
~|(%ergo-bad-path-mark !!)
:- ((hard path) q.q.pax)
?. ?=(%mime p.mim)
~
`((hard mime) q.q.mim)
%- welp :_ reg
%+ turn (~(tap by mus))
|= [pot=term len=@ud pak=(set path)]
:* u.hez %ergo pot
%+ turn (~(tap in pak))
|= pax=path
[(slag len pax) (~(got by can) pax)]
==
==
::
@ -825,7 +866,8 @@
=+ let=let
=+ hut=(~(uni by hut.ran) nut)
=+ lat=(~(uni by lat.ran) nat)
=+ =+ yon=`aeon`1 :: sanity check
=+ ?: =(0 let) ~
=+ yon=`aeon`1 :: sanity check
|-
~| yon=yon
=+ tak=(~(got by hit) yon)
@ -1262,6 +1304,9 @@
%+ ~(put by bar) pax
(make-delta p.mys [(lobe-to-mark u.har) u.har] [p q.q]:q.mys)
:: XX check vase !evil
:: XX of course that's a problem, p.u.ber isn't in rang since it
:: was just cretated. We shouldn't be sending multiple
:: diffs
%+ ~(put by bar) pax
(make-delta p.mys [(lobe-to-mark p.u.ber) p.u.ber] [p q.q]:q.mys)
:: XX check vase !evil
@ -1407,6 +1452,8 @@
^- nako
:+ hit.dom
let.dom
?~ =(0 b)
[~ ~]
(data-twixt-takos (~(get by hit.dom) a) (aeon-to-tako b))
::
++ query :: query:ze
@ -2008,7 +2055,6 @@
!!
[%pact (lobe-to-silk pax u.-) [%done ~ u.cay]]
==
::
++ built
|= res=gage
@ -2143,23 +2189,31 @@
=. ank.dom ank.dat
?~ hez
(done:he ~)
?. syn
=+ mus=(must-ergo (turn (~(tap by erg.dat)) head))
?: =(~ mus)
(done:he ~)
ergo
::
++ ergo
^+ .
=- %_(+ tag [- tag])
=+ ^- sum=(set path)
=+ (must-ergo (turn (~(tap by erg.dat)) head))
=+ (turn (~(tap by -)) (corl tail tail))
%+ roll -
|= [pak=(set path) acc=(set path)]
(~(uni in acc) pak)
=+ zez=ze(ank.dom ank.dat)
=+ val=?:(?=(%init gem.dat) ali bob)
:* hen %pass
[%merge (scot %p p.bob) q.bob (scot %p p.ali) q.ali %ergo ~]
%f %exec p.bob [p.val q.val cas.dat] ~ %tabl
^- (list (pair silk silk))
%+ turn (~(tap by erg.dat))
|= [a=path b=?]
%+ turn (~(tap in sum))
|= a=path
^- (pair silk silk)
:- [%done ~ %path !>(a)]
=+ b=(~(got by erg.dat) a)
?. b
[%done ~ %null !>(~)]
:+ %cast %mime
@ -2172,25 +2226,33 @@
=+ tay=(gage-to-tage res)
?: ?=(%| -.tay)
(error:he %ergo-bad-made leaf/"merge ergo failed" p.tay)
=+ =| can=mick
|- ^- tan=$&(mick [p=term q=tang])
?~ p.tay can
=+ =| nac=mode
|- ^- tan=$&(mode [p=term q=tang])
?~ p.tay nac
=* pax p.i.p.tay
?. ?=(%path p.pax)
[%ergo >[%expected-path got=p.pax]< ~]
=* mim q.i.p.tay
=+ mit=?.(?=(%mime p.mim) ~ `((hard mime) q.q.mim))
$(p.tay t.p.tay, can :_(can [((hard path) q.q.pax) mit]))
$(p.tay t.p.tay, nac :_(nac [((hard path) q.q.pax) mit]))
?: ?=([@ *] tan) (error:he tan)
=+ `can=(map path (unit mime))`(mo tan)
?~ hez
(error:he %ergo-no-hez ~)
?. syn
(error:he %ergo-sync-off ~)
?: ?=(%| -.gon.dat)
+>.$
%_ +>.$
don %|
reg [[u.hez %ergo who syd let.dom tan] reg]
reg
=+ mus=(must-ergo (turn (~(tap by erg.dat)) head))
%- welp :_ reg
%+ turn (~(tap by mus))
|= [pot=term len=@ud pak=(set path)]
:* u.hez %ergo pot
%+ turn (~(tap in pak))
|= pax=path
[(slag len pax) (~(got by can) pax)]
==
==
::
++ he
@ -2271,8 +2333,8 @@
?^(rug u.rug *rung)
=+ ^= red ^- rede
=+ yit=(~(get by rus.rug) syd)
?^(yit u.yit `rede`[~2000.1.1 ~ [~ *rind] *dome ~ ~ %|])
((de now hen ~ ~) [who him] syd red ran.ruf)
?^(yit u.yit `rede`[~2000.1.1 ~ [~ *rind] *dome ~ ~])
((de now hen ~ hez.ruf) [who him] syd red ran.ruf mon.ruf)
::
++ posh
|= [him=ship syd=desk red=rede ruf=raft]
@ -2294,7 +2356,7 @@
%_ +>
ran.ruf run
dos.yar
(~(put by dos.yar) syd [qyx.red dom.red dok.red mer.red syn.red])
(~(put by dos.yar) syd [qyx.red dom.red dok.red mer.red])
==
::
++ wake
@ -2311,10 +2373,10 @@
=+ ^= saq ^- dojo
=+ saq=(~(get by dos.yar) syd)
?~(saq *dojo u.saq)
%^ (de now hen hun.yar hez.yar)
%^ (de now hen hun.yar hez.ruf)
[who who]
syd
[[now qyx.saq ~ dom.saq dok.saq mer.saq syn.saq] ran.ruf]
[[now qyx.saq ~ dom.saq dok.saq mer.saq] ran.ruf mon.ruf]
--
--
::::::::::::::::::::::::::::::::::::::::::::::::::::::::
@ -2346,8 +2408,12 @@
==
^- [p=(list move) q=_..^$]
?- -.q.hic
%boat
:_ ..^$
[hen %give %hill (turn (~(tap by mon.ruf)) head)]~
::
%init
:_ ..^$(fat.ruf (~(put by fat.ruf) p.q.hic [hen ~ ~]))
:_ ..^$(fat.ruf (~(put by fat.ruf) p.q.hic [hen ~]))
=+ [bos=(sein p.q.hic) can=(clan p.q.hic)]
%- zing ^- (list (list move))
:~ ?: =(bos p.q.hic) ~
@ -2385,45 +2451,34 @@
[mos ..^$]
::
%into
=+ yar=(~(got by fat.ruf) p.q.hic)
:_ ..^$(fat.ruf (~(put by fat.ruf) p.q.hic yar(hez [~ hen])))
^- (list move)
?: =(%$ q.q.hic)
~
=+ dos=(~(get by dos.yar) q.q.hic)
?: &(?=(^ dos) !=(0 +>-.+<.+.dos)) :: ank.s.u.dos
?: =(ank.dom.u.dos q.q.hic)
~
:_ ~
:* hen %pass / %c %info p.q.hic q.q.hic %&
(khan-to-soba `ank.dom.u.dos `r.q.hic)
=. hez.ruf `hen
:_ ..^$
=+ bem=(~(get by mon.ruf) p.q.hic)
?: &(?=(~ bem) !=(%$ p.q.hic))
~|([%bad-mount-point-from-unix p.q.hic] !!)
=+ ^- bem=beam
?^ bem
u.bem
[[?>(?=(^ fat.ruf) p.n.fat.ruf) %base %ud 1] ~]
=+ rom=(~(got by fat.ruf) p.bem)
=+ dos=(~(got by dos.rom) q.bem)
?: =(0 let.dom.dos)
=+ cos=(mode-to-soba ~ s.bem q.q.hic r.q.hic)
=+ ^- [one=(list ,[path miso]) two=(list ,[path miso])]
%+ skid q.cos
|= [a=path b=miso]
?& ?=(%ins -.b)
?=(%mime p.p.b)
=+ (slag (dec (lent a)) a)
?| =([%hook ~] -)
=([%hoon ~] -)
== ==
:~ [hen %pass /one %c %info p.bem q.bem %& p.cos one]
[hen %pass /two %c %info p.bem q.bem %& p.cos two]
==
=+ cos=(khan-to-soba ~ `r.q.hic)
=+ ^- [one=(list ,[path miso]) two=(list ,[path miso])]
%+ skid q.cos
|= [a=path b=miso]
?& ?=(%ins -.b)
?=(%mime p.p.b)
=+ (slag (dec (lent a)) a)
?| =([%hook ~] -)
=([%hoon ~] -)
== ==
:~ [hen %pass /one %c %info p.q.hic q.q.hic %& p.cos one]
[hen %pass /two %c %info p.q.hic q.q.hic %& p.cos two]
==
::
%lynx
?: =(%$ q.q.hic)
[~ ..^$]
=^ mos ruf
=+ une=(un p.q.hic now hen ruf)
=+ ^= zat
(lynx:(di:wake:une q.q.hic) r.q.hic)
=+ zot=abet.zat
:- -.zot
=. une (pish:une q.q.hic +.zot ran.zat)
abet:une
[mos ..^$]
=+ yak=(~(got by hut.ran.ruf) (~(got by hit.dom.dos) let.dom.dos))
=+ cos=(mode-to-soba q.yak (flop s.bem) q.q.hic r.q.hic)
[hen %pass / %c %info p.bem q.bem %& cos]~
::
%merg :: direct state up
?: =(%$ q.q.hic)
@ -2437,6 +2492,47 @@
=. une (pish:une q.q.hic +.zot ran.zat)
abet:une
[mos ..^$]
::
%mont
=. hez.ruf ?^(hez.ruf hez.ruf `[[%$ %sync ~] ~])
=+ pot=(~(get by mon.ruf) p.q.hic)
?^ pot
~& [%already-mounted pot]
[~ ..^$]
=. mon.ruf
(~(put by mon.ruf) p.q.hic [q.q.hic r.q.hic %ud 0] (flop s.q.hic))
=+ yar=(~(get by fat.ruf) q.q.hic)
?~ yar
[~ ..^$]
=+ dos=(~(get by dos.u.yar) r.q.hic)
?~ dos
[~ ..^$]
=+ une=(un q.q.hic now hen ruf)
=+ wex=(di:une r.q.hic)
=+ wao=(mont:wex p.q.hic s.q.hic)
=+ woo=abet:wao
[-.woo ..^$(ruf abet:(pish:une r.q.hic +.woo ran.wao))]
::
%ogre
?~ hez.ruf
~& %no-sync-duct
[~ ..^$]
?@ p.q.hic
?. (~(has by mon.ruf) p.q.hic)
~& [%not-mounted p.q.hic]
[~ ..^$]
:_ ..^$(mon.ruf (~(del by mon.ruf) p.q.hic))
[u.hez.ruf %give %ogre p.q.hic]~
:_ %_ ..^$
mon.ruf
%- mo
%+ skip (~(tap by mon.ruf))
(corl (cury test p.q.hic) tail)
==
%+ turn
(skim (~(tap by mon.ruf)) (corl (cury test p.q.hic) tail))
|= [pot=term bem=beam]
[u.hez.ruf %give %ogre pot]
::
%warp
=^ mos ruf
@ -2727,71 +2823,43 @@
^- rand
[p q [p q.q]:r]
::
:: XX perhaps fil.khan should be (unit (unit mime)) and !>
++ khan-to-soba
|= [ank=(unit ankh) kan=(unit khan)]
++ mode-to-soba
|= [hat=(map path lobe) pax=path all=? mod=mode]
^- soba
:- *cart
=| pax=path
:: =- ~& [%khan (turn - |=((pair path miso) [p -.q]))] -
|- ^- (list ,[p=path q=miso])
?~ ank
?~ kan
:: ~& [pax %ank-kan-sig]
%+ welp
^- (list (pair path miso))
?. all
~
:: ~& [pax %ank-sig]
=+ ?~ dir.u.kan
~
=+ (~(tap by u.dir.u.kan))
:: ~& [%dirukan pax=pax (~(run by u.dir.u.kan) (cury test ~))]
|- ^- (list (pair path miso))
?~ +< ~
?~ q.i $(+< t)
(weld ^$(pax [p.i pax], kan `u.q.i) $(+< t))
?~ fil.u.kan
-
?~ u.fil.u.kan
-
:: ~& [pax %ins-1]
[[(flop pax) %ins u.u.fil.u.kan] -]
?~ kan
:: ~& [pax %kan-sig]
=+ =+ (~(tap by r.u.ank))
|-(?~(+< ~ (weld ^$(pax [p.i pax], ank `q.i) $(+< t))))
?~ q.u.ank
-
[[(flop pax) %del q.u.q.u.ank] -]
:: ~& [pax %neither-sig]
=+ ?~ dir.u.kan
~
%+ weld
=+ (~(tap by r.u.ank))
|- ^- (list ,[p=path q=miso])
?~ +< ~
=+ (~(get by u.dir.u.kan) p.i)
?: ?=([~ ~] -) $(+< t)
%- weld :_ $(+< t)
:: ~& [pax %ankhing p.i ?=(~ -)]
^$(pax [p.i pax], ank `q.i, kan ?~(- ~ `u.u.-))
=+ (~(tap by u.dir.u.kan))
:: ~& [%sdirukan pax=pax (~(run by dir.u.kan) (cury test ~))]
|- ^- (list ,[p=path q=miso])
?~ +< ~
?~ q.i $(+< t)
?: (~(has by r.u.ank) p.i) $(+< t)
:: ~& [pax %khaning p.i]
%- weld :_ $(+< t)
^$(pax [p.i pax], kan `u.q.i, ank ~)
?~ q.u.ank
?~ fil.u.kan
-
?~ u.fil.u.kan
-
:: ~& %ins-2
[[(flop pax) %ins u.u.fil.u.kan] -]
?~ fil.u.kan
-
?~ u.fil.u.kan
[[(flop pax) %del q.u.q.u.ank] -]
[[(flop pax) %mut q.u.q.u.ank u.u.fil.u.kan] -]
=+ mad=(mo mod)
=+ len=(lent pax)
=+ ^- descendants=(list path)
%+ turn
%+ skim (~(tap by hat))
|= [paf=path lob=lobe]
=(pax (scag len paf))
|= [paf=path lob=lobe]
(slag len paf)
%+ murn
descendants
|= pat=path
^- (unit (pair path ,[%del ~]))
?: (~(has by mad) pat)
~
`[(weld pax pat) %del ~]
^- (list (pair path miso))
%+ murn mod
|= [pat=path mim=(unit mime)]
^- (unit (pair path miso))
=+ paf=(weld pax pat)
?~ mim
=+ (~(get by hat) paf)
?~ -
~& [%deleting-already-gone pax pat]
~
`[paf %del ~]
=+ (~(get by hat) paf)
?~ -
`[paf %ins %mime -:!>(*mime) u.mim]
`[paf %mut %mime -:!>(*mime) u.mim]
--

View File

@ -1,4 +1,4 @@
!:
::
:: dill (4d), terminal handling
::
|= pit=vase

View File

@ -1,4 +1,4 @@
!: :: %eyre, http servant
:: :: %eyre, http servant
!? 164
::::
|= pit=vase
@ -10,6 +10,10 @@
++ note :: out request $->
$% $: %a :: to %ames
$% [%wont p=sock q=[path *]] ::
== == ::
$: %b :: to %behn
$% [%wait p=@da] ::
[%rest p=@da] ::
== == ::
$: %d :: to %dill
$% [%flog p=[%crud p=@tas q=(list tank)]] ::
@ -24,14 +28,13 @@
== == ::
$: %g :: to %gall
$% [%deal p=sock q=cush] :: full transmission
== == ::
$: %t :: to %temp
$% [%wait p=@da] ::
[%rest p=@da] ::
== == == ::
++ sign :: in result $<-
$? $: %a :: by %ames
$% [%woot p=ship q=coop] ::
== == ::
$: %b :: by %behn
$% [%wake ~] :: timer activate
== == ::
$: %g :: by %gall
$% [%unto p=cuft] :: within agent
@ -42,9 +45,6 @@
$: %f :: by %ford
$% [%made p=@uvH q=gage] ::
[%news ~] ::
== == ::
$: %t :: by %time
$% [%wake ~] :: timer activate
== == ::
$: @tas :: by any
$% [%crud p=@tas q=(list tank)] ::
@ -414,7 +414,7 @@
return urb.redir($ship.text().toLowerCase()) // XX redundant?
req(
"/~/auth.json?PUT",
{ship:ship.innerText.toLowerCase(), code:pass.value},
{ship:$ship.text().toLowerCase(), code:pass.value},
function(){
if(urb.foreign) urb.redir()
else document.location.reload()
@ -1399,7 +1399,7 @@
=< abet
?~ ude done
=. hen p.u.ude
=. ..ix (pass-note of//[ire] [%t %rest era])
=. ..ix (pass-note of//[ire] [%b %rest era])
(give-even(ude ~) q.u.ude num ven)
::
++ give-even
@ -1428,7 +1428,7 @@
?: =(a p.eve)
?^ 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])
(pass-note:abet(ude [~ hen &]) of//[ire] [%b %wait era])
?: (gth a p.eve) ~|(seq-high/cur=p.eve !!)
=+ ven=~|(seq-low/cur=p.eve (~(got by q.eve) a))
abet:(give-even & a ven)

View File

@ -1,4 +1,4 @@
!:::::
::::::
:: :: %ford, new execution control
!? 164
::::
@ -156,6 +156,14 @@
=+ gib=(wox p.n.r.arc)
?~(gib rac [[u.gib p.n.r.arc] rac])
::
++ tack :: fold path to term
|= a=[i=term t=(list term)] ^- term
(rap 3 |-([i.a ?~(t.a ~ ['-' $(a t.a)])]))
::
++ tear :: split term
=- |=(a=term (rush a (most hep sym)))
sym=(cook crip ;~(plug low (star ;~(pose low nud))))
::
++ norm :: normalize beam rev
|= [ska=sled bem=beam]
%_ bem
@ -368,9 +376,9 @@
==
::
++ cool :: error caption
|* [cyt=trap hoc=(bolt)]
|* [cyt=$|(term trap) hoc=(bolt)]
?. ?=(%2 -.q.hoc) hoc
[p.hoc [%2 p.q.hoc *cyt q.q.hoc]]
[p.hoc [%2 p.q.hoc ?^(cyt *cyt [>`@tas`cyt<]~) q.q.hoc]]
::
++ cope :: bolt along
|* [hoc=(bolt) fun=(burg)]
@ -386,6 +394,21 @@
%0 [%0 p=(grom `_p.q.nuf`p.q.hoc p.q.nuf) q=q.q.nuf]
== ==
::
++ coop :: bolt alter
|* [hoc=(bolt) fun=(burg)]
?- -.q.hoc
%1 hoc
%0 hoc
%2 =+ nuf=(fun(+<- p.hoc))
:- p=p.nuf
^= q
?- -.q.nuf
%1 q.nuf
%0 [%0 p=(grom `_p.q.nuf`p.q.hoc p.q.nuf) q=q.q.nuf]
%2 =. q.q.nuf (welp q.q.nuf q.q.hoc)
[%2 p=(grom `_p.q.nuf`p.q.hoc p.q.nuf) q=q.q.nuf]
== ==
::
++ coup :: toon to bolt
|= cof=cafe
|* [ton=toon fun=$+(* *)]
@ -951,23 +974,35 @@
^- (burg beak (jug mark mark))
|= [cof=cafe bek=beak]
=. ^bek bek
%+ cope (lend cof [bek /mar])
|= [cof=cafe arc=arch]
:: =- =+((cope - |=([cafe lil=(jug mark mark)] ~&(lil=lil (flue cof)))) +<)
=+ all=(~(tap by r.arc))
|- ^- (bolt (jug mark mark))
?~ all (flue cof)
%+ cope $(cof cof, all t.all)
|= [cof=cafe lil=(jug mark mark)]
=* for p.i.all
=+ raf=(fang cof for)
?: ?=(%2 -.q.raf)
=. q.q.raf :_(q.q.raf leaf/"! {<`mark`for>} build failed, ignoring.")
((slog 0 (flop q.q.raf)) (fine cof lil))
%+ cope `(bolt vase)`raf
|= [cof=cafe vax=vase]
%+ cope
=| sup=path
|- ^- (bolt (list ,[mark vase]))
%+ cope (lend cof [bek (welp sup /mar)])
|= [cof=cafe arc=arch]
=+ all=(skim (turn (~(tap by r.arc)) head) (sane %tas))
|- ^- (bolt (list ,[mark vase]))
?~ all (fine cof ~)
%+ cope $(all t.all)
|= [cof=cafe dep=(list ,[mark vase])]
%+ cope ^^^$(cof cof, sup [i.all sup])
|= [cof=cafe wid=(list ,[mark vase])] ^- (bolt (list ,[mark vase]))
=+ [res=(weld wid dep) pax=(flop sup)]
?~ pax (fine cof res)
?. (~(has by r.arc) %hoon) (fine cof res)
=+ :- sil=[%core (norm ska bek (welp sup /mar))]
for=(rap 3 |-([i.pax ?~(t.pax ~ ['-' $(pax t.pax)])]))
=+ raf=(;~(cope make furl feel) cof sil)
?: ?=(%2 -.q.raf)
=- ((slog 0 (flop `tang`-)) (fine cof res))
?^ t.pax ~ :: error on top-level marks
:_(q.q.raf leaf/"! {<`mark`for>} build failed, ignoring.")
(cope `(bolt vase)`raf (flux |=(vax=vase [[for vax] res])))
|= [cof=cafe all=(list ,[mark vase])] ^- (bolt (jug mark mark))
%+ fine cof
%- ~(gas ju lil)
|- ^- (jug mark mark)
?~ all ~
%- ~(gas ju $(all t.all))
=+ [for vax]=i.all
~| weg=(jam 3 p.vax)
%+ weld
^- (list ,[mark mark])
@ -1171,8 +1206,19 @@
::
%core
%+ cool |.(leaf/"ford: core {<(tope p.kas)>}")
%+ cope (cope (fade cof %hoon p.kas) abut:(meow p.kas ~))
(flux |=(cor=vase [%& %core cor]))
%- cope :_ (flux |=(cor=vase [%& %core cor]))
=+ bem=p.kas
?~ s.bem (cope (fade cof %hoon bem) abut:(meow bem ~))
=+ opt=`(list term)`(fall (tear i.s.bem) ~)
?~ opt (cope (fade cof %hoon bem) abut:(meow bem ~))
|- ^- (bolt vase)
=. i.s.bem (tack opt)
%+ coop (cope (fade cof %hoon bem) abut:(meow bem ~))
|= [cof=cafe ~] ^- (bolt vase)
?~ t.opt (flaw cof ~)
%+ coop ^$(cof cof, opt t.opt, t.s.bem :_(t.s.bem i.opt))
|= [cof=cafe ~] ^- (bolt vase)
^$(cof cof, opt :_(t.t.opt (tack i.opt i.t.opt ~)))
::
%diff
%+ cool |.(leaf/"ford: diff {<`@p`(mug p.kas)>} {<`@p`(mug q.kas)>}")
@ -1454,6 +1500,7 @@
%see
=. r.p.hon ?:(?=([%ud 0] r.p.hon) r.how r.p.hon)
$(hon q.hon, how p.hon)
::
%saw
%+ cope $(hon q.hon)
|= [cof=cafe sam=vase]
@ -1684,7 +1731,7 @@
::
++ load :: highly forgiving
|= old=axle
=. pol.old (~(run by pol.old) |=(baby +<(jav ~)))
::=. pol.old (~(run by pol.old) |=(baby +<(jav ~)))
..^$(+>- old)
::=. old
:: ?. ?=([%0 *] old) old :: remove at 1

View File

@ -29,8 +29,14 @@
-- ::
|% :::::::::::::::::::::::::::::::::::::::::::::::::::::: %gall state
::::::::::::::::::::::::::::::::::::::::::::::::::::::
++ axle-n ?(axle axle-0) :: upgrade path
++ axle-0 ,[%0 pol=(map ship mast-0)] ::
++ mast-0 ::
(cork mast |=(mast +<(bum (~(run by bum) seat-0)))) ::
++ seat-0 ::
(cork seat |=(seat +<(|7 zam=(scar |7.+<)))) ::
++ axle :: all state
$: %0 :: state version
$: %1 :: state version
pol=(map ship mast) :: apps by ship
== ::
++ gest :: subscriber data
@ -67,6 +73,7 @@
ged=gest :: subscribers
hav=vase :: running state
byk=beak :: update control
pyl=(map bone mark) :: req'd translations
zam=scar :: opaque ducts
== ::
++ sofa :: queue for blocked
@ -313,24 +320,16 @@
(mo-boon i.t.pax (mo-chew t.t.pax) +>.sih)
::
%pel :: translated peer
?> ?=([@ @ ~] t.pax)
=+ :* mar=i.t.pax
dap=i.t.t.pax
==
?: ?=([%f %made *] sih)
?- -.q.+.sih
%tabl ~|(%made-tabl !!)
%& (mo-give %unto %diff p.q.+>.sih)
%| =. p.q.+>.sih (turn p.q.+>.sih |=(a=tank rose/[~ "! " ~]^[a]~))
~> %slog.`%*(. >[%wh %y]< +> [>%mo-cyst-fail< (flop p.q.+>.sih)])
(mo-give %unto %quit ~) :: XX better errors pls
==
?> ?=([%g %unto *] sih)
?. ?=(%diff -.+>.sih)
(mo-give %unto +>.sih)
%+ mo-pass
[%sys pax]
[%f %exec our (mo-beak dap) ~ %cast mar %done ~ `cage`+>+.sih]
?> ?=([@ ~] t.pax)
=+ mar=i.t.pax
?> ?=([%f %made *] sih)
?- -.q.+.sih
%tabl ~|(%made-tabl !!)
%& (mo-give %unto %diff p.q.+>.sih)
%| =. p.q.+>.sih (turn p.q.+>.sih |=(a=tank rose/[~ "! " ~]^[a]~))
~> %slog.`%*(. >[%wh %y]< +> [>%mo-cyst-fail< (flop p.q.+>.sih)])
(mo-give %unto %quit ~) :: XX better errors pls
==
::
%red :: diff ack
?> ?=([@ @ @ ~] t.pax)
@ -437,7 +436,7 @@
%& ap-abet:(ap-pout:pap t.t.t.pax %diff +.q.+>.q.hin)
%| =+ why=p.q.+>.q.hin
=. why (turn why |=(a=tank rose/[~ "! " ~]^[a]~))
~> %slog.`%*(. >[%wh %y]< +> [>%mo-cook-fail< (flop why)])
~> %slog.`rose/[" " "[" "]"]^[>%mo-cook-fail< (flop why)]
~& [him=q.q.pry our=our pax=pax]
::
:: here we should crash because the right thing
@ -493,10 +492,6 @@
%+ mo-pass
[%sys %val (scot %p q.q.pry) dap ~]
[%f %exec our (mo-beak dap) ~ %cast p.cub %done ~ q.cub]
?: ?=(%peel -.cub)
%+ mo-pass
[%sys %pel p.cub dap ~]
[%g %deal [q.q.pry our] dap %peer q.cub]
ap-abet:(ap-club:(ap-abed:ap dap pry) cub)
::
++ mo-club :: local action
@ -596,7 +591,17 @@
:- (~(got by r.zam) p.cov)
?- -.q.cov
?(%slip %sick) !!
%give ?<(=(0 p.cov) [%give %unto p.q.cov])
%give
?< =(0 p.cov)
?. ?=(%diff -.p.q.cov)
[%give %unto p.q.cov]
=+ cay=`cage`p.p.q.cov
=+ mar=(fall (~(get by pyl) p.cov) p.cay)
?: =(mar p.cay) [%give %unto p.q.cov]
:+ %pass
[%sys %pel dap ~]
[%f %exec our (mo-beak dap) ~ %cast mar %done ~ cay]
::
%pass
:+ %pass `path`[%use dap p.q.cov]
?- -.q.q.cov
@ -623,7 +628,7 @@
|= cub=club
^+ +>
?- -.cub
%peel !!
%peel (ap-peel +.cub)
%poke (ap-poke +.cub)
%peer (ap-peer +.cub)
%puff !!
@ -884,6 +889,11 @@
^+ +>
(ap-prep(hav vax) `hav)
::
++ ap-peel
|= [mar=mark pax=path]
=. pyl (~(put by pyl) ost mar)
(ap-peer pax)
::
++ ap-peer :: apply %peer
|= pax=path
^+ +>
@ -923,13 +933,15 @@
=+ cug=(ap-find /lame)
?~ cug
=. why [>%ap-lame dap wut< (turn why |=(a=tank rose/[~ "! " ~]^[a]~))]
~> %slog.`%*(. >[%wh %y]< +> (flop why))
~> %slog.`rose/[" " "[" "]"]^(flop why)
+>.$
=^ cam +>.$
%+ ap-call q.u.cug
!>([wut why])
?^ cam
~&([%ap-lame-lame u.cam] +>.$)
=. why [>%ap-lame-lame< (turn u.cam |=(a=tank rose/[~ "! " ~]^[a]~))]
~> %slog.`rose/[" " "[" "]"]^(welp (flop why) leaf/"." (flop u.cam))
+>.$
+>.$
::
++ ap-pour :: generic take
@ -1109,10 +1121,11 @@
%exec `%f
%flog `%d
%info `%c
%lynx `%c
%merg `%c
%mont `%c
%ogre `%c
%them `%e
%wait `%t
%wait `%b
%want `%a
%wont `%a :: XX for begin; remove
%warp `%c
@ -1172,9 +1185,14 @@
~
::
++ load :: recreate vane
|= old=axle
|= old=axle-n
^+ ..^$
..^$(all old)
?: ?=(%1 -.old) ..^$(all old)
%= $
old => |=(seat-0 `seat`+<(zam [~ zam]))
=> |=(mast-0 +<(bum (~(run by bum) +>)))
old(- %1, pol (~(run by pol.old) .))
==
::
++ scry
|= [fur=(unit (set monk)) ren=@tas who=ship syd=desk lot=coin tyl=path]

View File

@ -1468,7 +1468,6 @@
?: (nan b n) [~ n]
?: (nan b m) [~ m]
~
++ pro |= [b=@u p=@u n=[s=? e=@s a=@u]]
^- [s=? e=@s a=@u]
=+ maxexp=`@s`(^mul 2 +(b))
@ -1478,7 +1477,6 @@
?: &(=(1 (mod e.n 2)) (^gte e.n minexp))
(szer:vl:fl b p s.n) :: flush denorms
n
++ err |= [b=@u p=@u n=[s=? e=@s a=@u]]
^- (unit tape)
?: (snan b n) [~ "snan"]
@ -5004,7 +5002,7 @@
--
~% %ed + ~
|%
++ puck :: public key
++ puck :: public key
~/ %puck
|= sk=@I ^- @
?: (gth (met 3 sk) 32) !!
@ -5015,12 +5013,12 @@
(lsh 0 3 (cut 0 [3 (sub b 5)] h))
=+ aa=(scam bb a)
(etch aa)
++ suck :: keypair from seed
++ suck :: keypair from seed
|= se=@I ^- @uJ
=+ pu=(puck se)
(can 0 ~[[b se] [b pu]])
::
++ sign :: certify
++ sign :: certify
~/ %sign
|= [m=@ se=@] ^- @
=+ sk=(suck se)
@ -5050,7 +5048,7 @@
(~(sit fo l) (add r (mul (shaz ha) a)))
(can 0 ~[[b (etch rr)] [b ss]])
::
++ veri :: validate
++ veri :: validate
~/ %veri
|= [s=@ m=@ pk=@] ^- ?
?: (gth (div b 4) (met 3 s)) |
@ -5070,189 +5068,185 @@
++ scr :: scrypt
~% %scr + ~
|%
++ sal |= [x=@ r=@] :: salsa20 hash
?> =((mod r 2) 0) :: with r rounds
=+ few==>(fe .(a 5))
=+ ^= rot
|= [a=@ b=@]
(mix (end 5 1 (lsh 0 a b)) (rsh 0 (sub 32 a) b))
=+ ^= lea
|= [a=@ b=@]
(net:few (sum:few (net:few a) (net:few b)))
=> |% ++ qr :: quarterround
|= y=[@ @ @ @ ~]
=+ zb=(mix &2.y (rot 7 (sum:few &1.y &4.y)))
=+ zc=(mix &3.y (rot 9 (sum:few zb &1.y)))
=+ zd=(mix &4.y (rot 13 (sum:few zc zb)))
=+ za=(mix &1.y (rot 18 (sum:few zd zc)))
~[za zb zc zd]
++ rr :: rowround
|= [y=(list ,@)]
=+ za=(qr ~[&1.y &2.y &3.y &4.y])
=+ zb=(qr ~[&6.y &7.y &8.y &5.y])
=+ zc=(qr ~[&11.y &12.y &9.y &10.y])
=+ zd=(qr ~[&16.y &13.y &14.y &15.y])
^- (list ,@) :~
&1.za &2.za &3.za &4.za
&4.zb &1.zb &2.zb &3.zb
&3.zc &4.zc &1.zc &2.zc
&2.zd &3.zd &4.zd &1.zd
==
++ cr :: columnround
|= [x=(list ,@)]
=+ ^= y %- rr ^- (list ,@) :~
&1.x &5.x &9.x &13.x
&2.x &6.x &10.x &14.x
&3.x &7.x &11.x &15.x
&4.x &8.x &12.x &16.x
==
^- (list ,@) :~
&1.y &5.y &9.y &13.y
&2.y &6.y &10.y &14.y
&3.y &7.y &11.y &15.y
&4.y &8.y &12.y &16.y
==
++ dr :: doubleround
|= [x=(list ,@)]
(rr (cr x))
++ al :: add two lists
|= [a=(list ,@) b=(list ,@)]
|- ^- (list ,@)
?~ a ~ ?~ b ~
[i=(sum:few -.a -.b) t=$(a +.a, b +.b)]
--
=+ xw=(rpp 5 16 x)
=+ ^= ow |- ^- (list ,@)
?~ r xw
$(xw (dr xw), r (sub r 2))
(rep 5 (al xw ow))
++ sal
|= [x=@ r=@] :: salsa20 hash
?> =((mod r 2) 0) :: with r rounds
=+ few==>(fe .(a 5))
=+ ^= rot
|= [a=@ b=@]
(mix (end 5 1 (lsh 0 a b)) (rsh 0 (sub 32 a) b))
=+ ^= lea
|= [a=@ b=@]
(net:few (sum:few (net:few a) (net:few b)))
=> |%
++ qr :: quarterround
|= y=[@ @ @ @ ~]
=+ zb=(mix &2.y (rot 7 (sum:few &1.y &4.y)))
=+ zc=(mix &3.y (rot 9 (sum:few zb &1.y)))
=+ zd=(mix &4.y (rot 13 (sum:few zc zb)))
=+ za=(mix &1.y (rot 18 (sum:few zd zc)))
~[za zb zc zd]
++ rr :: rowround
|= [y=(list ,@)]
=+ za=(qr ~[&1.y &2.y &3.y &4.y])
=+ zb=(qr ~[&6.y &7.y &8.y &5.y])
=+ zc=(qr ~[&11.y &12.y &9.y &10.y])
=+ zd=(qr ~[&16.y &13.y &14.y &15.y])
^- (list ,@) :~
&1.za &2.za &3.za &4.za
&4.zb &1.zb &2.zb &3.zb
&3.zc &4.zc &1.zc &2.zc
&2.zd &3.zd &4.zd &1.zd ==
++ cr :: columnround
|= [x=(list ,@)]
=+ ya=(qr ~[&1.x &5.x &9.x &13.x])
=+ yb=(qr ~[&6.x &10.x &14.x &2.x])
=+ yc=(qr ~[&11.x &15.x &3.x &7.x])
=+ yd=(qr ~[&16.x &4.x &8.x &12.x])
^- (list ,@) :~
&1.ya &4.yb &3.yc &2.yd
&2.ya &1.yb &4.yc &3.yd
&3.ya &2.yb &1.yc &4.yd
&4.ya &3.yb &2.yc &1.yd ==
++ dr :: doubleround
|= [x=(list ,@)]
(rr (cr x))
++ al :: add two lists
|= [a=(list ,@) b=(list ,@)]
|- ^- (list ,@)
?~ a ~ ?~ b ~
[i=(sum:few -.a -.b) t=$(a +.a, b +.b)]
--
=+ xw=(rpp 5 16 x)
=+ ^= ow |- ^- (list ,@)
?~ r xw
$(xw (dr xw), r (sub r 2))
(rep 5 (al xw ow))
::
++ rpp |= [a=bloq b=@ c=@] :: rip w/filler blocks
=+ q=(rip a c)
=+ w=(lent q)
?. =(w b)
?. (lth w b) (slag (sub w b) q)
^+ q (weld q (reap (sub b (lent q)) 0))
q
++ rpp
|= [a=bloq b=@ c=@] :: rip w/filler blocks
=+ q=(rip a c)
=+ w=(lent q)
?. =(w b)
?. (lth w b) (slag (sub w b) q)
^+ q (weld q (reap (sub b (lent q)) 0))
q
::
++ xrl |= [a=(list ,@) b=(list ,@)] :: xor lists
|- ^- (list ,@)
?~ a b ?~ b a
[i=(mix -.a -.b) t=$(a +.a, b +.b)]
++ bls
|= [a=@ b=(list ,@)] :: split to sublists
?> =((mod (lent b) a) 0)
|- ^- (list (list ,@))
?~ b ~
[i=(scag a `(list ,@)`b) t=$(b (slag a `(list ,@)`b))]
::
++ xrm |= [a=(list (list ,@)) b=(list (list ,@))]
|- ^- (list (list ,@))
?~ a b ?~ b a
[i=(xrl -.a -.b) t=$(a +.a, b +.b)]
++ slb
|= [a=(list (list ,@))]
|- ^- (list ,@)
?~ a ~
(weld `(list ,@)`-.a $(a +.a))
::
++ bls |= [a=@ b=(list ,@)] :: split to sublists
?> =((mod (lent b) a) 0)
|- ^- (list (list ,@))
?~ b ~
[i=(scag a `(list ,@)`b) t=$(b (slag a `(list ,@)`b))]
++ sbm
|= [r=@ b=(list ,@)] :: scryptBlockMix
?> =((lent b) (mul 2 r))
=+ [x=(snag (dec (mul 2 r)) b) c=0]
=| [ya=(list ,@) yb=(list ,@)]
|- ^- (list ,@)
?~ b (flop (weld yb ya))
=. x (sal (mix x -.b) 8)
?~ (mod c 2)
$(c +(c), b +.b, ya [i=x t=ya])
$(c +(c), b +.b, yb [i=x t=yb])
::
++ slb |= [a=(list (list ,@))]
|- ^- (list ,@)
?~ a ~
(weld `(list ,@)`-.a $(a +.a))
++ srm
|= [r=@ b=(list ,@) n=@] :: scryptROMix
?> ?& =((lent b) (mul 2 r))
=(n (bex (dec (xeb n))))
(lth n (bex (mul r 16)))
==
=+ [v=*(list (list ,@)) c=0]
=. v
|- ^- (list (list ,@))
=+ w=(sbm r b)
?: =(c n) (flop v)
$(c +(c), v [i=[b] t=v], b w)
=+ x=(sbm r (snag (dec n) v))
|- ^- (list ,@)
?: =(c n) x
=+ q=(snag (dec (mul r 2)) x)
=+ z=`(list ,@)`(snag (mod q n) v)
=+ ^= w |- ^- (list ,@)
?~ x ~ ?~ z ~
[i=(mix -.x -.z) t=$(x +.x, z +.z)]
$(x (sbm r w), c +(c))
::
++ sbm |= [r=@ b=(list ,@)] :: scryptBlockMix
?> =((lent b) (mul 2 r))
=+ [x=(snag (dec (mul 2 r)) b) c=0]
=| [ya=(list ,@) yb=(list ,@)]
|- ^- (list ,@)
?~ b (flop (weld yb ya))
=. x (sal (mix x -.b) 8)
?~ (mod c 2)
$(c +(c), b +.b, ya [i=x t=ya])
$(c +(c), b +.b, yb [i=x t=yb])
++ hmc
|= [k=@ t=@] :: HMAC-SHA-256
(hml k (met 3 k) t (met 3 t))
::
++ srm |= [r=@ b=(list ,@) n=@] :: scryptROMix
?> ?&
=((lent b) (mul 2 r))
=(n (bex (dec (xeb n))))
(lth n (bex (mul r 16)))
==
=| v=(list (list ,@))
=+ c=0
=. v
|- ^- (list (list ,@))
=+ w=(sbm r b)
?: =(c n) (flop v)
$(c +(c), v [i=[b] t=v], b w)
=+ x=(sbm r (snag (dec n) v))
|- ^- (list ,@)
?: =(c n) x
=+ q=(snag (dec (mul r 2)) x)
$(x (sbm r (xrl x (snag (mod q n) v))), c +(c))
::
++ hmc |= [k=@ t=@] :: HMAC-SHA-256
(hml k (met 3 k) t (met 3 t))
::
++ hml |= [k=@ kl=@ t=@ tl=@] :: w/length
=. k (end 3 kl k) =. t (end 3 tl t)
=+ b=64
=. k ?. (gth kl b) k (shay kl k)
=+ ^= q %+ shay (add b tl)
(add (lsh 3 b t) (mix k (fil 3 b 0x36)))
%+ shay (add b 32)
(add (lsh 3 b q) (mix k (fil 3 b 0x5c)))
++ hml
|= [k=@ kl=@ t=@ tl=@] :: w/length
=> .(k (end 3 kl k), t (end 3 tl t))
=+ b=64
=. k ?. (gth kl b) k (shay kl k)
=+ ^= q %+ shay (add b tl)
(add (lsh 3 b t) (mix k (fil 3 b 0x36)))
%+ shay (add b 32)
(add (lsh 3 b q) (mix k (fil 3 b 0x5c)))
::
++ pbk ~/ %pbk :: PBKDF2-HMAC-SHA256
|= [p=@ s=@ c=@ d=@]
(pbl p (met 3 p) s (met 3 s) c d)
|= [p=@ s=@ c=@ d=@]
(pbl p (met 3 p) s (met 3 s) c d)
::
++ pbl ~/ %pbl :: w/length
|= [p=@ pl=@ s=@ sl=@ c=@ d=@]
=. p (end 3 pl p) =. s (end 3 sl s)
=+ h=32
?> ?& (lte d (bex 30)) :: max key length 1GB
(lte c (bex 28)) :: max iterations 2^28
!=(c 0)
==
=+ ^= l ?~ (mod d h)
(div d h)
+((div d h))
=+ r=(sub d (mul h (dec l)))
=+ [t=0 j=1 k=1]
=. t |- ^- @
?: (gth j l) t
=+ u=(add s (lsh 3 sl (rep 3 (flop (rpp 3 4 j)))))
=+ f=0 =. f |- ^- @
?: (gth k c) f
=+ q=(hml p pl u ?:(=(k 1) (add sl 4) h))
$(u q, f (mix f q), k +(k))
$(t (add t (lsh 3 (mul (dec j) h) f)), j +(j))
(end 3 d t)
|= [p=@ pl=@ s=@ sl=@ c=@ d=@]
=> .(p (end 3 pl p), s (end 3 sl s))
=+ h=32
?> ?& (lte d (bex 30)) :: max key length 1GB
(lte c (bex 28)) :: max iterations 2^28
!=(c 0)
==
=+ ^= l ?~ (mod d h)
(div d h)
+((div d h))
=+ r=(sub d (mul h (dec l)))
=+ [t=0 j=1 k=1]
=. t |- ^- @
?: (gth j l) t
=+ u=(add s (lsh 3 sl (rep 3 (flop (rpp 3 4 j)))))
=+ f=0 =. f |- ^- @
?: (gth k c) f
=+ q=(hml p pl u ?:(=(k 1) (add sl 4) h))
$(u q, f (mix f q), k +(k))
$(t (add t (lsh 3 (mul (dec j) h) f)), j +(j))
(end 3 d t)
::
++ hsh ~/ %hsh :: scrypt
|= [p=@ s=@ n=@ r=@ z=@ d=@]
(hsl p (met 3 p) s (met 3 s) n r z d)
|= [p=@ s=@ n=@ r=@ z=@ d=@]
(hsl p (met 3 p) s (met 3 s) n r z d)
::
++ hsl ~/ %hsl :: w/length
|= [p=@ pl=@ s=@ sl=@ n=@ r=@ z=@ d=@]
=| v=(list (list ,@))
=. p (end 3 pl p) =. s (end 3 sl s)
=+ u=(mul (mul 128 r) z)
?> ?& =(n (bex (dec (xeb n)))) :: n is power of 2
!=(r 0) !=(z 0)
%+ lte :: max 1GB memory
(mul (mul 128 r) (dec (add n z)))
(bex 30)
(lth pl (bex 31))
(lth sl (bex 31))
==
=+ ^= b =+ %^ rpp 3 u
(pbl p pl s sl 1 u)
%+ turn (bls (mul 128 r) -)
|=(a=(list ,@) (rpp 9 (mul 2 r) (rep 3 a)))
?> =((lent b) z)
=+ ^= q
=+ |- ?~ b (flop v)
$(b +.b, v [i=(srm r -.b n) t=v])
%+ turn `(list (list ,@))`-
|=(a=(list ,@) (rpp 3 (mul 128 r) (rep 9 a)))
(pbl p pl (rep 3 (slb q)) u 1 d)
|= [p=@ pl=@ s=@ sl=@ n=@ r=@ z=@ d=@]
=| v=(list (list ,@))
=> .(p (end 3 pl p), s (end 3 sl s))
=+ u=(mul (mul 128 r) z)
?> ?& =(n (bex (dec (xeb n)))) :: n is power of 2
!=(r 0) !=(z 0)
%+ lte :: max 1GB memory
(mul (mul 128 r) (dec (add n z)))
(bex 30)
(lth pl (bex 31))
(lth sl (bex 31))
==
=+ ^= b =+ (rpp 3 u (pbl p pl s sl 1 u))
%+ turn (bls (mul 128 r) -)
|=(a=(list ,@) (rpp 9 (mul 2 r) (rep 3 a)))
?> =((lent b) z)
=+ ^= q
=+ |- ?~ b (flop v)
$(b +.b, v [i=(srm r -.b n) t=v])
%+ turn `(list (list ,@))`-
|=(a=(list ,@) (rpp 3 (mul 128 r) (rep 9 a)))
(pbl p pl (rep 3 (slb q)) u 1 d)
--
::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
:: section 2eY, SHA-256 (move me) ::
@ -10075,6 +10069,7 @@
|= hap=path ^- @tas
?+ hap !!
[@ %ames *] %a
[@ %boat *] %c
[@ %newt *] %a
[@ %sync *] %c
[@ %term *] %d

View File

@ -42,7 +42,7 @@
== ::
++ move ,[p=duct q=(mold note gift)] :: typed move
++ note :: out request $->
$% $: %t :: to %time
$% $: %b :: to %behn
$% [%wait p=@da] ::
[%rest p=@da] ::
== == == ::

View File

@ -1029,9 +1029,7 @@
^- miso
=+ dir=((hard arch) .^(%cy pax))
?~ q.dir [%ins val]
=+ for=((hard mark) -:(flop pax))
?> =(for p.val)
[%mut [for p.q.val .^(%cx pax)] val]
[%mut val]
::
++ file :: simple file load
|= pax=path
@ -1049,7 +1047,7 @@
|= pax=path
^- toro
?> ?=([* * * *] pax)
[i.t.pax [%& [*cart [[t.t.t.pax [%del %$ !>(.^(%cx pax))]] ~]]]]
[i.t.pax [%& [*cart [[t.t.t.pax [%del ~]] ~]]]]
::
++ furl :: unify changes
|= [one=toro two=toro]
@ -1163,12 +1161,13 @@
::
++ ofis :: XX broken
=- |=(a=cord (rash a fel))
=- fel=;~(sfix (boss 64 (plus siw)) (stun 0^2 tis))
=< fel=(cook |=(a=@ `@t`(swap 3 a)) (bass 64 .))
=- (cook welp ;~(plug (plus siw) (stun 0^2 (cold %0 tis))))
^= siw
;~ pose
dit
(cook |=(a=@ (sub a (sub 'A' 10))) (shim 'A' 'Z'))
(cook |=(a=@ (sub a (sub 'a' 36))) (shim 'a' 'z'))
(cook |=(a=@ (sub a 'A')) (shim 'A' 'Z'))
(cook |=(a=@ (sub a 'G')) (shim 'a' 'z'))
(cook |=(a=@ (add a 4)) (shim '0' '9'))
(cold 62 (just '+'))
(cold 63 (just '/'))
==
@ -2114,13 +2113,13 @@
++ mime ,[p=mite q=octs] :: mimetyped data
++ mite (list ,@ta) :: mime type
++ miso :: ankh delta
$% [%del p=cage] :: delete
$% [%del ~] :: delete
[%ins p=cage] :: insert
[%dif p=cage] :: mutate from diff
[%mut p=cage q=cage] :: mutate from raw
[%mut p=cage] :: mutate from raw
== ::
++ misu :: computed delta
$% [%del p=cage] :: delete
$% [%del ~] :: delete
[%ins p=cage] :: insert
[%dif p=lobe q=cage] :: mutate from diff
== ::
@ -2322,29 +2321,46 @@
[%wont p=sock q=path r=*] :: e2e send message
== ::
::
:::: %behn
::
++ gift-behn :: out result <-$
$% [%mass p=mass] :: memory usage
[%wake ~] :: wakey-wakey
== ::
++ kiss-behn :: in request ->$
$% [%rest p=@da] :: cancel alarm
[%wait p=@da] :: set alarm
[%wake ~] :: timer activate
[%wegh ~] :: report memory
== ::
::
:::: %clay
::
++ khan ::
$: fil=(unit (unit cage)) :: XX see khan-to-soba
dir=(unit (map ,@ta (unit khan))) ::
== ::
++ mick (list ,[path (unit mime)])
++ mode (list ,[path (unit mime)])
++ riff ,[p=desk q=(unit rave)] :: request/desist
:::: ::
++ gift-clay :: out result <-$
$% [%ergo p=@p q=@tas r=@ud s=mick] :: version update
$% [%ergo p=@tas q=mode] :: version update
[%hill p=(list ,@tas)] :: mount points
[%mack p=(unit tang)] :: ack
[%mass p=mass] :: memory usage
[%mere p=(each (set path) (pair term tang))] :: merge result
[%note p=@tD q=tank] :: debug message
[%ogre p=@tas] :: delete mount point
[%writ p=riot] :: response
== ::
++ kiss-clay :: in request ->$
$% [%info p=@p q=@tas r=nori] :: internal edit
$% [%boat ~] :: pier rebooted
[%info p=@p q=@tas r=nori] :: internal edit
[%init p=@p] :: report install
[%into p=@p q=@tas r=khan] :: external edit
[%lynx p=@p q=@tas r=(unit ,?)] :: sync to unix
[%into p=@tas q=? r=mode] :: external edit
[%merg p=@p q=@tas r=@p s=@tas t=germ] :: merge desks
[%mont p=@tas q=@p r=@tas s=path] :: mount to unix
[%ogre p=$|(@tas beam)] :: delete mount point
[%warp p=sock q=riff] :: file request
[%wegh ~] :: report memory
[%west p=sack q=path r=*] :: network request
@ -2587,19 +2603,6 @@
[%mack p=(unit tang)] :: message ack
== ::
::
:::: %time
::
++ gift-time :: out result <-$
$% [%mass p=mass] :: memory usage
[%wake ~] :: wakey-wakey
== ::
++ kiss-time :: in request ->$
$% [%rest p=@da] :: cancel alarm
[%wait p=@da] :: set alarm
[%wake ~] :: timer activate
[%wegh ~] :: report memory
== ::
::
:::: %arvo
::
++ gift-arvo :: out result <-$
@ -2609,7 +2612,7 @@
gift-eyre
gift-ford
gift-gall
gift-time
gift-behn
==
++ kiss-arvo :: in request ->$
$? kiss-ames
@ -2618,25 +2621,25 @@
kiss-eyre
kiss-ford
kiss-gall
kiss-time
kiss-behn
==
++ note-arvo :: out request $->
$? [@tas %meta vase]
$% [%a kiss-ames]
[%b kiss-behn]
[%c kiss-clay]
[%d kiss-dill]
[%e kiss-eyre]
[%f kiss-ford]
[%g kiss-gall]
[%t kiss-time]
== ==
++ sign-arvo :: in result $<-
$% [%a gift-ames]
[%b gift-behn]
[%c gift-clay]
[%d gift-dill]
[%e gift-eyre]
[%f gift-ford]
[%g gift-gall]
[%t gift-time]
==
--

View File

@ -1 +0,0 @@
|=([^ [input=path output=path ~] ~] kiln-cp/[input output])

View File

@ -1,16 +0,0 @@
:: this mark is used to receive incoming oauth2 tokens that we use to poke our %gall server
::
:::: /hook/door/do-auth/mar
::
/? 310
!:
|_ cod=cord
::
++ grab :: converter arm
|%
++ noun ,@t :: clam from noun
++ json (cork (ot authcode/so platform/so ~):jo need) :: (need (so:jo jon))
--
--

View File

@ -1,9 +0,0 @@
!:
|_ cod=cord
::
++ grab :: converter am
|%
++ noun ,@t :: clam from noun
++ json (cork (ot secret/so platform/so ~):jo need) :: (need (so:jo jon))
--
--

View File

@ -8,5 +8,5 @@
|= $: [now=@da eny=@uvI bec=beak]
[arg=(list term) ~]
==
:+ %hood-reload-desk %base
:+ %helm-reload-desk %base
arg

View File

@ -8,4 +8,4 @@
|= $: [now=@da eny=@uvI bec=beak]
[[who=@p myl=@t ~] ~]
==
[%hood-invite who myl]
[%helm-invite who myl]

12
cat/hood/label.hoon Normal file
View File

@ -0,0 +1,12 @@
::
:::: /hoon/label/hood/cat
::
/? 314
::
::::
!:
|= $: [now=@da eny=@uvI bec=beak]
[arg=[syd=desk lab=@tas ~] ~]
==
:- %kiln-label
[syd lab]:arg

View File

@ -8,7 +8,7 @@
|= $: [now=@da eny=@uvI byk=beak]
[arg=$?([dap=term ~] [who=ship dap=term ~]) ~]
==
:- %hood-link
:- %drum-link
?~ +.arg
[p.byk dap.arg]
[who.arg dap.arg]

View File

@ -8,4 +8,4 @@
|= $: [now=@da eny=@uvI bec=beak]
[arg=~ ~]
==
[%hood-mass ~]
[%helm-mass ~]

View File

@ -8,5 +8,5 @@
|= $: [now=@da eny=@uvI bec=beak]
[[syd=@tas her=@p sud=@tas gem=?([?(%auto germ) ~] ~)] ~]
==
:- %hood-merge
:- %kiln-merge
[syd her sud ?~(gem %auto -.gem)]

12
cat/hood/mount.hoon Normal file
View File

@ -0,0 +1,12 @@
::
:::: /hoon/mount/hood/cat
::
/? 314
::
::::
!:
|= $: [now=@da eny=@uvI bec=beak]
[arg=[pax=path pot=@tas ~] ~]
==
:- %kiln-mount
[pax pot]:arg

1
cat/hood/mv.hoon Normal file
View File

@ -0,0 +1 @@
|=([^ [input=path output=path ~] ~] kiln-mv/[input output])

View File

@ -8,5 +8,5 @@
|= $: [now=@da eny=@uvI bec=beak]
[arg=[desk (list term)] ~]
==
:- %hood-reload-desk
:- %helm-reload-desk
arg

View File

@ -8,5 +8,5 @@
|= $: [now=@da eny=@uvI bec=beak]
[arg=(list term) ~]
==
:- %hood-reload
:- %helm-reload
arg

View File

@ -8,4 +8,4 @@
|= $: [now=@da eny=@uvI bec=beak]
[arg=~ ~]
==
[%hood-reset ~]
[%helm-reset ~]

View File

@ -8,7 +8,7 @@
|= $: [now=@da eny=@uvI bec=beak]
[arg=[@ $|(~ [@ ~])] ~]
==
:- %hood-start
:- %drum-start
?> ((sane %tas) -.arg)
?@ +.arg [%home -.arg]
?> ((sane %tas) +<.arg)

View File

@ -8,5 +8,5 @@
|= $: [now=@da eny=@uvI bec=beak]
[arg=[syd=@tas her=@p sud=@tas ~] ~]
==
:- %hood-sync
:- %kiln-sync
[syd her sud]:arg

12
cat/hood/unmount.hoon Normal file
View File

@ -0,0 +1,12 @@
::
:::: /hoon/mount/hood/cat
::
/? 314
::
::::
!:
|= $: [now=@da eny=@uvI bec=beak]
[[mon=$|(term [span path]) ~] ~]
==
:- %kiln-unmount
mon

View File

@ -9,5 +9,5 @@
|= $: [now=@da eny=@ bec=beak]
[~ ~]
==
~& %hood-verb
~& %helm-verb
[%helm-verb ~]

View File

@ -23,10 +23,10 @@
[%g %gall]
[%f %ford]
[%a %ames]
[%b %behn]
[%c %clay]
[%d %dill]
[%e %eyre]
[%t %time]
==
|- ^+ all
?~ vay all

View File

@ -14,20 +14,20 @@
==
^- (sole-result (cask begs))
%+ sole-lo
[%& %hood-begin "your ship: ~"]
[%& %helm-begin "your ship: ~"]
%+ sole-go fed:ag
|= his=@p
%+ sole-lo
[%& %hood-ticket "your ticket: ~"]
[%& %helm-ticket "your ticket: ~"]
%+ sole-go fed:ag
|= tic=@p
%+ sole-lo
[%& %hood-entropy "some entropy: "]
[%& %helm-entropy "some entropy: "]
%+ sole-go (boss 256 (more gon qit))
|= yen=@t
=+ ney=(shax yen)
%+ sole-yo `tank`[%leaf "entropy check: {(scow %p `@p`(mug ney))}"]
%+ sole-so %hood-begin
%+ sole-so %helm-begin
:* his
tic
ney

View File

@ -131,12 +131,12 @@
^- (list ,[p=@tas q=@tas])
:~ [%$ %zuse]
[%a %ames]
[%b %behn]
[%c %clay]
[%d %dill]
[%e %eyre]
[%f %ford]
[%g %gall]
[%t %time]
==
|= [p=@tas q=@tas]
=+ way=`path`(welp top /[q])

View File

@ -21,10 +21,12 @@
:: :: ::
:::: :: ::
:: :: ::
++ hood-unix ::
$: syd=desk ::
syn=(unit bean) ::
++ hood-mount ::
$: pax=path ::
pot=term ::
== ::
++ hood-unmount ::
$|(term [span path]) ::
++ hood-sync ::
$: syd=desk ::
her=ship ::
@ -55,7 +57,8 @@
++ card ::
$% [%exec wire @p beak (unit silk)] ::
[%info wire @p @tas nori] ::
[%lynx wire @p @tas (unit ,?)] ::
[%mont wire @tas @p @tas path] ::
[%ogre wire $|(@tas beam)] ::
[%merg wire @p @tas @p @tas germ] ::
[%poke wire dock pear] ::
[%warp wire sock riff] ::
@ -76,9 +79,23 @@
^+ +>
?~(+< +> $(+< t.+<, +> (emit i.+<)))
::
++ poke-unix ::
|= hood-unix
abet:(emit %lynx /kiln our syd syn)
++ poke-mount
|= hood-mount
=+ bem=(tome pax)
?~ bem
=+ "can't mount bad path: {<pax>}"
abet:(spam leaf/- ~)
abet:(emit %mont /mount pot p.u.bem q.u.bem (flop s.u.bem))
::
++ poke-unmount
|= mon=hood-unmount
?^ mon
=+ bem=(tome mon)
?~ bem
=+ "can't unmount bad path: {<mon>}"
abet:(spam leaf/- ~)
abet:(emit %ogre /unmount-beam [[p q %ud 0] s]:u.bem)
abet:(emit %ogre /unmount-point mon)
::
++ poke-sync ::
|= hos=hood-sync
@ -118,6 +135,11 @@
%+ furl (fray output)
(foal output -:(flop input) %noun .^(%cx input))
::
++ poke-label
|= [syd=desk lab=@tas]
=+ pax=/(scot %p our)/[syd]/[lab]
(do-info "labeled {(spud pax)}" [syd %| lab])
::
++ poke-schedule
|= [where=path tym=@da eve=@t]
=. where (welp where /sched)
@ -217,8 +239,7 @@
=. +>.$
%- spam
?: ?=(%& -.mes)
~
:: [leaf/"sync succeeded from {<sud>} on {<her>} to {<syd>}" ~]
[leaf/"sync succeeded from {<sud>} on {<her>} to {<syd>}" ~]
?+ p.p.mes
:* leaf/"sync failed from {<sud>} on {<her>} to {<syd>}"
leaf/"please manually merge the desks with"

Some files were not shown because too many files have changed in this diff Show More