MCPcopy Index your code
hub / github.com/devopsctl/gitlabctl / assignListProjectMembersOptions

Function assignListProjectMembersOptions

cmd/flags_assigners.go:542–554  ·  view source on GitHub ↗

assignListProjectMembersOptions assigns the flags' values to gitlab.ListProjectMembersOptions fields. If a flag's default value is not changed by the caller, it's value will not be assigned to the associated gitlab.ListProjectMembersOptions field.

(cmd *cobra.Command)

Source from the content-addressed store, hash-verified

540// If a flag's default value is not changed by the caller,
541// it's value will not be assigned to the associated gitlab.ListProjectMembersOptions field.
542func assignListProjectMembersOptions(cmd *cobra.Command) *gitlab.ListProjectMembersOptions {
543 opts := new(gitlab.ListProjectMembersOptions)
544 if cmd.Flag("page").Changed {
545 opts.Page = getFlagInt(cmd, "page")
546 }
547 if cmd.Flag("per-page").Changed {
548 opts.PerPage = getFlagInt(cmd, "per-page")
549 }
550 if cmd.Flag("query").Changed {
551 opts.Query = gitlab.String(getFlagString(cmd, "query"))
552 }
553 return opts
554}
555
556// assignListGroupMembersOptions assigns the flags' values to gitlab.ListGroupMembersOptions fields.
557// If a flag's default value is not changed by the caller,

Callers 1

runGetProjectMembersFunction · 0.85

Calls 2

getFlagIntFunction · 0.85
getFlagStringFunction · 0.85

Tested by

no test coverage detected