-
Notifications
You must be signed in to change notification settings - Fork 358
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
+vats changes #6390
+vats changes #6390
Conversation
pkg/arvo/gen/vats.hoon
Outdated
:: usage: +vats, =options [%option], =short [?] | ||
|% | ||
+$ options ?(%suspended %running %blocking %exists %default) | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hoon style requires ::
on blank lines.
pkg/arvo/gen/vats.hoon
Outdated
++ report-running | ||
|= [our=@p now=@da =short] | ||
^- tang | ||
=/ desks .^((set desk) %cd /(scot %p our)/base/(scot %da now)) ::preps desk variable, set of desks, scries clay for desks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style: lines should not exceed 80 characters
pkg/arvo/gen/vats.hoon
Outdated
== | ||
[%tang (report-vats p.bec now)] | ||
?+ options [%tang (report-vats p.bec now short)] | ||
%running [%tang (report-running p.bec now short)] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style: indent inside a ?+
pkg/base-dev/sur/hood.hoon
Outdated
@@ -49,7 +52,7 @@ | |||
^- tank | |||
=/ ego (scot %p our) | |||
=/ wen (scot %da now) | |||
=+ .^(=cass %cw /[ego]/[syd]/[wen]) | |||
=+ .^(=cass %cw /[ego]/[syd]/[wen]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
trailing whitespace
pkg/base-dev/sur/hood.hoon
Outdated
@@ -108,6 +111,64 @@ | |||
leaf/"kids desk: {?~(sink <~> ?~(kid.u.sink <~> <u.kid.u.sink>))}" | |||
leaf/"pending updates: {<`(list [@tas @ud])`~(tap in wic.dek)>}" | |||
== | |||
|
|||
++ report-vat-short | |||
|= $: $: tyr=rock:tire =cone sor=(map desk [ship desk]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
style: I'd put each of these on their own line, like this:
$: tyr=rock:tire
=cone
sor=(map desk [ship desk])
zyn=(map [desk ship desk] sync-state)
==
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sometimes when making a large noun, such as an Arvo move, we will have multiple entries in a :*
on the same line, but the standard for $:
is to put each item on its own line.
pkg/arvo/gen/vats.hoon
Outdated
|= syd=desk | ||
=/ deskstatus .^(rock:tire:clay %cx /(scot %p our)//(scot %da now)/tire) | ||
=(%live -:(~(got by deskstatus) syd)) | ||
=/ prep (report-prep our now) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code starting here seems to be repeated in all of these new functions. The "options" field just selects a set of desks, so I think this would be cleaner if reporting on a set of desks was factored separately from using the option to determine that set of desks. I would also rename "options" to "filter", since it's more specific -- it filters the set of desks.
pkg/arvo/gen/vats.hoon
Outdated
^- tang | ||
=/ desks .^((set desk) %cd /(scot %p our)/base/(scot %da now)) ::preps desk variable, set of desks, scries clay for desks | ||
=. desks | ||
%- silt |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
second argument to a =.
should be indented
pkg/arvo/gen/vats.hoon
Outdated
=. desks | ||
%- silt | ||
%+ skim | ||
~(tap in desks) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
second argument to a %+
should be indented
Implemented all the changes @belisarius222 |
Description
Resolves #6297.
Took a first pass at this upgrading +vats; you can add options with +vats, =options [%option], =short [?]
@belisarius222
Would appreciate any feedback