This reduces the cognitive complexity of DirectoryShare parsing code by moving the options parsing logic (ro and tag) into a separate method and also allows specifying options in any order (e.g. /Users/admin/build:tag=foo-bar,ro).
Also, the docs for --dir now looks like this:
The [name:]path[:ro,tag=virtiofs-mount-tag] format unfortunately does not allow us to express the available option combinations properly, so I think it would be a nice idea to reduce the cognitive load and abstract away the notion of "options" altogether into discussion section.
This reduces the cognitive complexity of
DirectoryShare
parsing code by moving the options parsing logic (ro
andtag
) into a separate method and also allows specifying options in any order (e.g./Users/admin/build:tag=foo-bar,ro
).Also, the docs for
--dir
now looks like this:The
[name:]path[:ro,tag=virtiofs-mount-tag]
format unfortunately does not allow us to express the available option combinations properly, so I think it would be a nice idea to reduce the cognitive load and abstract away the notion of "options" altogether intodiscussion
section.