From @christophermaier on June 17, 2016 17:55
In order to more easily make command pipelines with cogctl, provide a --quiet/-q option on listing commands, which would simply return a list of the canonical identifiers for a thing.
As an example, right now you need to type something like this to assign all the permissions from a given bundle to a role:
cogctl permissions | grep $MY_BUNDLE | awk '{print $1 ":" $2}' | xargs cogctl permissions grant --role $MY_ROLE
With a --quiet / -q option, that could be reduced to:
cogctl permissions -q | grep $MY_BUNDLE | xargs cogctl permissions grant --role $MY_ROLE
assuming that cogctl permissions -q returned output like:
bundle1:perm1
bundle1:perm2
bundle2:perm1
Copied from original issue: operable/cog#779
From @christophermaier on June 17, 2016 17:55
In order to more easily make command pipelines with
cogctl, provide a--quiet/-qoption on listing commands, which would simply return a list of the canonical identifiers for a thing.As an example, right now you need to type something like this to assign all the permissions from a given bundle to a role:
With a
--quiet/-qoption, that could be reduced to:assuming that
cogctl permissions -qreturned output like:Copied from original issue: operable/cog#779