Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for editing Gists #484

Merged
merged 9 commits into from
Oct 11, 2019

Conversation

martinvanzijl
Copy link
Contributor

Fixes issue #466.

Added the following methods:

  • GHGist.setDescription
  • GHGist.addFile
  • GHGist.updateFile
  • GHGist.renameFile

NOTE: I could not get the deleteFile() method to work. I have left it commented-out.

Fixes issue hub4j#466

NOTE: I could not get the deleteFile() method to work.
Copy link
Member

@bitwiseman bitwiseman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have a ton of PRs up. Thanks! As with others, add some tests and I think we can merge.

@bitwiseman
Copy link
Member

@martinvanzijl There's actually GistBuilder, so it would be better if we had a GistUpdater class to do the updating.

- Created class GHGistUpdater to do the updating.
- Added unit tests.
@martinvanzijl
Copy link
Contributor Author

@bitwiseman
Thanks for reviewing. I created the GHGistUpdater class to do the updating as suggested, and added unit tests. Can you please check?

I still can't get the deleteFile method to work.

@bitwiseman bitwiseman merged commit 7d65e31 into hub4j:master Oct 11, 2019
}

// // This method does not work.
// public GHGistUpdater deleteFile(String fileName) throws IOException {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@martinvanzijl
This probably has to do with the way that values are passed via maps.
I suspect passing null results in the key not being set or at least not set to GitHub.

@martinvanzijl martinvanzijl deleted the issue_466_edit_gists branch October 13, 2019 02:24
bitwiseman added a commit to bitwiseman/github-api that referenced this pull request Apr 22, 2020
bitwiseman added a commit to bitwiseman/github-api that referenced this pull request Apr 26, 2020
bitwiseman added a commit to bitwiseman/github-api that referenced this pull request Apr 27, 2020
bitwiseman added a commit to bitwiseman/github-api that referenced this pull request Apr 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants