diff options
Diffstat (limited to 'bridge/github/import_query.go')
-rw-r--r-- | bridge/github/import_query.go | 97 |
1 files changed, 6 insertions, 91 deletions
diff --git a/bridge/github/import_query.go b/bridge/github/import_query.go index ef26b3e8..52aef9e9 100644 --- a/bridge/github/import_query.go +++ b/bridge/github/import_query.go @@ -47,14 +47,9 @@ type userContentEdit struct { } type issueComment struct { - authorEvent - Body githubv4.String - Url githubv4.URI - - UserContentEdits struct { - Nodes []userContentEdit - PageInfo pageInfo - } `graphql:"userContentEdits(last: $commentEditLast, before: $commentEditBefore)"` + authorEvent // NOTE: contains Id + Body githubv4.String + Url githubv4.URI } type timelineItem struct { @@ -96,86 +91,6 @@ type timelineItem struct { } `graphql:"... on RenamedTitleEvent"` } -type issueTimeline struct { - authorEvent - Title string - Number githubv4.Int - Body githubv4.String - Url githubv4.URI - - TimelineItems struct { - Edges []struct { - Cursor githubv4.String - Node timelineItem - } - PageInfo pageInfo - } `graphql:"timelineItems(first: $timelineFirst, after: $timelineAfter)"` - - UserContentEdits struct { - Nodes []userContentEdit - PageInfo pageInfo - } `graphql:"userContentEdits(last: $issueEditLast, before: $issueEditBefore)"` -} - -// Alex -type timelineItemsQuery struct { - Repository struct { - Issue struct { - TimelineItems struct { - Edges []struct { - Cursor githubv4.String - Node timelineItem - } - PageInfo pageInfo - } `graphql:"timelineItems(first: $timelineFirst, after: $timelineAfter)"` - } `graphql:"issue(number: $issueNumber)"` - } `graphql:"repository(owner: $owner, name: $name)"` -} - -type issueEdit struct { - UserContentEdits struct { - Nodes []userContentEdit - PageInfo pageInfo - } `graphql:"userContentEdits(last: $issueEditLast, before: $issueEditBefore)"` -} - -type issueTimelineQuery struct { - Repository struct { - Issues struct { - Nodes []issueTimeline - PageInfo pageInfo - } `graphql:"issues(first: $issueFirst, after: $issueAfter, orderBy: {field: CREATED_AT, direction: ASC}, filterBy: {since: $issueSince})"` - } `graphql:"repository(owner: $owner, name: $name)"` -} - -type issueEditQuery struct { - Repository struct { - Issues struct { - Nodes []issueEdit - PageInfo pageInfo - } `graphql:"issues(first: $issueFirst, after: $issueAfter, orderBy: {field: CREATED_AT, direction: ASC}, filterBy: {since: $issueSince})"` - } `graphql:"repository(owner: $owner, name: $name)"` -} - -type commentEditQuery struct { - Repository struct { - Issues struct { - Nodes []struct { - Timeline struct { - Nodes []struct { - IssueComment struct { - UserContentEdits struct { - Nodes []userContentEdit - PageInfo pageInfo - } `graphql:"userContentEdits(last: $commentEditLast, before: $commentEditBefore)"` - } `graphql:"... on IssueComment"` - } - } `graphql:"timeline(first: $timelineFirst, after: $timelineAfter)"` - } - } `graphql:"issues(first: $issueFirst, after: $issueAfter, orderBy: {field: CREATED_AT, direction: ASC}, filterBy: {since: $issueSince})"` - } `graphql:"repository(owner: $owner, name: $name)"` -} - type ghostQuery struct { User struct { Login githubv4.String @@ -209,7 +124,7 @@ type issueQuery struct { Issues struct { Nodes []issue PageInfo pageInfo - } `graphql:"issues(first: $issueFirst, after: $issueAfter, orderBy: {field: CREATED_AT, direction: ASC})"` //, filterBy: {since: $issueSince})"` + } `graphql:"issues(first: $issueFirst, after: $issueAfter, orderBy: {field: CREATED_AT, direction: ASC}), filterBy: {since: $issueSince})"` } `graphql:"repository(owner: $owner, name: $name)"` } @@ -221,7 +136,7 @@ type issue struct { Url githubv4.URI } -type issueEditQuery_A struct { +type issueEditQuery struct { Node struct { Typename githubv4.String `graphql:"__typename"` Issue struct { @@ -246,7 +161,7 @@ type timelineQuery struct { } `graphql:"node(id: $gqlNodeId)"` } -type commentEditQuery_A struct { +type commentEditQuery struct { Node struct { Typename githubv4.String `graphql:"__typename"` IssueComment struct { |