shrub/app/hood.hoon

165 lines
8.4 KiB
Plaintext
Raw Normal View History

2015-06-12 00:53:32 +03:00
:: :: ::
2016-02-05 06:05:37 +03:00
:::: /hoon/hood/app :: ::
2015-05-11 21:05:14 +03:00
:: :: ::
/? 310 :: zuse version
2016-02-12 02:29:52 +03:00
/+ sole, talk, helm, kiln, drum, write :: libraries
2015-09-02 03:24:18 +03:00
[. helm kiln drum]
2015-05-11 21:05:14 +03:00
:: :: ::
:::: :: ::
!: :: ::
=> |% :: module boilerplate
++ hood-0 ::
2015-12-20 23:50:45 +03:00
{$0 lac/(map @tas hood-part)} ::
2015-05-11 21:05:14 +03:00
++ hood-good ::
2015-12-20 23:50:45 +03:00
|* hed/hood-head ::
|= paw/hood-part ::
2015-05-11 21:05:14 +03:00
?- hed ::
2015-12-09 04:54:26 +03:00
$drum ?>(?=($drum -.paw) `drum-part`paw) ::
$helm ?>(?=($helm -.paw) `helm-part`paw) ::
$kiln ?>(?=($kiln -.paw) `kiln-part`paw) ::
2016-02-12 02:29:52 +03:00
$write ?>(?=($write -.paw) `part:write`paw) ::
2015-05-11 21:05:14 +03:00
== ::
++ hood-head _-:*hood-part ::
2015-05-12 23:10:22 +03:00
++ hood-make ::
2015-12-20 23:50:45 +03:00
|* {our/@p hed/hood-head} ::
2015-05-11 21:05:14 +03:00
?- hed ::
$drum (drum-make our) ::
2015-12-09 04:54:26 +03:00
$helm *helm-part ::
$kiln *kiln-part ::
$write *part:write ::
2015-05-11 21:05:14 +03:00
== ::
++ hood-part-old ::
$? hood-part ::
{$drum $0 drum-pith-0} ::
== ::
++ hood-port ::
|= paw/hood-part-old ^- hood-part ::
?+ -.paw paw ::
$drum (drum-port paw) ::
== ::
:: ::
2015-05-11 21:05:14 +03:00
++ hood-part ::
$% {$drum $1 drum-pith} ::
2015-12-09 04:54:26 +03:00
{$helm $0 helm-pith} ::
{$kiln $0 kiln-pith} ::
2016-02-12 02:29:52 +03:00
{$write $0 pith:write} ::
2015-05-11 21:05:14 +03:00
== ::
-- ::
:: :: ::
:::: :: ::
:: :: ::
2015-12-20 23:50:45 +03:00
|_ $: hid/bowl :: system state
hood-0 :: server state
2015-05-11 21:05:14 +03:00
== ::
2015-12-21 00:16:39 +03:00
++ able :: find+make part
2015-12-20 23:50:45 +03:00
|* hed/hood-head
2015-05-11 21:05:14 +03:00
=+ rep=(~(get by lac) hed)
=+ par=?^(rep u.rep `hood-part`(hood-make our.hid hed))
2015-05-12 23:10:22 +03:00
((hood-good hed) par)
2015-05-11 21:05:14 +03:00
::
++ ably :: save part
|* {(list) hood-part}
[(flop +<-) %_(+> lac (~(put by lac) +<+< +<+))]
2015-05-11 21:05:14 +03:00
:: :: ::
:::: :: ::
:: :: ::
++ prep ::
|= old/(unit hood-0) ^- (quip _!! +>)
:- ~
?~ old +>
+>(lac (~(run by lac.u.old) hood-port))
::
2015-05-30 10:53:19 +03:00
++ coup-kiln-fancy (wrap take-coup-fancy):from-kiln
2015-05-14 22:24:43 +03:00
++ coup-kiln-spam ::
2015-12-20 23:50:45 +03:00
|= {way/wire saw/(unit tang)}
2015-05-14 22:24:43 +03:00
~? ?=(^ saw) [%kiln-spam-lame u.saw]
2015-06-12 00:53:32 +03:00
[~ +>]
2015-05-14 22:24:43 +03:00
::
2015-09-17 01:39:11 +03:00
++ coup-kiln-reload ::
2015-12-20 23:50:45 +03:00
|= {way/wire saw/(unit tang)}
2015-09-17 01:39:11 +03:00
~? ?=(^ saw) [%kiln-reload-lame u.saw]
[~ +>]
::
2015-09-26 03:23:06 +03:00
++ coup-kiln-overload ::
2015-12-20 23:50:45 +03:00
|= {way/wire saw/(unit tang)}
2015-09-26 03:23:06 +03:00
~? ?=(^ saw) [%kiln-overload-lame u.saw]
[~ +>]
::
++ coup-drum-phat (wrap take-coup-phat):from-drum
++ coup-helm-hi (wrap coup-hi):from-helm
++ diff-sole-effect-drum-phat (wrap diff-sole-effect-phat):from-drum
2015-06-04 01:16:32 +03:00
++ from-lib
2015-12-15 01:24:20 +03:00
|* _[%helm ..$ _abet]:(helm)
2015-06-04 01:16:32 +03:00
=> .(+< [identity start finish]=+<)
=- [wrap=- *start] :: usage (wrap handle-arm):from-foo
2015-12-20 23:50:45 +03:00
|* handle/_finish
2015-06-04 01:16:32 +03:00
|= _+<.handle
=. +>.handle (start hid (able identity))
(ably (handle +<))
2015-05-17 22:39:03 +03:00
::
2015-12-15 01:21:10 +03:00
++ from-drum (from-lib %drum [..$ _se-abet]:(drum))
++ from-helm (from-lib %helm [..$ _abet]:(helm))
++ from-kiln (from-lib %kiln [..$ _abet]:(kiln))
2016-02-12 02:29:52 +03:00
++ from-write (from-lib %write [..$ _abet]:(write))
2015-05-28 05:46:58 +03:00
::
2015-12-20 23:50:45 +03:00
++ init-helm |=({way/wire *} [~ +>])
2016-02-12 02:29:52 +03:00
++ made-write (wrap made):from-write
2015-09-17 02:40:53 +03:00
++ made-kiln (wrap take-made):from-kiln
++ mere-kiln (wrap take-mere):from-kiln
++ mere-kiln-sync (wrap take-mere-sync):from-kiln
2015-09-26 03:23:06 +03:00
++ wake-kiln-overload (wrap take-wake-overload):from-kiln
2015-09-17 02:40:53 +03:00
++ note-helm (wrap take-note):from-helm
++ 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
2015-10-20 23:48:11 +03:00
++ poke-drum-unlink (wrap poke-unlink):from-drum
2016-02-12 02:29:52 +03:00
:: ++ poke-drum-exit (wrap poke-exit):from-drum
2015-09-17 02:40:53 +03:00
++ poke-drum-start (wrap poke-start):from-drum
++ poke-helm-hi (wrap poke-hi):from-helm
2016-02-06 01:17:30 +03:00
++ poke-helm-init (wrap poke-init):from-helm :: XX used?
2015-09-17 02:40:53 +03:00
++ 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
2015-12-08 03:57:54 +03:00
++ poke-helm-deset (wrap poke-deset):from-helm
++ poke-helm-serve (wrap poke-serve):from-helm
2015-09-17 02:40:53 +03:00
++ poke-helm-send-hi (wrap poke-send-hi):from-helm
++ poke-helm-send-ask (wrap poke-send-ask):from-helm
2015-09-17 02:40:53 +03:00
++ poke-helm-verb (wrap poke-verb):from-helm
++ poke-helm-begin (wrap poke-begin):from-helm
2016-04-11 05:23:29 +03:00
++ poke-helm-spawn (wrap poke-spawn):from-helm
2015-09-17 02:40:53 +03:00
++ poke-hood-sync (wrap poke-sync):from-kiln
2016-02-26 02:19:44 +03:00
++ poke-hood-init-sync (wrap poke-init-sync):from-kiln
2016-05-07 02:21:29 +03:00
++ poke-kiln-info (wrap poke-info):from-kiln
2015-09-17 02:40:53 +03:00
++ poke-kiln-label (wrap poke-label):from-kiln
++ poke-kiln-merge (wrap poke-merge):from-kiln
++ poke-kiln-cancel (wrap poke-cancel):from-kiln
++ poke-kiln-mount (wrap poke-mount):from-kiln
++ poke-kiln-rm (wrap poke-rm):from-kiln
++ poke-kiln-schedule (wrap poke-schedule):from-kiln
2016-01-07 01:08:46 +03:00
++ poke-kiln-track (wrap poke-track):from-kiln
2015-09-17 02:40:53 +03:00
++ poke-kiln-sync (wrap poke-sync):from-kiln
++ poke-kiln-syncs (wrap poke-syncs):from-kiln
2015-09-17 02:40:53 +03:00
++ poke-kiln-start-autoload (wrap poke-start-autoload):from-kiln
++ poke-kiln-autoload (wrap poke-autoload):from-kiln
2015-09-26 03:23:06 +03:00
++ poke-kiln-overload (wrap poke-overload):from-kiln
2015-09-17 02:40:53 +03:00
++ poke-kiln-unmount (wrap poke-unmount):from-kiln
++ poke-kiln-unsync (wrap poke-unsync):from-kiln
++ poke-write-sec-atom (wrap poke-sec-atom):from-write
2016-02-12 02:29:52 +03:00
++ poke-write-paste (wrap poke-paste):from-write
++ poke-write-comment (wrap poke-comment):from-write
++ poke-write-fora-post (wrap poke-fora-post):from-write
++ poke-write-plan-info (wrap poke-plan-info):from-write
++ poke-write-plan-account (wrap poke-plan-account):from-write
2016-02-12 02:29:52 +03:00
++ poke-write-tree (wrap poke-tree):from-write
++ poke-write-wipe (wrap poke-wipe):from-write
2015-09-17 02:40:53 +03:00
++ 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-autoload (wrap take-writ-autoload):from-kiln
++ writ-kiln-sync (wrap take-writ-sync):from-kiln
2015-05-11 21:05:14 +03:00
--