From 2729b4bba6cb639c43b5cee2ed217e8057167f77 Mon Sep 17 00:00:00 2001 From: tnn Date: Sat, 7 Mar 2015 15:14:27 +0000 Subject: add documentation on how USE_GITHUB is used --- doc/guide/files/fixes.xml | 48 ++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 47 insertions(+), 1 deletion(-) diff --git a/doc/guide/files/fixes.xml b/doc/guide/files/fixes.xml index 6ba999bec43..a236daaf41b 100644 --- a/doc/guide/files/fixes.xml +++ b/doc/guide/files/fixes.xml @@ -1,4 +1,4 @@ - + Making your package work @@ -778,6 +778,52 @@ FETCH_MESSAGE+= "manually from "${MASTER_SITES:Q}"." telling them that changing distfiles after releases without changing the file names is not good practice. + + Packages hosted on github.com + Helper methods exist for packages hosted on github.com. You do not need to specify MASTER_SITE but should instead use one of the three supported methods from below. + + Fetch based on a tagged release + + If your distfile URL looks similar to http://github.com/username/exampleproject/archive/v1.0.zip, then you are packaging a tagged release. + + +DISTNAME= exampleproject-1.0 +USE_GITHUB= yes +GH_ACCOUNT= username +#GH_PROJECT= # can be omitted if same as DISTNAME +GH_TAGNAME= v1.0 +EXTRACT_SUFX= .zip + + + + Fetch based on a specific commit + + If your distfile URL looks similar to http://github.com/example/example/archive/988881adc9fc3655077dc2d4d757d480b5ea0e11.tar.gz, then you are packaging a specific commit not tied to a release. + + +DISTNAME= example-1.0 +USE_GITHUB= yes +#GH_ACCOUNT= # can be omitted if same as DISTNAME +#GH_PROJECT= # can be omitted if same as DISTNAME +GH_COMMIT= 988881adc9fc3655077dc2d4d757d480b5ea0e11 + + + + + Fetch based on release + + If your distfile URL looks similar to http://github.com/username/exampleproject/releases/download/rel-1.6/offensive-1.6.zip, then you are packaging a release. + + +PKGNAME= ${DISTNAME:S/offensive/proper/} +DISTNAME= offensive-1.6 +USE_GITHUB= yes +GH_ACCOUNT= username +GH_PROJECT= exampleproject +GH_RELEASE= rel-${PKGVERSION_NOREV} # usually just set this to ${DISTNAME} + + + -- cgit v1.2.3