MCPcopy
hub / github.com/cli/cli / CheckLinkedBranchFeature

Function CheckLinkedBranchFeature

api/queries_branch_issue_reference.go:92–110  ·  view source on GitHub ↗
(client *Client, host string)

Source from the content-addressed store, hash-verified

90}
91
92func CheckLinkedBranchFeature(client *Client, host string) error {
93 var query struct {
94 Name struct {
95 Fields []struct {
96 Name string
97 }
98 } `graphql:"LinkedBranch: __type(name: \"LinkedBranch\")"`
99 }
100
101 if err := client.Query(host, "LinkedBranchFeature", &query, nil); err != nil {
102 return err
103 }
104
105 if len(query.Name.Fields) == 0 {
106 return fmt.Errorf("the `gh issue develop` command is not currently available")
107 }
108
109 return nil
110}
111
112func FindRepoBranchID(client *Client, repo ghrepo.Interface, ref string) (string, string, error) {
113 var query struct {

Callers 1

developRunFunction · 0.92

Calls 2

QueryMethod · 0.65
ErrorfMethod · 0.65

Tested by

no test coverage detected