Skip to content
This repository has been archived by the owner on Jun 1, 2020. It is now read-only.

GitHub auto-updater #27

Open
PeterDaveHello opened this issue Nov 6, 2016 · 13 comments
Open

GitHub auto-updater #27

PeterDaveHello opened this issue Nov 6, 2016 · 13 comments

Comments

@PeterDaveHello
Copy link
Contributor

PeterDaveHello commented Nov 6, 2016

Bountysource

The current general purpose git auto-updater can fetch every file inside tagged commit of any public git repository but it can't handle the manually upload assets on GitHub release page, so let's add a GitHub auto-updater for those libraries publish assets on the release page on GitHub, we can use GitHub api for the tags/versions check, and just download the files of the needed versions.

@jman294
Copy link

jman294 commented Apr 23, 2018

Check out: jman294@ed350dd

This github auto updater is not tested, but a start on the idea. I did not know fully what to replace and where to place the downloaded tarballs. I have not ran the code yet, so it probably has a few bugs. Just looking to see if this is what you were envisioning.

@PeterDaveHello
Copy link
Contributor Author

The idea is to use the files on the release page, but not from the repository itself, for the files inside a repository, current git auto-update can handle it ;)

@jman294
Copy link

jman294 commented Apr 24, 2018

This downloads the tarballs for the needed versions. jman294@a480c15
The next step is to extract the tarballs and copy the files to the correct positions like what is done it gitUpdater?

@PeterDaveHello
Copy link
Contributor Author

We need to fetch the manually uploaded artifacts, not the tarball, all the files in the tarball can be fetched by current git auto-updater already 😃

@jman294
Copy link

jman294 commented Apr 25, 2018

I may not be the most qualified for this issue, but I'll keep working at it anyway if you want me to. :). Is this what needs to happen?

  • Download individual files from github based on the package glob.
  • Copy these files to their corresponding version number folder

What do you mean by 'download the tarball of the needed versions'?

If you think someone else is better suited to this issue than I am, I am happy to step aside :)

@jman294
Copy link

jman294 commented Apr 26, 2018

At any rate, here is what I've got:
jman294@f19969f
It implements much of the same functionality as git updater, but instead downloads needed files for versions from GitHub. It is very messy.

@PeterDaveHello
Copy link
Contributor Author

@jman294 I'm fine if you'd like to try.

The tarball means the .tar.gz files you're going to download in the program, AFAIK the tarballs come from the repository itself, however, we can already handle the files inside the repository, what we need to fetch are the files in the "release" package, individually uploaded but not the repository files ;)

The concept is to fetch the list of uploaded files in the release page, use glob to decide the files match our auto-update filemaps, can download them one by one.

@jman294
Copy link

jman294 commented Apr 27, 2018

In most recent commit I made it download needed files from the releases from github. I did not download the tarballs, only the singular needed files. In preliminary testing, it seems to work, at least from what I understand.

@PeterDaveHello
Copy link
Contributor Author

Cool, would you please remove .swp, .swo temp files and squash all the commits into one first?

@jman294
Copy link

jman294 commented Apr 27, 2018

#33

I believe you can squash the commits while merging. Otherwise, I can squash my commits into one.

@PeterDaveHello
Copy link
Contributor Author

I prefer to see your squash first ;)

@jman294
Copy link

jman294 commented Jun 2, 2018

Hi, is there possibly anything I can do to improve my pr and obtain the bounty?

@PeterDaveHello
Copy link
Contributor Author

Hi @jman294, I'll test it ASAP, sorry for your waiting.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants