urbit/mar/sole/effect.hoon
Philip C Monk c9539452e2 Merge remote-tracking branch 'origin/newunix'
Conflicts:
	urb/urbit.pill
	urb/zod/base/mar/bit-accounts.hoon
	urb/zod/base/mar/bit-addr-made.hoon
	urb/zod/base/mar/bit-addr-request.hoon
	urb/zod/base/mar/bit-api-call.hoon
	urb/zod/base/mar/bit-get-token.hoon
	urb/zod/base/mar/bit-transaction.hoon
	urb/zod/base/mar/bit/accounts.hoon
	urb/zod/base/mar/bit/addr-made.hoon
	urb/zod/base/mar/bit/addr-request.hoon
	urb/zod/base/mar/bit/api-call.hoon
	urb/zod/base/mar/bit/get-token.hoon
	urb/zod/base/mar/bit/transaction.hoon
	urb/zod/base/mar/cloud-auth.hoon
	urb/zod/base/mar/cloud-secret.hoon
	urb/zod/base/mar/cloud/auth.hoon
	urb/zod/base/mar/cloud/secret.hoon
	urb/zod/base/mar/dill-belt.hoon
	urb/zod/base/mar/dill-blit.hoon
	urb/zod/base/mar/dill/belt.hoon
	urb/zod/base/mar/dill/blit.hoon
	urb/zod/base/mar/oct3-move.hoon
	urb/zod/base/mar/oct3-update.hoon
	urb/zod/base/mar/oct3/move.hoon
	urb/zod/base/mar/oct3/update.hoon
	urb/zod/base/mar/oct4-move.hoon
	urb/zod/base/mar/oct4-update.hoon
	urb/zod/base/mar/oct4/move.hoon
	urb/zod/base/mar/oct4/update.hoon
	urb/zod/base/mar/sole-action.hoon
	urb/zod/base/mar/sole-effect.hoon
	urb/zod/base/mar/sole/action.hoon
	urb/zod/base/mar/sole/effect.hoon
	urb/zod/base/mar/talk-command.hoon
	urb/zod/base/mar/talk-report.hoon
	urb/zod/base/mar/talk/command.hoon
	urb/zod/base/mar/talk/report.hoon
	urb/zod/mar/bit-accounts.hoon
	urb/zod/mar/bit-addr-made.hoon
	urb/zod/mar/bit-addr-request.hoon
	urb/zod/mar/bit-api-call.hoon
	urb/zod/mar/bit-get-token.hoon
	urb/zod/mar/bit-transaction.hoon
	urb/zod/mar/cloud-auth.hoon
	urb/zod/mar/cloud-auth/door.hook
	urb/zod/mar/cloud-secret.hoon
	urb/zod/mar/cloud-secret/door.hook
	urb/zod/mar/dill-belt.hoon
	urb/zod/mar/dill-blit.hoon
	urb/zod/mar/oct3-move.hoon
	urb/zod/mar/oct3-update.hoon
	urb/zod/mar/oct4-move.hoon
	urb/zod/mar/oct4-update.hoon
	urb/zod/mar/sole-action.hoon
	urb/zod/mar/sole-effect.hoon
	urb/zod/mar/talk-command.hoon
	urb/zod/mar/talk-report.hoon
2015-06-23 19:28:46 -04:00

56 lines
1.4 KiB
Plaintext

::
:::: /hoon/sole-effect/mar
::
/? 314
/- *sole
!:
::::
::
|%
++ mar-sole-change :: XX dependency
|_ cha=sole-change
++ grow
|% ++ json
^- ^json
=+ cha
=< (jobe ted/(. ted) ler/a/~[(jone own.ler) (jone his.ler)] ~)
|= det=sole-edit
?- -.det
%nop [%s 'nop']
%mor [%a (turn p.det ..$)]
%del (joba %del (jone p.det))
%set (joba %set (jape (tufa p.det)))
%ins (joba %ins (jobe at/(jone p.det) cha/s/(tuft q.det) ~))
==
--
--
++ wush
|= [wid=@u tan=tang]
^- tape
=+ rolt=|=(a=wall `tape`?~(a ~ ?~(t.a i.a :(weld i.a "\0a" $(a t.a)))))
(rolt (turn (flop tan) |=(a=tank (rolt (wash 0^wid a)))))
::
--
!:
|_ sef=sole-effect
::
++ grab :: convert from
|%
++ noun sole-effect :: clam from %noun
--
++ grow
|%
++ json
^- ^json
?+ -.sef ~|(unsupported-effect/-.sef !!)
%mor [%a (turn p.sef |=(a=sole-effect json(sef a)))]
%err (joba %hop (jone p.sef))
%txt (joba %txt (jape p.sef))
%tan (joba %tan (jape (wush 160 p.sef)))
%det (joba %det json:~(grow mar-sole-change +.sef))
%pro (joba %pro (jobe vis/b/vis.sef tag/s/tag.sef cad/(jape cad.sef) ~))
?(%bel %clr %nex) (joba %act %s -.sef)
==
--
--