mirror of
https://github.com/urbit/shrub.git
synced 2024-12-01 06:35:32 +03:00
hoon: bat/net to bas/fas
This commit is contained in:
parent
250f4e3130
commit
510fb6b394
@ -534,7 +534,7 @@
|
||||
::
|
||||
++ tag |*(a=@tas (cold a (jest a))) ::TODO into stdlib
|
||||
++ ship ;~(pfix sig fed:ag)
|
||||
++ path ;~(pfix net ;~(plug urs:ab (easy ~))) ::NOTE short only, tmp
|
||||
++ path ;~(pfix fas ;~(plug urs:ab (easy ~))) ::NOTE short only, tmp
|
||||
:: +mang: un/managed indicator prefix
|
||||
::
|
||||
++ mang
|
||||
|
@ -154,7 +154,7 @@
|
||||
==
|
||||
==
|
||||
::
|
||||
;~ pfix net
|
||||
;~ pfix fas
|
||||
;~ pose
|
||||
(parse-variable (cold %sur hep) ;~(pfix gap parse-cables))
|
||||
(parse-variable (cold %lib lus) ;~(pfix gap parse-cables))
|
||||
@ -168,8 +168,8 @@
|
||||
++ parse-sink
|
||||
;~ pose
|
||||
;~(plug (cold %file tar) parse-beam)
|
||||
;~(plug (cold %flat pat) (most net sym))
|
||||
;~(plug (cold %pill dot) (most net sym))
|
||||
;~(plug (cold %flat pat) (most fas sym))
|
||||
;~(plug (cold %pill dot) (most fas sym))
|
||||
;~(plug (cold %http lus) (stag %post parse-url))
|
||||
;~(plug (cold %http hep) (stag %put parse-url))
|
||||
(stag %show (cook $?($1 $2 $3 $4 $5) (cook lent (stun [1 5] wut))))
|
||||
@ -217,7 +217,7 @@
|
||||
;~ pose
|
||||
;~ plug
|
||||
;~(pfix sig fed:ag)
|
||||
;~(pose ;~(pfix net sym) (easy default-app))
|
||||
;~(pose ;~(pfix fas sym) (easy default-app))
|
||||
==
|
||||
%+ stag our
|
||||
;~(pose sym (easy default-app))
|
||||
@ -252,7 +252,7 @@
|
||||
auri:de-purl:html
|
||||
::
|
||||
++ parse-model ;~(plug parse-server parse-config)
|
||||
++ parse-server (stag 0 (most net sym))
|
||||
++ parse-server (stag 0 (most fas sym))
|
||||
++ parse-hoon tall:hoon-parser
|
||||
::
|
||||
++ parse-rood
|
||||
|
@ -24,8 +24,8 @@
|
||||
=/ parsed=(unit (list coin))
|
||||
%+ rust link
|
||||
;~ pose
|
||||
;~(pfix net (more net nuck:so))
|
||||
(more net nuck:so)
|
||||
;~(pfix fas (more fas nuck:so))
|
||||
(more fas nuck:so)
|
||||
==
|
||||
?~ parsed
|
||||
link
|
||||
|
@ -81,7 +81,7 @@
|
||||
++ derivation-path
|
||||
;~ pfix
|
||||
;~(pose (jest 'm/') (easy ~))
|
||||
%+ most net
|
||||
%+ most fas
|
||||
;~ pose
|
||||
%+ cook
|
||||
|=(i=@ (add i (bex 31)))
|
||||
|
@ -11,7 +11,7 @@
|
||||
=/ parse-path
|
||||
%+ cook
|
||||
|=(p=path (slag 3 p))
|
||||
(ifix [net (jest '::')] (more net urs:ab))
|
||||
(ifix [fas (jest '::')] (more fas urs:ab))
|
||||
=/ parse-full
|
||||
;~(plug parse-path ;~(sfix ;~((glue dot) parse-pair parse-pair) gar))
|
||||
(rust tape parse-full)
|
||||
|
@ -17,19 +17,19 @@
|
||||
:: parses the zuse version, eg "/? 309"
|
||||
::
|
||||
;~ pose
|
||||
(ifix [;~(plug net wut gap) gap] dem)
|
||||
(ifix [;~(plug fas wut gap) gap] dem)
|
||||
(easy zuse)
|
||||
==
|
||||
:: pareses the structures, eg "/- types"
|
||||
::
|
||||
;~ pose
|
||||
(ifix [;~(plug net hep gap) gap] (most ;~(plug com gaw) cable))
|
||||
(ifix [;~(plug fas hep gap) gap] (most ;~(plug com gaw) cable))
|
||||
(easy ~)
|
||||
==
|
||||
:: parses the libraries, eg "/+ lib1, lib2"
|
||||
::
|
||||
;~ pose
|
||||
(ifix [;~(plug net lus gap) gap] (most ;~(plug com gaw) cable))
|
||||
(ifix [;~(plug fas lus gap) gap] (most ;~(plug com gaw) cable))
|
||||
(easy ~)
|
||||
==
|
||||
::
|
||||
@ -42,7 +42,7 @@
|
||||
++ beam
|
||||
%+ sear de-beam:format
|
||||
;~ pfix
|
||||
net
|
||||
fas
|
||||
(sear plex (stag %clsg poor)):hoon-parser
|
||||
==
|
||||
:: +cable: parses a +^cable, a reference to something on the filesystem
|
||||
@ -70,7 +70,7 @@
|
||||
|%
|
||||
++ apex
|
||||
%+ knee *^crane |. ~+
|
||||
;~ pfix net
|
||||
;~ pfix fas
|
||||
;~ pose
|
||||
:: `/~` hoon literal
|
||||
::
|
||||
@ -110,10 +110,10 @@
|
||||
(stag %fstr ;~(pfix tar subcrane))
|
||||
:: `/!mark/ evaluate as hoon, then pass through mark
|
||||
::
|
||||
(stag %fszp ;~(pfix zap ;~(sfix sym net)))
|
||||
(stag %fszp ;~(pfix zap ;~(sfix sym fas)))
|
||||
:: `/mark/` passes current path through :mark
|
||||
::
|
||||
(stag %fszy ;~(sfix sym net))
|
||||
(stag %fszy ;~(sfix sym fas))
|
||||
==
|
||||
==
|
||||
:: +parse-alts: parse a set of alternatives
|
||||
@ -140,7 +140,7 @@
|
||||
%+ wide-or-tall
|
||||
fail
|
||||
=- ;~(sfix (star -) gap duz)
|
||||
;~(pfix gap net ;~(plug static-path subcrane))
|
||||
;~(pfix gap fas ;~(plug static-path subcrane))
|
||||
:: +parse-pipe: parses a pipe of mark conversions
|
||||
::
|
||||
++ parse-pipe
|
||||
@ -188,11 +188,11 @@
|
||||
:: +static-path: parses a path
|
||||
::
|
||||
++ static-path
|
||||
(sear plex (stag %clsg (more net hasp))):hoon-parser
|
||||
(sear plex (stag %clsg (more fas hasp))):hoon-parser
|
||||
:: +late-bound-path: a path whose time varies
|
||||
::
|
||||
++ late-bound-path
|
||||
;~ pfix net
|
||||
;~ pfix fas
|
||||
%+ cook |=(a=truss a)
|
||||
=> hoon-parser
|
||||
;~ plug
|
||||
|
@ -32,7 +32,7 @@
|
||||
%- su
|
||||
;~ plug
|
||||
sym
|
||||
;~(pfix col (more net (cook crip (star ;~(less net prn)))))
|
||||
;~(pfix col (more fas (cook crip (star ;~(less fas prn)))))
|
||||
==
|
||||
listen-api+(su ;~(plug sym ;~(pfix col sym)))
|
||||
export+so
|
||||
@ -54,7 +54,7 @@
|
||||
%- su
|
||||
;~ plug
|
||||
sym
|
||||
;~(pfix col (more net (cook crip (star ;~(less net prn)))))
|
||||
;~(pfix col (more fas (cook crip (star ;~(less fas prn)))))
|
||||
==
|
||||
command+so
|
||||
app+(su sym)
|
||||
|
@ -49,10 +49,10 @@
|
||||
(key-val (jest 'description: ') (cook crip (star qit)))
|
||||
%+ key-val (jest 'comments: ')
|
||||
(cook |=(a=@ =(%on a)) ;~(pose (jest %on) (jest %off)))
|
||||
(key-val (jest 'writers: ') ;~(pfix net (more net urs:ab)))
|
||||
(key-val (jest 'writers: ') ;~(pfix fas (more fas urs:ab)))
|
||||
;~ pose
|
||||
(key-val (jest 'subscribers: ') ;~(pfix net (more net urs:ab)))
|
||||
;~(pfix (jest 'subscribers: ') ;~(pfix net (more net urs:ab)))
|
||||
(key-val (jest 'subscribers: ') ;~(pfix fas (more fas urs:ab)))
|
||||
;~(pfix (jest 'subscribers: ') ;~(pfix fas (more fas urs:ab)))
|
||||
==
|
||||
==
|
||||
++ both-parser
|
||||
|
@ -5642,7 +5642,7 @@
|
||||
==
|
||||
++ gaw (cold ~ (star ;~(pose vul gah))) :: classic white
|
||||
++ gay ;~(pose gap (easy ~)) ::
|
||||
++ gon ;~(pose ;~(plug bat gay net) (easy ~)) :: long numbers \ /
|
||||
++ gon ;~(pose ;~(plug bas gay fas) (easy ~)) :: long numbers \ /
|
||||
++ gul ;~(pose (cold 2 gal) (cold 3 gar)) :: axis syntax < >
|
||||
++ hex (bass 16 (most gon hit)) :: hex to atom
|
||||
++ hig (shim 'A' 'Z') :: uppercase
|
||||
@ -5683,8 +5683,8 @@
|
||||
;~(less ;~(plug (just `@`10) soz) (just `@`10))
|
||||
==
|
||||
++ qit ;~ pose :: chars in a cord
|
||||
;~(less bat soq prn)
|
||||
;~(pfix bat ;~(pose bat soq mes)) :: escape chars
|
||||
;~(less bas soq prn)
|
||||
;~(pfix bas ;~(pose bas soq mes)) :: escape chars
|
||||
==
|
||||
++ qut ;~ simu soq :: cord
|
||||
;~ pose
|
||||
@ -5799,7 +5799,7 @@
|
||||
(cook tuft (ifix [sig dot] hex))
|
||||
;~(pfix sig ;~(pose sig dot))
|
||||
==
|
||||
++ voy ;~(pfix bat ;~(pose bat soq bix))
|
||||
++ voy ;~(pfix bas ;~(pose bas soq bix))
|
||||
--
|
||||
++ ag
|
||||
|%
|
||||
@ -6330,7 +6330,7 @@
|
||||
++ spat |=(pax/path (crip (spud pax))) :: render path to cord
|
||||
++ spud |=(pax/path ~(ram re (smyt pax))) :: render path to tape
|
||||
++ stab :: parse cord to path
|
||||
=+ fel=;~(pfix net (more net urs:ab))
|
||||
=+ fel=;~(pfix fas (more fas urs:ab))
|
||||
|=(zep/@t `path`(rash zep fel))
|
||||
::
|
||||
:::: 4n: virtualization
|
||||
@ -12131,7 +12131,7 @@
|
||||
++ gash %+ cook :: parse path
|
||||
|= a/(list tyke) ^- tyke
|
||||
?~(a ~ (weld i.a $(a t.a)))
|
||||
(more net limp)
|
||||
(more fas limp)
|
||||
++ gasp ;~ pose :: parse =path= etc.
|
||||
%+ cook
|
||||
|=({a/tyke b/tyke c/tyke} :(weld a b c))
|
||||
@ -12156,7 +12156,7 @@
|
||||
|= {a/(list) b/tyke}
|
||||
?~ a b
|
||||
$(a t.a, b [`[%sand %tas %$] b])
|
||||
;~(plug (star net) gasp)
|
||||
;~(plug (star fas) gasp)
|
||||
++ mota %+ cook
|
||||
|=({a/tape b/tape} (rap 3 (weld a b)))
|
||||
;~(plug (star low) (star hig))
|
||||
@ -12334,7 +12334,7 @@
|
||||
++ porc
|
||||
;~ plug
|
||||
(cook |=(a/(list) (lent a)) (star cen))
|
||||
;~(pfix net gash)
|
||||
;~(pfix fas gash)
|
||||
==
|
||||
::
|
||||
++ rump
|
||||
@ -12344,7 +12344,7 @@
|
||||
;~(plug rope ;~(pose (stag ~ wede) (easy ~)))
|
||||
::
|
||||
++ rood
|
||||
;~ pfix net
|
||||
;~ pfix fas
|
||||
(stag %clsg poor)
|
||||
==
|
||||
::
|
||||
@ -12542,7 +12542,7 @@
|
||||
;~ plug
|
||||
(punt ;~(plug (cold %id hax) (cook trip sym)))
|
||||
(cook en-class (star ;~(plug (cold %class dot) sym)))
|
||||
(punt ;~(plug ;~(pose (cold %href net) (cold %src pat)) soil))
|
||||
(punt ;~(plug ;~(pose (cold %href fas) (cold %src pat)) soil))
|
||||
(easy ~)
|
||||
==
|
||||
::
|
||||
@ -13391,7 +13391,7 @@
|
||||
:- '*'
|
||||
(cold [%base %noun] tar)
|
||||
:- '/'
|
||||
;~(pfix net (stag %loop ;~(pose (cold %$ buc) sym)))
|
||||
;~(pfix fas (stag %loop ;~(pose (cold %$ buc) sym)))
|
||||
:- '@'
|
||||
;~(pfix pat (stag %base (stag %atom mota)))
|
||||
:- '?'
|
||||
@ -13426,7 +13426,7 @@
|
||||
==
|
||||
:- ['a' 'z']
|
||||
;~ pose
|
||||
(stag %bsts ;~(plug sym ;~(pfix ;~(pose net tis) wyde)))
|
||||
(stag %bsts ;~(plug sym ;~(pfix ;~(pose fas tis) wyde)))
|
||||
(stag %like (most col rope))
|
||||
==
|
||||
==
|
||||
@ -13530,7 +13530,7 @@
|
||||
;~ pfix col
|
||||
;~ pose
|
||||
(stag %mccl (ifix [pal par] (most ace wide)))
|
||||
;~(pfix net (stag %mcnt wide))
|
||||
;~(pfix fas (stag %mcnt wide))
|
||||
==
|
||||
==
|
||||
:- '='
|
||||
@ -13800,7 +13800,7 @@
|
||||
['$' (rune buc %sgbs expf)]
|
||||
['_' (rune cab %sgcb expb)]
|
||||
['%' (rune cen %sgcn hind)]
|
||||
['/' (rune net %sgnt hine)]
|
||||
['/' (rune fas %sgnt hine)]
|
||||
['<' (rune gal %sgld hinb)]
|
||||
['>' (rune gar %sgbn hinb)]
|
||||
['+' (rune lus %sgls hinc)]
|
||||
@ -13815,7 +13815,7 @@
|
||||
%- stew
|
||||
^. stet ^. limo
|
||||
:~ [':' (rune col %mccl expi)]
|
||||
['/' (rune net %mcnt expa)]
|
||||
['/' (rune fas %mcnt expa)]
|
||||
['<' (rune gal %mcgl exp1)]
|
||||
['~' (rune sig %mcsg expi)]
|
||||
[';' (rune mic %mcmc exqc)]
|
||||
@ -13830,7 +13830,7 @@
|
||||
['?' (rune wut %tswt expw)]
|
||||
['^' (rune ket %tskt expt)]
|
||||
[':' (rune col %tscl expp)]
|
||||
['/' (rune net %tsnt expo)]
|
||||
['/' (rune fas %tsnt expo)]
|
||||
[';' (rune mic %tsmc expo)]
|
||||
['<' (rune gal %tsld expb)]
|
||||
['>' (rune gar %tsbn expb)]
|
||||
@ -14287,9 +14287,7 @@
|
||||
term
|
||||
[%name term %spec u.unit %base %noun]
|
||||
;~ plug sym
|
||||
:: XX: net deprecated
|
||||
::
|
||||
(punt ;~(pfix ;~(pose net tis) wyde))
|
||||
(punt ;~(pfix ;~(pose fas tis) wyde))
|
||||
==
|
||||
::
|
||||
%+ cook
|
||||
@ -14307,7 +14305,7 @@
|
||||
++ wede :: wide bulb
|
||||
:: XX: lus deprecated
|
||||
::
|
||||
;~(pfix ;~(pose lus net) wide)
|
||||
;~(pfix ;~(pose lus fas) wide)
|
||||
++ wide :: full wide form
|
||||
%+ knee *hoon
|
||||
|.(~+((wart ;~(pose expression:(norm |) long apex:(sail |)))))
|
||||
|
@ -882,19 +882,19 @@
|
||||
:: parses the zuse version, eg "/? 309"
|
||||
::
|
||||
;~ pose
|
||||
(ifix [;~(plug net wut gap) gap] dem)
|
||||
(ifix [;~(plug fas wut gap) gap] dem)
|
||||
(easy zuse)
|
||||
==
|
||||
:: pareses the structures, eg "/- types"
|
||||
::
|
||||
;~ pose
|
||||
(ifix [;~(plug net hep gap) gap] (most ;~(plug com gaw) cable))
|
||||
(ifix [;~(plug fas hep gap) gap] (most ;~(plug com gaw) cable))
|
||||
(easy ~)
|
||||
==
|
||||
:: parses the libraries, eg "/+ lib1, lib2"
|
||||
::
|
||||
;~ pose
|
||||
(ifix [;~(plug net lus gap) gap] (most ;~(plug com gaw) cable))
|
||||
(ifix [;~(plug fas lus gap) gap] (most ;~(plug com gaw) cable))
|
||||
(easy ~)
|
||||
==
|
||||
::
|
||||
@ -907,7 +907,7 @@
|
||||
++ beam
|
||||
%+ sear de-beam
|
||||
;~ pfix
|
||||
net
|
||||
fas
|
||||
(sear plex (stag %clsg poor)):hoon-parser
|
||||
==
|
||||
:: +cable: parses a +^cable, a reference to something on the filesystem
|
||||
@ -935,7 +935,7 @@
|
||||
|%
|
||||
++ apex
|
||||
%+ knee *^crane |. ~+
|
||||
;~ pfix net
|
||||
;~ pfix fas
|
||||
;~ pose
|
||||
:: `/~` hoon literal
|
||||
::
|
||||
@ -975,10 +975,10 @@
|
||||
(stag %fstr ;~(pfix tar subcrane))
|
||||
:: `/!mark/ evaluate as hoon, then pass through mark
|
||||
::
|
||||
(stag %fszp ;~(pfix zap ;~(sfix sym net)))
|
||||
(stag %fszp ;~(pfix zap ;~(sfix sym fas)))
|
||||
:: `/mark/` passes current path through :mark
|
||||
::
|
||||
(stag %fszy ;~(sfix sym net))
|
||||
(stag %fszy ;~(sfix sym fas))
|
||||
==
|
||||
==
|
||||
:: +parse-alts: parse a set of alternatives
|
||||
@ -1005,7 +1005,7 @@
|
||||
%+ wide-or-tall
|
||||
fail
|
||||
=- ;~(sfix (star -) gap duz)
|
||||
;~(pfix gap net ;~(plug static-path subcrane))
|
||||
;~(pfix gap fas ;~(plug static-path subcrane))
|
||||
:: +parse-pipe: parses a pipe of mark conversions
|
||||
::
|
||||
++ parse-pipe
|
||||
@ -1053,11 +1053,11 @@
|
||||
:: +static-path: parses a path
|
||||
::
|
||||
++ static-path
|
||||
(sear plex (stag %clsg (more net hasp))):hoon-parser
|
||||
(sear plex (stag %clsg (more fas hasp))):hoon-parser
|
||||
:: +late-bound-path: a path whose time varies
|
||||
::
|
||||
++ late-bound-path
|
||||
;~ pfix net
|
||||
;~ pfix fas
|
||||
%+ cook |=(a=truss a)
|
||||
=> hoon-parser
|
||||
;~ plug
|
||||
|
@ -6125,7 +6125,7 @@
|
||||
[(rash a fel) b]
|
||||
:: :: ++pa:dejs:format
|
||||
++ pa :: string as path
|
||||
(su ;~(pfix net (more net urs:ab)))
|
||||
(su ;~(pfix fas (more fas urs:ab)))
|
||||
:: :: ++pe:dejs:format
|
||||
++ pe :: prefix
|
||||
|* {pre/* wit/fist}
|
||||
@ -6696,7 +6696,7 @@
|
||||
=* wow `(map @t @)`(malt lip)
|
||||
(sear ~(get by wow) low)
|
||||
=* tuf ;~(pfix (just 'u') (cook tuft qix:ab))
|
||||
;~(pose doq net soq bas loo tuf)
|
||||
;~(pose doq fas soq bas loo tuf)
|
||||
==
|
||||
:: :: ++expo:de-json:html
|
||||
++ expo :: exponent
|
||||
@ -7032,7 +7032,7 @@
|
||||
:: :: ++apat:de-purl:html
|
||||
++ apat :: 2396 abs_path
|
||||
%+ cook deft
|
||||
;~(pfix net (more net smeg))
|
||||
;~(pfix fas (more fas smeg))
|
||||
:: :: ++aurf:de-purl:html
|
||||
++ aurf :: 2396 with fragment
|
||||
%+ cook |~(a/purf a)
|
||||
@ -7059,7 +7059,7 @@
|
||||
:: :: ++htts:de-purl:html
|
||||
++ htts :: scheme
|
||||
%+ sear ~(get by (malt `(list (pair term ?))`[http+| https+& ~]))
|
||||
;~(sfix scem ;~(plug col net net))
|
||||
;~(sfix scem ;~(plug col fas fas))
|
||||
:: :: ++cock:de-purl:html
|
||||
++ cock :: cookie
|
||||
%+ most ;~(plug mic ace)
|
||||
@ -7091,10 +7091,10 @@
|
||||
(cold ' ' (just '+'))
|
||||
:: :: ++pque:de-purl:html
|
||||
++ pque :: 3986 query char
|
||||
;~(pose pcar net wut)
|
||||
;~(pose pcar fas wut)
|
||||
:: :: ++pquo:de-purl:html
|
||||
++ pquo :: normal query char
|
||||
;~(pose pure pesc pold net wut col com)
|
||||
;~(pose pure pesc pold fas wut col com)
|
||||
:: :: ++pure:de-purl:html
|
||||
++ pure :: 2396 unreserved
|
||||
;~(pose aln hep dot cab sig)
|
||||
|
Loading…
Reference in New Issue
Block a user