pkg: move /lib/dill into base-dev, include it

Landscape desk needed it, but didn't have it.
This commit is contained in:
fang 2022-02-20 15:35:55 -06:00
parent bbb1a716bf
commit c4f38032ce
No known key found for this signature in database
GPG Key ID: EB035760C1BBA972
3 changed files with 95 additions and 93 deletions

View File

@ -1,93 +0,0 @@
:: dill: utilities for dill's data structures
::
=, dill
|%
++ enjs
|%
++ blit
|= =blit:dill
^- json
=, enjs:format
%+ frond -.blit
?- -.blit
%bel b+&
%clr b+&
%hop ?@ p.blit (numb p.blit)
(pairs 'r'^(numb r.p.blit) 'c'^(numb c.p.blit) ~)
%put a+(turn p.blit |=(c=@c s+(tuft c)))
%nel b+&
%url s+p.blit
%wyp b+&
::
%sag
%- pairs
:~ 'path'^(path p.blit)
'file'^s+(en:base64:mimes:html (as-octs:mimes:html (jam q.blit)))
==
::
%sav
%- pairs
:~ 'path'^(path p.blit)
'file'^s+(en:base64:mimes:html (as-octs:mimes:html q.blit))
==
::
%klr
:- %a
%+ turn p.blit
|= [=stye text=(list @c)]
%- pairs
:~ 'text'^a+(turn text |=(c=@c s+(tuft c)))
::
:- 'stye'
%- pairs
|^ :~ 'back'^(color p.q.stye)
'fore'^(color q.q.stye)
'deco'^a+(turn ~(tap in p.stye) |=(d=deco ?~(d ~ s+d)))
==
++ color
|= =tint
?@ tint ?~(tint ~ s+tint)
=, tint
(pairs r+(numb r) g+(numb g) b+(numb b) ~)
--
==
==
--
::
++ dejs
|%
++ belt
|= jon=json
^- belt:dill
?: ?=([%s *] jon)
(taft p.jon)
=, dejs:format
%. jon
%- of
|^ :* mod+(ot 'mod'^mod 'key'^bot ~)
txt+(ar (cu taft so))
bol
==
::
++ bol
:~ aro+(su (perk %d %l %r %u ~))
bac+ul
del+ul
hit+(ot 'r'^ni 'c'^ni ~)
ret+ul
==
::
++ bot
|= j=json
^- bolt:dill
?+ j !!
[%s *] (taft p.j)
[%o *] ((of bol) j)
==
::
++ mod
|= j=json
((su (perk %ctl %met %hyp ~)) j)
--
--
--

1
pkg/arvo/lib/dill.hoon Symbolic link
View File

@ -0,0 +1 @@
../../base-dev/lib/dill.hoon

View File

@ -0,0 +1,93 @@
:: dill: utilities for dill's data structures
::
=, dill
|%
++ enjs
|%
++ blit
|= =blit:dill
^- json
=, enjs:format
%+ frond -.blit
?- -.blit
%bel b+&
%clr b+&
%hop ?@ p.blit (numb p.blit)
(pairs 'r'^(numb r.p.blit) 'c'^(numb c.p.blit) ~)
%put a+(turn p.blit |=(c=@c s+(tuft c)))
%nel b+&
%url s+p.blit
%wyp b+&
::
%sag
%- pairs
:~ 'path'^(path p.blit)
'file'^s+(en:base64:mimes:html (as-octs:mimes:html (jam q.blit)))
==
::
%sav
%- pairs
:~ 'path'^(path p.blit)
'file'^s+(en:base64:mimes:html (as-octs:mimes:html q.blit))
==
::
%klr
:- %a
%+ turn p.blit
|= [=stye text=(list @c)]
%- pairs
:~ 'text'^a+(turn text |=(c=@c s+(tuft c)))
::
:- 'stye'
%- pairs
|^ :~ 'back'^(color p.q.stye)
'fore'^(color q.q.stye)
'deco'^a+(turn ~(tap in p.stye) |=(d=deco ?~(d ~ s+d)))
==
++ color
|= =tint
?@ tint ?~(tint ~ s+tint)
=, tint
(pairs r+(numb r) g+(numb g) b+(numb b) ~)
--
==
==
--
::
++ dejs
|%
++ belt
|= jon=json
^- belt:dill
?: ?=([%s *] jon)
(taft p.jon)
=, dejs:format
%. jon
%- of
|^ :* mod+(ot 'mod'^mod 'key'^bot ~)
txt+(ar (cu taft so))
bol
==
::
++ bol
:~ aro+(su (perk %d %l %r %u ~))
bac+ul
del+ul
hit+(ot 'r'^ni 'c'^ni ~)
ret+ul
==
::
++ bot
|= j=json
^- bolt:dill
?+ j !!
[%s *] (taft p.j)
[%o *] ((of bol) j)
==
::
++ mod
|= j=json
((su (perk %ctl %met %hyp ~)) j)
--
--
--

1
pkg/landscape/lib/dill.hoon Symbolic link
View File

@ -0,0 +1 @@
../../base-dev/lib/dill.hoon