Support uploading to a specific branch
Closed this issue · 2 comments
rajbos commented
Currently all files are uploaded to the default branch, as that is what the GitHub API uses by default. I want to pass in a parameter indicating the branch name to use for uploading the file.
As a requirement I'd say that the branch already has to exist. Creating it is not necessary for me.
Changes needed
- Add an optional parameter to the action to specify the branch name
- Add the extra parameter to the PUT call in upload.js, see documentation
github-upload-action/upload.js
Lines 49 to 54 in 20142a0
I'd be happy to help working on this :-)
LasyIsLazy commented
I'd be thankful if you can make a PR for this.
Additional, There may be several points to note:
- What will the GitHub API do if the branch is not existed?
- Which structure should we use for the extra parameter to the PUT call?