0
GraphQL Query I used:
mutation CreateGitProfileRepo($name: String!, $description: String!, $homepageUrl: URI!) {
createRepository(input: {name: $name, visibility: PUBLIC, description: $description, homepageUrl: $homepageUrl}) {
repository {
ref(qualifiedName: "main") {
repository {
id
}
}
}
}
}
I’m getting ref ID as null
, as it is an empty repo.
Now I’m creating a commit using:
mutation ($input: CreateCommitOnBranchInput!) {
createCommitOnBranch(input: $input) {
commit {
url
}
}
}
here expectedHeadOid
is a required field, and my ref id is comming as null,
How to create a commit in this repo.
I’ve created new Repository using GitHub Graphql API.
Reset to default
Know someone who can answer? Share a link to this question via email, Twitter, or Facebook.
Browse other questions tagged
or ask your own question.
or ask your own question.
|