urbit/gen/solid.hoon

54 lines
1.2 KiB
Plaintext
Raw Normal View History

:: Compile arvo as a pill noun, without compiler changes.
:: usage
::
:: .urbit/pill +solid
2015-06-18 04:08:47 +03:00
::
2016-02-11 03:41:28 +03:00
:::: /hoon/solid/gen
2015-06-18 04:08:47 +03:00
::
/? 310
2015-06-18 04:08:47 +03:00
::
::::
!:
2015-09-12 03:24:51 +03:00
:- %say
2016-08-11 21:15:06 +03:00
|= $: {now/@da eny/@uvJ bec/beak}
2015-12-10 12:17:19 +03:00
{$~ $~}
2015-06-18 04:08:47 +03:00
==
:- %noun
=+ top=`path`/(scot %p p.bec)/[q.bec]/(scot %da now)/sys
2015-06-18 04:08:47 +03:00
=+ pax=`path`(weld top `path`[%hoon ~])
=+ arp=`path`(weld top `path`[%ovra ~])
2015-06-18 04:08:47 +03:00
~& %solid-start
=+ txt=.^(@t %cx (weld pax `path`[%hoon ~]))
=+ rax=.^(@t %cx (weld arp `path`[%hoon ~]))
~& %solid-loaded
=+ gen=(rain pax txt)
2015-06-18 04:08:47 +03:00
~& %solid-parsed
=+ one=(~(mint ut %noun) %noun gen)
2015-06-18 04:08:47 +03:00
~& %solid-compiled
=+ two=(~(mint ut p.one) %noun (rain arp rax))
~& %solid-arvo
=+ ken=[7 q.one q.two]
~& [%solid-kernel `@ux`(mug ken)]
2015-06-18 04:08:47 +03:00
:- ken
=+ all=.*(0 ken)
=+ ^= vay ^- (list {p/@tas q/path})
:~ [%$ /zuse]
[%f /vane/ford]
[%c /vane/clay]
[%g /vane/gall]
[%a /vane/ames]
[%b /vane/behn]
[%d /vane/dill]
[%e /vane/eyre]
2015-06-18 04:08:47 +03:00
==
|- ^+ all
?~ vay all
=+ pax=(weld top q.i.vay)
2016-01-26 03:47:58 +03:00
=+ txt=.^(@ %cx (weld pax `path`[%hoon ~]))
2015-06-18 04:08:47 +03:00
=+ sam=[now `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)