mirror of
https://github.com/urbit/shrub.git
synced 2025-01-05 19:46:50 +03:00
various fixes and improvements
This commit is contained in:
parent
a02f8d0f06
commit
b3fbdc6d3a
@ -672,7 +672,7 @@
|
||||
^- (quip move +>)
|
||||
~? !=(src.hid our.hid) [%dojo-peer-stranger ost.hid src.hid pax]
|
||||
:: ?> =(src.hid our.hid)
|
||||
?< (~(has by hoc) ost.hid)
|
||||
~? (~(has by hoc) ost.hid) [%dojo-peer-replaced ost.hid pax]
|
||||
?> =(~ pax)
|
||||
=< he-abet
|
||||
%~ he-peer he
|
||||
|
@ -179,7 +179,7 @@
|
||||
|= [wid=@u tan=tang]
|
||||
^- tape
|
||||
=+ rolt=|=(a=wall `tape`?~(a ~ :(weld i.a "\0a" $(a t.a))))
|
||||
(rolt (turn tan |=(a=tank (rolt (wash 0^wid a)))))
|
||||
(rolt (turn (flop tan) |=(a=tank (rolt (wash 0^wid a)))))
|
||||
::
|
||||
::
|
||||
++ add-cookies
|
||||
@ -188,7 +188,7 @@
|
||||
=+ cuh=(turn `(list ,@t)`cug |=(a=@t set-cookie/a))
|
||||
hit(q (weld cuh q.hit))
|
||||
::
|
||||
++ add-poll :: inject dependency
|
||||
++ inject :: inject dependency
|
||||
|= [dep=@uvH max=[[%html ~] [[%head ~] hed=marl] [[%body ~] tal=marl] ~]]
|
||||
^- manx
|
||||
=: hed.max :_(hed.max ;meta(charset "utf-8", urb_injected "");)
|
||||
@ -198,7 +198,7 @@
|
||||
max(hed :_(hed.max ;script@"/~/on/{<dep>}.js"(urb_injected "");))
|
||||
::
|
||||
++ add-json :: inject window.urb
|
||||
|= [urb=json jaz=cord] ^- cord
|
||||
|= [urb=json jaz=cord] ^- cord
|
||||
=- (cat 3 (crip -) jaz)
|
||||
"""
|
||||
var _urb = {(pojo urb)}
|
||||
@ -222,7 +222,6 @@
|
||||
|= tan=tang
|
||||
;html
|
||||
;head
|
||||
;meta(charset "utf-8");
|
||||
;link(rel "stylesheet", href "/home/lib/base.css");
|
||||
;title: server error
|
||||
==
|
||||
@ -772,7 +771,7 @@
|
||||
=- `silk`[%cast %mime %done ~ cay(q.q -)]
|
||||
?+ p.cay q.q.cay :: inject dependency long-poll
|
||||
%urb =| urb=[[%html ~] [[%head ~] marl] [[%body ~] manx marl] ~]
|
||||
.*(.(urb q.q.cay) !=((add-poll p.sih urb)))
|
||||
.*(.(urb q.q.cay) !=((inject p.sih urb)))
|
||||
==
|
||||
~| q.q.cay
|
||||
=+ ((hard ,[mit=mite rez=octs]) q.q.cay)
|
||||
@ -816,7 +815,7 @@
|
||||
|= [sas=@ud dep=@uvH mez=tang]
|
||||
^+ +>
|
||||
:: (back ha/~ dep %tang !>(mez)) ::tang->urb chain may be source of failure
|
||||
(give-html sas ~ (add-poll dep (render-tang mez)))
|
||||
(give-html sas ~ (inject dep (render-tang mez)))
|
||||
::
|
||||
++ give-html
|
||||
|= [sas=@ud cug=(list ,@t) max=manx]
|
||||
|
@ -835,7 +835,9 @@
|
||||
|= [cof=cafe arc=arch]
|
||||
?^ q.arc
|
||||
%+ (flux some) cof
|
||||
|=([cof=cafe arg=heel] (cope (liar cof bem) (lake for)))
|
||||
|= [cof=cafe arg=heel] ^- (bolt vase)
|
||||
%+ cool |.(leaf/"ford: load {<for>} {<(tope bem)>}")
|
||||
(cope (liar cof bem) (lake for))
|
||||
?. (~(has by r.arc) %hook)
|
||||
(flue cof)
|
||||
%+ cope (lend cof bem(s [%hook s.bem]))
|
||||
@ -843,7 +845,8 @@
|
||||
?~ q.arc
|
||||
(flue cof)
|
||||
%+ (flux some) cof
|
||||
|= [cof=cafe arg=heel]
|
||||
|= [cof=cafe arg=heel] ^- (bolt vase)
|
||||
%+ cool |.(leaf/"ford: hook {<for>} {<(tope bem)>}")
|
||||
%+ cope (fade cof %hook bem)
|
||||
|= [cof=cafe hyd=hood]
|
||||
(cope (abut:(meow bem arg) cof hyd) (lake for))
|
||||
@ -917,8 +920,8 @@
|
||||
=+ von=(save ~ %cy bem)
|
||||
?~ von [p=cof q=[%1 [%y bem ~] ~ ~]]
|
||||
%+ flag (norm ska bem)
|
||||
(fine cof ((hard arch) q.q:(need u.von)))
|
||||
::
|
||||
(fine cof ?>(?=([~ %arch ^] u.von) ((hard arch) q.q.u.u.von)))
|
||||
::
|
||||
++ liar :: load vase
|
||||
|= [cof=cafe bem=beam]
|
||||
^- (bolt vase)
|
||||
@ -999,7 +1002,6 @@
|
||||
%+ cope ((~(got by mal) i.wuy) cof arg)
|
||||
|= [cof=cafe hoc=vase]
|
||||
(cope (lope cof i.wuy t.wuy hoc) (flux some))
|
||||
::
|
||||
++ lime :: load beam
|
||||
|= [cof=cafe for=mark bem=beam arg=heel]
|
||||
=+ [mob=bem mer=(flop arg)]
|
||||
@ -1113,7 +1115,7 @@
|
||||
::
|
||||
%boil
|
||||
^- (bolt gage)
|
||||
:: %+ cool |.(leaf/"ford: boil {<p.kas>} {<(tope q.kas)>} {<r.kas>}")
|
||||
%+ cool |.(leaf/"ford: boil {<p.kas>} {<(tope q.kas)>} {<r.kas>}")
|
||||
%+ cope (lamp cof q.kas)
|
||||
|= [cof=cafe bem=beam]
|
||||
%+ cope (lime cof p.kas bem r.kas)
|
||||
|
@ -4156,7 +4156,7 @@
|
||||
|* [hel=(list) hev=(list)]
|
||||
|- ^+ hev
|
||||
=+ ^= sev
|
||||
=+ [inx=0 sev=*(map ,@t (list ,@ud))]
|
||||
=+ [inx=0 sev=*(map ,_i.-.hev (list ,@ud))]
|
||||
|- ^+ sev
|
||||
?~ hev sev
|
||||
=+ guy=(~(get by sev) i.hev)
|
||||
@ -6444,7 +6444,7 @@
|
||||
:- %mean
|
||||
=+ fek=~(feck ap p.gen)
|
||||
?^ fek [%dtzz %tas u.fek]
|
||||
[%brdt [%cnhp [%cnzy %cain] [%zpgr p.gen] ~]]
|
||||
[%brdt [%cnhp [%cnzy %cain] [%zpgr [%tsgr [~ 3] p.gen]] ~]]
|
||||
q.gen
|
||||
::
|
||||
[%sgcb *] [%sggr [%mean [%brdt p.gen]] q.gen]
|
||||
|
@ -102,9 +102,7 @@
|
||||
::
|
||||
++ do-info
|
||||
|= [mez=tape pax=path tor=toro]
|
||||
=+ syd=q:(need (tome pax))
|
||||
=- abet:abet:(spam:(work syd) leaf/mez ~)
|
||||
(emit %info /kiln our tor)
|
||||
abet:(emit:(spam leaf/mez ~) %info /kiln our tor)
|
||||
::
|
||||
++ poke-rm |=(a=path (do-info "removed" a (fray a)))
|
||||
++ poke-cp
|
||||
|
Loading…
Reference in New Issue
Block a user