Skip to content

Allow to use the 'latest' release (with a named asset) #9

@carstingaxion

Description

@carstingaxion

Hello @stoph ,

thank you for providing this great service!

Today I wanted to use it within a blueprint.json to reference the latest release, without any need to change numbers regularly. But unfortunately only numbered releases seem to work. Like this example, where 0.28.0 is indeed the latest.

⛔ https://github-proxy.com/proxy/?repo=GatherPress/gatherpress&release=latest&asset=gatherpress.zip
✅ https://github-proxy.com/proxy/?repo=GatherPress/gatherpress&release=0.28.0&asset=gatherpress.zip

I described it like this in the PR with our use-case:

Internally github-proxy.com uses:

$url = "https://github.com/$repo/releases/download/$release/$asset";

which works fine with numbered, but not the latest release.

grafik

Acording to download - Is there a link to GitHub for downloading a file in the latest release of a repository? - Stack Overflow the url template needs some change.

$url = "https://github.com/$repo/releases/download/$release/$asset";

Following this scheme, I'm able to download both assets successfully.

✅ https://github.com/GatherPress/gatherpress/releases/download/0.28.0/gatherpress.zip
✅ https://github.com/GatherPress/gatherpress/releases/latest/download/gatherpress.zip

Hoping, you are able & willing to make this change.
Best regards carsten

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions