Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

what is the best practice of distributing binaries from a github project? [closed]

what is the best practice of distributing binaries from a github project?

I can think of:

  • Create a bin folder in your project where you keep a copy of the binaries. However, github is meant to store source code and not binaries Storing large and regularly changing binaries may be expensive qua diskspace and bandwidth?
  • Upload a copy of the binaries to the github pages of the project, or use a separate web site for hosting your binaries. However, that is not always feasible, and requires more (hand)work to keep the binaries up to date, I rather want to have the binaries updated automatically or with a single action.
like image 887
Jos de Jong Avatar asked Apr 27 '12 07:04

Jos de Jong


People also ask

What is binaries in GitHub release?

What Are Releases In GitHub? Releases in GitHub are the one-stop solution from GitHub to provide software packages in binary files along with their release notes for every release of the software. Binary files are a great way to give the user a version of the software in the form of code until a particular point.


2 Answers

As of December 11, 2012 the Downloads feature on GitHub is deprecated. The article Distributing large binaries recommends using an external service:

We recommend Amazon S3 for storage paired with CloudFront for serving via CDN, or other services such as SourceForge.


However, since 2d July 2013, you now can define a release.

Releases, a workflow for shipping software to end users.
Releases are first-class objects with changelogs and binary assets that present a full project history beyond Git artifacts. They're accessible from a repository's homepage:

homepage

  • Releases are accompanied by release notes and links to download the software or source code.
  • Following the conventions of many Git projects, releases are tied to Git tags. You can use an existing tag, or let releases create the tag when it's published.
  • You can also attach binary assets (such as compiled executables, minified scripts, documentation) to a release. Once published, the release details and assets are available to anyone that can view the repository.

release

like image 97
vitaut Avatar answered Oct 13 '22 07:10

vitaut


It is clear to me now that it is important not to store binaries in your github project itself. Thus, you will need to store binaries elsewhere. Possible solutions I came across are:

  • Store the binaries in a separate submodule (dalores idea). It makes sense to store them in your projects github pages, which you use to host your projects website via github.
  • If you have only a few binaries or zip file only, you can upload them to github via Downloads -> Upload a new file. This feature is quite limited though, you cannot put files in structured folders.
  • In case of java jar files, there are solutions out there like Nexus for managing your libraries.
  • Store the binaries on a completely separate site that you host yourself
like image 20
Jos de Jong Avatar answered Oct 13 '22 06:10

Jos de Jong