(cmd *cobra.Command, name string)
| 53 | } |
| 54 | |
| 55 | func runNewProjectHook(cmd *cobra.Command, name string) error { |
| 56 | opts, err := assignAddProjectHookOptions(cmd) |
| 57 | if err != nil { |
| 58 | return err |
| 59 | } |
| 60 | hook, errr := newProjectHook(name, opts) |
| 61 | if errr != nil { |
| 62 | return errr |
| 63 | } |
| 64 | printProjectHooksOut(getFlagString(cmd, "out"), hook) |
| 65 | return nil |
| 66 | } |
| 67 | |
| 68 | func newProjectHook(project string, opts *gitlab.AddProjectHookOptions) (*gitlab.ProjectHook, error) { |
| 69 | git, err := newGitlabClient() |
no test coverage detected