Hi @proabiral, it looks like you found an endpoint that we haven't yet implemented.
Thank you for alerting us to this!
Would you like to submit a PR to fix this, or would you like me to open this up as an issue for one of our great volunteers to fix?
Hi @gmlewis ,
Thanks for such a quick response.
I would love to submit a PR to fix this but I have never worked on such a large project like this before. Is there any documentation that I can refer to that would help to better overview of the project ?
Welcome to the project, @proabiral !
The best place to get started is to look at our CONTRIBUTING.md document at the top of our repo.
After that, feel free to ask questions. 馃榿
Hi @gmlewis ,
I have tried to implemented the feature on my fork here.
Can you please provide feedback on this ?
After looking at the PR and reading the v3 API docs again, it is not clear to me if the cname parameter is required, thoughts?
It seems like source is required, but if you aren't sure about cname as well, @proabiral, could you please contact [email protected] and point them to this API and ask them if cname (and source while you're asking) are required? Also, could you ask them to please mark them appropriately as "Optional" or "Required"? The, when you get a reply, could you please report back here? (Lately they have been responding within a few hours... pretty impressive.)
That would help quite a bit... thank you!
Hi @gmlewis ,
I have tried to implemented the feature on my fork here.
Can you please provide feedback on this ?
Feedback provided, but as I commented in the commit, let's please create a PR first and then the code review history will be kept in this repo and others who watch this repo will be able to better participate as well, especially if I give feedback that they disagree with. :smile:
Hi @gmlewis ,
Thanks for such a detailed feedback. :) Really appreciate it.
According to Github Support,
Thanks for reaching out. Neither parameter is required, but at least one of them must be provided. So, either cname or source must be provided since providing no parameter doesn't make sense.
Since neither parameter specifically is required, it wouldn't be correct to mark them as required -- they're optional. And the way the rest of the documentation indicates optional parameters is by not mentioning the "Required." text (e.g. see https://developer.github.com/v3/issues/#create-an-issue).
I am kinda stuck in a scenario here, if we need to remove existing CName from the repo, we will be needing to send request with body
{"cname":""}
However, to only update source not CName, we will be needing to send request with body with only source omitting CName
{"source":"master"}
Can you please guide me on how this can be achieved ?
Here's the comment I just added to your PR:
Based on the 2020-01-09 response from the GitHub tech support team, both fields are optional, so what you have written is correct so far (except Cname needs to be CName to match Go style).
So to be able to remove the Custom Domain, we need a separate way to flag this.
One of the ways we've done this is to add a removeCustomDomain flag to the UpdatePages endpoint below.
If that flag is true, then internally we switch to a different struct where the CName field does not include the ,omitempty tag modifier. Then a null will be sent across.
Check out what I recently did in https://github.com/google/go-github/pull/1357 for an example.
Also take a look at #1372 for a way to unit test calls like these to prove that the JSON is being marshaled as we expect it to be.
Do you want to include enablement params in this PR - or shall I raise another issue?
Another issue/PR would probably be nice from a record-keeping standpoint, thanks.
This would be a great PR for any new contributor to this repo or any Go developer.
All contributions are greatly appreciated!
Feel free to volunteer for any issue and the issue can be assigned to you so that others don't attempt to duplicate the work.
Please check out our CONTRIBUTING.md guide to get started.
Thank you!
Happy to pick it up @gmlewis
Thank you, @patrickmarabeas !
It is yours.
Most helpful comment
Happy to pick it up @gmlewis