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

GHRelease.uploadAsset() that takes InputStream instead of File #434

Closed
gabrielittner opened this issue May 27, 2018 · 1 comment · Fixed by #438
Closed

GHRelease.uploadAsset() that takes InputStream instead of File #434

gabrielittner opened this issue May 27, 2018 · 1 comment · Fixed by #438

Comments

@gabrielittner
Copy link

It would be great if you could offer a GHRelease.uploadAsset(InputStream, String) overload. I've got something that is already in memory and in my environment it's not easy to create files. That overload would allow me to simply pass in a ByteArrayInputStream.

@markkolich
Copy link

The uploadAsset method invokes file.getName():

https://github.com/kohsuke/github-api/blob/d61697a152c4ca50e82a95c0bee04b61430ac358/src/main/java/org/kohsuke/github/GHRelease.java#L127-L135

Looks like it would be up to the overloaded method to pass in the desired filename as well. E.g., GHRelease#uploadAsset(InputStream, String, String).

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 a pull request may close this issue.

2 participants