gruntwork-io / fetch

Download files, folders, and release assets from a specific git commit, branch, or tag of public and private GitHub repos.
https://www.gruntwork.io/
MIT License
589 stars 90 forks source link

Enable asset downloads from GitHub Enterprise #52

Closed josh-padnick closed 5 years ago

josh-padnick commented 5 years ago

Fixes #48. This is a tricky one to test because we don't have a running instance of GitHub Enterprise against which we can run integration tests. So the best we can do is to validate that the URL fetch attempts to download from in the case of GitHub Enterprise is as expected.

I also noticed a few areas where errors were being swallowed so I added some boilerplate error handling code for those cases.

In the end, for the +178 lines of code additions here, the actual bug fix just 4 lines of code.

dg-jrichardson commented 5 years ago

Tested this out this evening, and looks to fix #48 that I was seeing in our GHE implementation

josh-padnick commented 5 years ago

Ok, great. PR feedback incorporated, tests pass, real-world use case validated. I think this is ready to merge. Releases should auto-populate in a few minutes.

josh-padnick commented 5 years ago

Fixes #48.