File tree Expand file tree Collapse file tree 1 file changed +20
-33
lines changed Expand file tree Collapse file tree 1 file changed +20
-33
lines changed Original file line number Diff line number Diff line change @@ -37,44 +37,31 @@ func newGitSourceAPI(codefresh *codefresh) IGitSourceAPI {
3737}
3838
3939func (g * gitSource ) List (runtimeName string ) ([]model.GitSource , error ) {
40- // jsonData := map[string]interface{}{
41- // "query": `query GetGitSourcesList(pagination: SlicePaginationArgs!, project: String!, $runtime: String!) {
42- // gitSources(pagination: {}, project: "", runtime: $runtime) {
43- // edges {
44- // node {
45- // metadata {
46- // name
47- // }
48- // path
49- // repoURL
50- // }
51- // }
52- // }
53- // }`,
54- // "variables": map[string]interface{}{
55- // "runtime": runtimeName,
56- // },
57- // }
58-
5940 jsonData := map [string ]interface {}{
60- "query" : `query ListGitSources($runtime: String, $pagination: SlicePaginationArgs) {
61- gitSources(runtime: $runtime, pagination: $pagination) {
62- edges {
63- node {
64- metadata {
65- name
66- }
67- app {
68- repoURL
69- path
70- }
41+ "query" : `{
42+ gitSources {
43+ edges {
44+ node {
45+ metadata {
46+ name
47+ }
48+ self {
49+ path
50+ repoURL
51+ revision
52+ size
53+ status {
54+ syncStatus
55+ syncStartedAt
56+ syncFinishedAt
57+ healthStatus
58+ revision
7159 }
60+ }
61+ }
7262 }
7363 }
7464 }` ,
75- "variables" : map [string ]interface {}{
76- "runtime" : runtimeName ,
77- },
7865 }
7966
8067 response , err := g .codefresh .requestAPI (& requestOptions {
You can’t perform that action at this time.
0 commit comments