diff --git a/pkg/arvo/app/neo.hoon b/pkg/arvo/app/neo.hoon index 9790baff3f..b81ea2ba1a 100644 --- a/pkg/arvo/app/neo.hoon +++ b/pkg/arvo/app/neo.hoon @@ -445,7 +445,10 @@ (on-move move) ?> ?=(%noun mark) ?: =(%clay q.vase) - copy-clay + (copy-clay ~) + ?: ?=([%file *] q.vase) + =+ ;;(=path +.q.vase) + (copy-clay `path) ?: ?=([%dbug veb=?] q.vase) ?> =(our src):bowl %- (print-dbug veb.q.vase) @@ -811,10 +814,8 @@ ++ vale ^- ? - ~& vale-con/stud =; rap=(trap ?) =/ res (mule rap) - ~& vale-con-done/stud ?: ?=(%& -.res) p.res %- (slog leaf/"mark-vale" p.res) @@ -929,8 +930,12 @@ (need ref) :: ++ copy-clay + |= just=(unit path) |^ ^+ run - =+ .^(paths=(list path) %ct root) + =/ paths=(list path) + ?~ just + .^((list path) %ct root) + ~[u.just] :: =. paths :: %+ sort paths :: |= [a=path b=path] @@ -972,7 +977,6 @@ ?~ imps run loop(imps ~, paths imps) - ~& reading/i.paths =^ pat=(unit path) run (read-file i.paths) ?~ pat @@ -1027,7 +1031,6 @@ run =* do-con ~(do con q.u.pos) ?. vale:do-con - ~& con-vale/q.u.pos run =. fiesta register:do-con run @@ -1087,7 +1090,7 @@ =+ .^(src=@t %cx (welp root pax)) =/ =file:ford ~| parsing/pax - (scan (trip src) (rein:ford pax)) + (scan (trip src) (rein:ford [our.bowl (pave:neo pax)])) =/ has-imports=? ?& (levy pro.file |=(pro:ford ~(exists pro stud))) (levy lib.file |=(lib:ford ~(exists lib name))) diff --git a/pkg/arvo/lib/ford-face.hoon b/pkg/arvo/lib/ford-face.hoon index 81ff6b455b..53a3b58c3b 100644 --- a/pkg/arvo/lib/ford-face.hoon +++ b/pkg/arvo/lib/ford-face.hoon @@ -14,7 +14,6 @@ ~ =/ face=@tas (get-face bowl) :- ~ - =- ((slog leaf/"attaching face" (sell -) ~) -) u.sut(p [%face (get-face bowl) p.u.sut]) +$ state [cache=(unit vase) ~] -- diff --git a/pkg/arvo/lib/ford-same.hoon b/pkg/arvo/lib/ford-same.hoon index c94f21f872..7922d8c69e 100644 --- a/pkg/arvo/lib/ford-same.hoon +++ b/pkg/arvo/lib/ford-same.hoon @@ -31,9 +31,6 @@ ^- (quip card:neo vase) =| sta=[cache=(unit vase) ~] =. cache.sta (get-output:ford:neo bowl %src) - - %- ?~ cache.sta (slog leaf/"no link" ~) - (slog leaf/"link" (sell u.cache.sta) ~) `!>(sta) -- -- diff --git a/pkg/arvo/neo/src/std/imp/circle.hoon b/pkg/arvo/neo/src/std/imp/circle.hoon new file mode 100644 index 0000000000..4ccd763b07 --- /dev/null +++ b/pkg/arvo/neo/src/std/imp/circle.hoon @@ -0,0 +1,33 @@ +/@ diff=circle-diff +|% +++ state %sig +++ poke (sy %circle-diff ~) +++ kids + %- ~(gas by *kids:neo) + :~ [~[|/%p] %sig %sig] + == +++ deps *deps:neo +++ form + ^- form:neo + |_ [=bowl:neo =ever:neo state-vase=vase *] + ++ poke + |= [=stud:neo vax=vase] + ?> ?=(%circle-diff stud) + =+ !<(=diff vax) + :_ state-vase + ?- -.diff + %add + %+ turn ~(tap by p.diff) + |= [=ship =made:neo] + [(snoc here.bowl p/ship) %make made] + :: + %del + %+ turn ~(tap in p.diff) + |= =ship + [(snoc here.bowl p/ship) %tomb ~] + == + ++ init + |= vas=(unit vase) + `*vase + -- +-- diff --git a/pkg/arvo/neo/src/std/imp/circles.hoon b/pkg/arvo/neo/src/std/imp/circles.hoon new file mode 100644 index 0000000000..ec20ca57e8 --- /dev/null +++ b/pkg/arvo/neo/src/std/imp/circles.hoon @@ -0,0 +1,34 @@ +/@ diff=circles-diff +|% +++ state %sig +++ poke (sy %circles-diff ~) +++ kids + %- ~(gas by *kids:neo) + :~ [~[|/%tas] %sig %circle-diff] + == +++ deps *deps:neo +++ form + ^- form:neo + |_ [=bowl:neo =ever:neo state-vase=vase *] + ++ poke + |= [=stud:neo vax=vase] + ~& stud/stud + ?> ?=(%circles-diff stud) + =+ !<(=diff vax) + :_ state-vase + ?- -.diff + %add + %+ turn ~(tap by p.diff) + |= [=term =made:neo] + [(snoc here.bowl term) %make made] + :: + %del + %+ turn ~(tap in p.diff) + |= =term + [(snoc here.bowl term) %tomb ~] + == + ++ init + |= vas=(unit vase) + `*vase + -- +-- diff --git a/pkg/arvo/neo/src/std/imp/feed-item.hoon b/pkg/arvo/neo/src/std/imp/feed-item.hoon new file mode 100644 index 0000000000..d4843f55cc --- /dev/null +++ b/pkg/arvo/neo/src/std/imp/feed-item.hoon @@ -0,0 +1,54 @@ +/@ diff=feed-item-diff +/@ state=feed-item +/@ circle +=> +|% +++ check-perms + |= =bowl:neo + =+ !<(=circle q.pail.q:(~(got by deps.bowl) %acl)) + (~(has in circle) ship.src.bowl) +-- +|% +++ state %feed-item +++ poke (sy %feed-item-diff ~) +++ kids + %- ~(gas by *kids:neo) + :~ [~[&/%likes |/%p] %sig %sig] + [~[&/%comments |/%p] %feed-comment %sig] + == +++ deps + %- ~(gas by *deps:neo) + :~ :- %acl + :^ req=& %y [%circle %sig] + %- ~(gas by *kids:neo) + :~ [~[|/%p] %sig %sig] + == + == +++ form + ^- form:neo + |_ [=bowl:neo =ever:neo state-vase=vase *] + +* sta !<(^state state-vase) + ++ poke + |= [=stud:neo vax=vase] + ^- (quip card:neo vase) + =/ sta sta + ?> (check-perms bowl) + ?> ?=(%feed-item-diff stud) + =+ !<(=diff vax) + ~! diff + ?- -.diff + %add-like + =. likes.sta +(likes.sta) + :_ !>(sta) + [(welp here.bowl %likes p/ship.src.bowl ~) %make stud/%sig ~ ~]~ + :: + %add-comment + =. comments.sta +(comments.sta) + :_ !>(sta) + [(welp here.bowl %comments da/now.bowl ~) %make made.diff]~ + == + ++ init + |= vas=(unit vase) + `(need vas) + -- +-- diff --git a/pkg/arvo/neo/src/std/imp/feed.hoon b/pkg/arvo/neo/src/std/imp/feed.hoon new file mode 100644 index 0000000000..ca8ec63fbd --- /dev/null +++ b/pkg/arvo/neo/src/std/imp/feed.hoon @@ -0,0 +1,34 @@ +/@ diff=feed-diff +|% +++ state %sig +++ poke (sy %feed-diff ~) +++ kids + %- ~(gas by *kids:neo) + :~ [~[&/%items |/%da] %feed-item %feed-item-diff] + == +++ deps + %- ~(gas by *deps:neo) + :~ acl/[req=& %x %circle %sig] + == +++ form + ^- form:neo + |_ [=bowl:neo =ever:neo state-vase=vase *] + ++ poke + |= [=stud:neo vax=vase] + ?> ?=(%feed-diff stud) + =+ !<(=diff vax) + :_ state-vase + ?- -.diff + %add + [(snoc here.bowl da/now.bowl) %make p.diff]~ + :: + %del + %+ turn ~(tap in p.diff) + |= =@da + [(snoc here.bowl da/da) %tomb ~] + == + ++ init + |= vas=(unit vase) + `*vase + -- +-- diff --git a/pkg/arvo/neo/src/std/imp/sig.hoon b/pkg/arvo/neo/src/std/imp/sig.hoon new file mode 100644 index 0000000000..6844ce8dd6 --- /dev/null +++ b/pkg/arvo/neo/src/std/imp/sig.hoon @@ -0,0 +1,17 @@ +|% +++ state %sig +++ poke ~ +++ kids *kids:neo +++ deps *deps:neo +++ form + ^- form:neo + |_ [=bowl:neo =ever:neo state-vase=vase *] + +* sta !<(^state state-vase) + ++ poke + |= [=stud:neo vax=vase] + !! + ++ init + |= vas=(unit vase) + `*vase + -- +-- diff --git a/pkg/arvo/neo/src/std/lib/aegean.hoon b/pkg/arvo/neo/src/std/lib/aegean.hoon new file mode 100644 index 0000000000..d898691e7e --- /dev/null +++ b/pkg/arvo/neo/src/std/lib/aegean.hoon @@ -0,0 +1,52 @@ +|% ++$ signature @uvH ++$ signal :: what gets broadcast + $: + =hops + =post + == ++$ hops ?(%0 %1 %2) :: do not allow >2 hops ++$ post path :: FQSP such that mark is %entry +:: author in the head +:: require timestamp, other cases rejected +:: originating desk included ++$ entry :: /mar/entry/hoon + $: + text=(unit @t) :: max length 256 bytes + media=(unit preview) + quote=(unit post) + == ++$ preview (map path coin) :: OGP data ++$ saved (set post) ++$ hidden (set post) ++$ boosts (map post [ship @da]) :: ships who have boosted and when ++$ store (map post entry) :: the content that gets sorted ++$ sort (map post weight=@sd) ++$ weight @sd ++$ fresh (list [post weight]) :: populated upon hearing new post +:: ++$ locker (set evidence) :: reported posts from friends ++$ evidence + $: + mine=signature + %disavow + =post + theirs=signature + =entry + == +:: ++$ action + $% + [%broadcast =signal] + [%save =post] + [%hide =post] + [%boost =post] + [%report =post] + == ++$ message + $% + [%gossip =signal] + [%praise =entry] + [%tattle =evidence] + == +-- diff --git a/pkg/arvo/neo/src/std/pro/circle-diff.hoon b/pkg/arvo/neo/src/std/pro/circle-diff.hoon new file mode 100644 index 0000000000..711bc76fff --- /dev/null +++ b/pkg/arvo/neo/src/std/pro/circle-diff.hoon @@ -0,0 +1,3 @@ +$% [%add p=(map ship made:neo)] + [%del p=(set ship)] +== diff --git a/pkg/arvo/neo/src/std/pro/circle.hoon b/pkg/arvo/neo/src/std/pro/circle.hoon new file mode 100644 index 0000000000..73221e67f0 --- /dev/null +++ b/pkg/arvo/neo/src/std/pro/circle.hoon @@ -0,0 +1 @@ +,(set ship) diff --git a/pkg/arvo/neo/src/std/pro/circles-diff.hoon b/pkg/arvo/neo/src/std/pro/circles-diff.hoon new file mode 100644 index 0000000000..a8095fb674 --- /dev/null +++ b/pkg/arvo/neo/src/std/pro/circles-diff.hoon @@ -0,0 +1,3 @@ +$% [%add p=(map term made:neo)] + [%del p=(set term)] +== diff --git a/pkg/arvo/neo/src/std/pro/feed-diff.hoon b/pkg/arvo/neo/src/std/pro/feed-diff.hoon new file mode 100644 index 0000000000..74009c8b16 --- /dev/null +++ b/pkg/arvo/neo/src/std/pro/feed-diff.hoon @@ -0,0 +1,3 @@ +$% [%add p=made:neo] + [%del p=(set time)] +== diff --git a/pkg/arvo/neo/src/std/pro/feed-item-diff.hoon b/pkg/arvo/neo/src/std/pro/feed-item-diff.hoon new file mode 100644 index 0000000000..fc09647e17 --- /dev/null +++ b/pkg/arvo/neo/src/std/pro/feed-item-diff.hoon @@ -0,0 +1,3 @@ +$% [%add-like ~] + [%add-comment =made:neo] +== diff --git a/pkg/arvo/neo/src/std/pro/feed-item.hoon b/pkg/arvo/neo/src/std/pro/feed-item.hoon new file mode 100644 index 0000000000..55f17fbb86 --- /dev/null +++ b/pkg/arvo/neo/src/std/pro/feed-item.hoon @@ -0,0 +1,6 @@ +$: title=@t + desc=@t + sent=time + likes=@ud + comments=@ud +== diff --git a/pkg/arvo/sur/neo.hoon b/pkg/arvo/sur/neo.hoon index a3ea57a949..d1ebd09e15 100644 --- a/pkg/arvo/sur/neo.hoon +++ b/pkg/arvo/sur/neo.hoon @@ -51,9 +51,9 @@ :: ++ run |= txt=@t - (scan (trip txt) (rein /)) + (scan (trip txt) (rein *name)) +$ lib - [face=(unit term) =name] + [face=term =name] +$ pro [face=term =stud] +$ vale @@ -65,12 +65,22 @@ =hoon == ++ rein - |= pax=path + |= =name =< apex |% ++ nam :: ^- $-(nail (like name:neo)) - ;~(plug ;~(pfix fas sig fed:ag) stip) + ;~ pose + %+ sear + |= [kets=(list) pit=pith] + ^- (unit ^name) + %- mole + |. ^- ^name + =. pit (scag (sub (lent pit) (lent kets)) pit) + name(pith (welp pith.name pit)) + ;~(pfix cen ;~(plug (star ket) stip)) :: relative + ;~(plug ;~(pfix fas sig fed:ag) stip) :: absolute + == ++ std ;~ pose ;~(plug sym ;~(pfix col sig fed:ag) ;~(pfix fas sym)) @@ -89,10 +99,15 @@ == ++ lib :: ^- $-(nail (like ^lib)) - %+ rune cen + %+ rune hep ;~ pose - (stag ~ nam) - ;~(plug (stag ~ sym) ;~(pfix gap nam)) + ;~(plug sym ;~(pfix tis nam)) + %+ cook + |= n=^name + =/ last (rear pith.n) + ?> ?=(@ last) + [last n] + nam == ++ rune |* [car=rule rul=rule] @@ -106,7 +121,7 @@ (star pro) ++ hone :: ^- $-(nail (like hoon)) - =+ vaz=(vang & pax) + =+ vaz=(vang & (en-path:^name name)) (ifix [gay gay] tall:vaz) ++ apex :: ^- rule @@ -591,10 +606,12 @@ +$ page (pair stud *) :: +$ cage (pair stud vase) :: ++$ made + [=code init=(unit vase) =conf] +$ note - $% [%make =code init=(unit vase) =conf] :: todo: configuration values, init cannot be ^ if installing over + $% [%make made] :: todo: configuration values, init cannot be ^ if installing over [%poke =pail] - [%tomb =case] + [%tomb cas=(unit case)] :: tom [%link from=pith src=stud] :: XX deprecate == +$ raw-poke