mirror of
https://github.com/urbit/shrub.git
synced 2024-12-23 19:05:48 +03:00
Merge 9a777e84de
into release/next-js
This commit is contained in:
commit
1645e8597f
@ -40,7 +40,7 @@
|
|||||||
=. mar-ok.state %.y
|
=. mar-ok.state %.y
|
||||||
=+ .^(paz=(list path) ct+(en-beam now-beak /mar))
|
=+ .^(paz=(list path) ct+(en-beam now-beak /mar))
|
||||||
|- ^+ [fex this]
|
|- ^+ [fex this]
|
||||||
?~ paz [fex this]
|
?~ paz [(flop fex) this]
|
||||||
=/ xap=path (flop i.paz)
|
=/ xap=path (flop i.paz)
|
||||||
?. ?=([%hoon *] xap)
|
?. ?=([%hoon *] xap)
|
||||||
$(paz t.paz)
|
$(paz t.paz)
|
||||||
@ -63,7 +63,7 @@
|
|||||||
?> =(~ app.state)
|
?> =(~ app.state)
|
||||||
=. app-ok.state %.y
|
=. app-ok.state %.y
|
||||||
=+ .^(app-arch=arch cy+(en-beam now-beak /app))
|
=+ .^(app-arch=arch cy+(en-beam now-beak /app))
|
||||||
=/ daz ~(tap in ~(key by dir.app-arch))
|
=/ daz (sort ~(tap in ~(key by dir.app-arch)) |=((pair) !(aor p q)))
|
||||||
|- ^+ [fex this]
|
|- ^+ [fex this]
|
||||||
?~ daz [fex this]
|
?~ daz [fex this]
|
||||||
=/ dap-pax=path /app/[i.daz]/hoon
|
=/ dap-pax=path /app/[i.daz]/hoon
|
||||||
@ -86,7 +86,7 @@
|
|||||||
=. gen-ok.state %.y
|
=. gen-ok.state %.y
|
||||||
=+ .^(paz=(list path) ct+(en-beam now-beak /gen))
|
=+ .^(paz=(list path) ct+(en-beam now-beak /gen))
|
||||||
|- ^+ [fex this]
|
|- ^+ [fex this]
|
||||||
?~ paz [fex this]
|
?~ paz [(flop fex) this]
|
||||||
=/ xap=path (flop i.paz)
|
=/ xap=path (flop i.paz)
|
||||||
?. ?=([%hoon *] xap)
|
?. ?=([%hoon *] xap)
|
||||||
$(paz t.paz)
|
$(paz t.paz)
|
||||||
@ -106,11 +106,18 @@
|
|||||||
++ on-peek on-peek:def
|
++ on-peek on-peek:def
|
||||||
++ on-agent on-agent:def
|
++ on-agent on-agent:def
|
||||||
++ on-arvo
|
++ on-arvo
|
||||||
|
=> |%
|
||||||
|
++ report
|
||||||
|
|* [=path ok=?]
|
||||||
|
=/ =tank leaf+"{?:(ok "built " "FAILED")} {(spud path)}"
|
||||||
|
~>(%slog.[0 tank] same)
|
||||||
|
--
|
||||||
|
::
|
||||||
|= [=wire =sign-arvo]
|
|= [=wire =sign-arvo]
|
||||||
^- [(list card) _this]
|
^- [(list card) _this]
|
||||||
?. ?=([%build *] wire)
|
?. ?& ?=([%build *] wire)
|
||||||
(on-arvo:def wire sign-arvo)
|
?=([%clay %writ *] sign-arvo)
|
||||||
?. ?=(%writ +<.sign-arvo)
|
==
|
||||||
(on-arvo:def wire sign-arvo)
|
(on-arvo:def wire sign-arvo)
|
||||||
=/ =path t.wire
|
=/ =path t.wire
|
||||||
?+ path ~|(path+path !!)
|
?+ path ~|(path+path !!)
|
||||||
@ -118,41 +125,29 @@
|
|||||||
=/ ok
|
=/ ok
|
||||||
?~ p.sign-arvo |
|
?~ p.sign-arvo |
|
||||||
(~(nest ut -:!>(*agent:gall)) | -:!<(vase q.r.u.p.sign-arvo))
|
(~(nest ut -:!>(*agent:gall)) | -:!<(vase q.r.u.p.sign-arvo))
|
||||||
~& ?: ok
|
%- (report path ok)
|
||||||
agent-built+path
|
|
||||||
agent-failed+path
|
|
||||||
=? app-ok.state !ok %.n
|
=? app-ok.state !ok %.n
|
||||||
=. app.state (~(del in app.state) path)
|
=. app.state (~(del in app.state) path)
|
||||||
~? =(~ app.state)
|
~? =(~ app.state)
|
||||||
?: app-ok.state
|
?:(app-ok.state %all-agents-built %some-agents-failed)
|
||||||
%all-agents-built
|
|
||||||
%some-agents-failed
|
|
||||||
[~ this]
|
[~ this]
|
||||||
::
|
::
|
||||||
[%mar *]
|
[%mar *]
|
||||||
=/ ok ?=(^ p.sign-arvo)
|
=/ ok ?=(^ p.sign-arvo)
|
||||||
~& ?: ok
|
%- (report path ok)
|
||||||
mark-built+path
|
|
||||||
mark-failed+path
|
|
||||||
=? mar-ok.state !ok %.n
|
=? mar-ok.state !ok %.n
|
||||||
=. mar.state (~(del in mar.state) path)
|
=. mar.state (~(del in mar.state) path)
|
||||||
~? =(~ mar.state)
|
~? =(~ mar.state)
|
||||||
?: mar-ok.state
|
?:(mar-ok.state %all-marks-built %some-marks-failed)
|
||||||
%all-marks-built
|
|
||||||
%some-marks-failed
|
|
||||||
[~ this]
|
[~ this]
|
||||||
::
|
::
|
||||||
[%gen *]
|
[%gen *]
|
||||||
=/ ok ?=(^ p.sign-arvo)
|
=/ ok ?=(^ p.sign-arvo)
|
||||||
~& ?: ok
|
%- (report path ok)
|
||||||
generator-built+path
|
|
||||||
generator-failed+path
|
|
||||||
=? gen-ok.state !ok %.n
|
=? gen-ok.state !ok %.n
|
||||||
=. gen.state (~(del in gen.state) path)
|
=. gen.state (~(del in gen.state) path)
|
||||||
~? =(~ gen.state)
|
~? =(~ gen.state)
|
||||||
?: gen-ok.state
|
?:(gen-ok.state %all-generators-built %some-generators-failed)
|
||||||
%all-generators-built
|
|
||||||
%some-generators-failed
|
|
||||||
[~ this]
|
[~ this]
|
||||||
==
|
==
|
||||||
++ on-fail on-fail:def
|
++ on-fail on-fail:def
|
||||||
|
@ -59,10 +59,10 @@
|
|||||||
%~ tap by
|
%~ tap by
|
||||||
%+ scry associations:md
|
%+ scry associations:md
|
||||||
[%x %metadata-store [%group (snoc (en-path:re r) %noun)]]
|
[%x %metadata-store [%group (snoc (en-path:re r) %noun)]]
|
||||||
|= [[* m=md-resource:md] metadata:md]
|
|= [m=md-resource:md association:md]
|
||||||
::NOTE we only count graphs for now
|
::NOTE we only count graphs for now
|
||||||
?. &(=(%graph app-name.m) =(our creator)) ~
|
?. &(=(%graph app-name.m) =(our creator.metadatum)) ~
|
||||||
`[module (de-path:re app-path.m)]
|
`[module.metadatum resource.m]
|
||||||
:: count activity per channel
|
:: count activity per channel
|
||||||
::
|
::
|
||||||
=/ activity=(list [resource:re members=@ud (list [resource:re mod=term week=@ud authors=@ud])])
|
=/ activity=(list [resource:re members=@ud (list [resource:re mod=term week=@ud authors=@ud])])
|
||||||
|
@ -442,19 +442,19 @@
|
|||||||
;< ~ bind:m (send-request (hiss-to-request:html hiss))
|
;< ~ bind:m (send-request (hiss-to-request:html hiss))
|
||||||
take-maybe-sigh
|
take-maybe-sigh
|
||||||
::
|
::
|
||||||
:: +build-fail: build the source file at the specified $beam
|
:: +build-file: build the source file at the specified $beam
|
||||||
::
|
::
|
||||||
++ build-file
|
++ build-file
|
||||||
|= [[=ship =desk =case] =spur]
|
|= [[=ship =desk =case] =spur]
|
||||||
=* arg +<
|
=* arg +<
|
||||||
=/ m (strand ,vase)
|
=/ m (strand ,(unit vase))
|
||||||
^- form:m
|
^- form:m
|
||||||
;< =riot:clay bind:m
|
;< =riot:clay bind:m
|
||||||
(warp ship desk ~ %sing %a case spur)
|
(warp ship desk ~ %sing %a case spur)
|
||||||
?~ riot
|
?~ riot
|
||||||
(strand-fail %build-file >arg< ~)
|
(pure:m ~)
|
||||||
?> =(%vase p.r.u.riot)
|
?> =(%vase p.r.u.riot)
|
||||||
(pure:m !<(vase q.r.u.riot))
|
(pure:m (some !<(vase q.r.u.riot)))
|
||||||
:: +build-mark: build a mark definition to a $dais
|
:: +build-mark: build a mark definition to a $dais
|
||||||
::
|
::
|
||||||
++ build-mark
|
++ build-mark
|
||||||
|
@ -6,6 +6,9 @@
|
|||||||
=/ m (strand ,vase)
|
=/ m (strand ,vase)
|
||||||
^- form:m
|
^- form:m
|
||||||
=+ !<([~ pax=path] arg)
|
=+ !<([~ pax=path] arg)
|
||||||
?^ bem=(de-beam pax)
|
?~ bem=(de-beam pax)
|
||||||
(build-file:strandio u.bem)
|
(strand-fail:strand %path-not-beam >pax< ~)
|
||||||
(strand-fail:strand %path-not-beam >pax< ~)
|
;< vax=(unit vase) bind:m (build-file:strandio u.bem)
|
||||||
|
?^ vax
|
||||||
|
(pure:m u.vax)
|
||||||
|
(strand-fail:strand %build-file >u.bem< ~)
|
||||||
|
@ -92,8 +92,12 @@
|
|||||||
?. =(%hoon (rear p)) ~
|
?. =(%hoon (rear p)) ~
|
||||||
(some [[-.i.bez p] ~])
|
(some [[-.i.bez p] ~])
|
||||||
loop(bez t.bez, fiz (~(gas in fiz) foz))
|
loop(bez t.bez, fiz (~(gas in fiz) foz))
|
||||||
~| bad-test-beam+i.bez
|
::
|
||||||
=/ tex=term =-(?>(((sane %tas) -) -) (rear s.i.bez))
|
:: XX this logic appears to be vestigial
|
||||||
|
::
|
||||||
|
=/ tex=term
|
||||||
|
~| bad-test-beam+i.bez
|
||||||
|
=-(?>(((sane %tas) -) -) (rear s.i.bez))
|
||||||
=/ xup=path (snip s.i.bez)
|
=/ xup=path (snip s.i.bez)
|
||||||
;< hov=? bind:m (check-for-file:strandio i.bez(s (snoc xup %hoon)))
|
;< hov=? bind:m (check-for-file:strandio i.bez(s (snoc xup %hoon)))
|
||||||
?. hov
|
?. hov
|
||||||
@ -107,16 +111,23 @@
|
|||||||
=/ paz=(list path)
|
=/ paz=(list path)
|
||||||
(tail !<([~ (list path)] arg))
|
(tail !<([~ (list path)] arg))
|
||||||
=/ bez=(list beam)
|
=/ bez=(list beam)
|
||||||
(turn paz |=(p=path (need (de-beam p))))
|
(turn paz |=(p=path ~|([%test-not-beam p] (need (de-beam p)))))
|
||||||
;< fiz=(set [=beam test=(unit term)]) bind:m (find-test-files bez)
|
;< fiz=(set [=beam test=(unit term)]) bind:m (find-test-files bez)
|
||||||
=> .(fiz (sort ~(tap in fiz) aor))
|
=> .(fiz (sort ~(tap in fiz) aor))
|
||||||
=| test-arms=(map path (list test-arm))
|
=| test-arms=(map path (list test-arm))
|
||||||
|
=| build-ok=?
|
||||||
|- ^- form:m
|
|- ^- form:m
|
||||||
=* gather-tests $
|
=* gather-tests $
|
||||||
?^ fiz
|
?^ fiz
|
||||||
~> %slog.0^leaf+"test: building {(spud s.beam.i.fiz)}"
|
;< cor=(unit vase) bind:m (build-file:strandio beam.i.fiz)
|
||||||
;< cor=vase bind:m (build-file:strandio beam.i.fiz)
|
?~ cor
|
||||||
=/ arms=(list test-arm) (get-test-arms cor)
|
~> %slog.0^leaf+"FAILED {(spud s.beam.i.fiz)} (build)"
|
||||||
|
gather-tests(fiz t.fiz, build-ok |)
|
||||||
|
~> %slog.0^leaf+"built {(spud s.beam.i.fiz)}"
|
||||||
|
=/ arms=(list test-arm) (get-test-arms u.cor)
|
||||||
|
::
|
||||||
|
:: XX this logic appears to be vestigial
|
||||||
|
::
|
||||||
=? arms ?=(^ test.i.fiz)
|
=? arms ?=(^ test.i.fiz)
|
||||||
|- ^+ arms
|
|- ^+ arms
|
||||||
?~ arms ~|(no-test-arm+i.fiz !!)
|
?~ arms ~|(no-test-arm+i.fiz !!)
|
||||||
@ -127,7 +138,7 @@
|
|||||||
gather-tests(fiz t.fiz)
|
gather-tests(fiz t.fiz)
|
||||||
%- pure:m !> ^= ok
|
%- pure:m !> ^= ok
|
||||||
%+ roll (resolve-test-paths test-arms)
|
%+ roll (resolve-test-paths test-arms)
|
||||||
|= [[=path =test-func] ok=_`?`%&]
|
|= [[=path =test-func] ok=_build-ok]
|
||||||
^+ ok
|
^+ ok
|
||||||
=/ res (run-test path test-func)
|
=/ res (run-test path test-func)
|
||||||
%- (slog (flop tang.res))
|
%- (slog (flop tang.res))
|
||||||
|
@ -327,7 +327,7 @@
|
|||||||
:: echo "hello" | openssl dgst -sha256 -sign private.pem | base64
|
:: echo "hello" | openssl dgst -sha256 -sign private.pem | base64
|
||||||
%+ expect-eq
|
%+ expect-eq
|
||||||
!> exp2b64
|
!> exp2b64
|
||||||
!> (en:base64 (met 3 sig) (swp 3 sig))
|
!> (en:base64:mimes:html (met 3 sig) (swp 3 sig))
|
||||||
==
|
==
|
||||||
::
|
::
|
||||||
++ test-csr
|
++ test-csr
|
||||||
|
Loading…
Reference in New Issue
Block a user