User:Ganwell/mistakes: Difference between revisions

From Alpine Linux
(Created page with "# APKBUILD mistakes # ## Style ## 1. Use tabs 2. Order of functions: prepare, build, check, package (the order they are executed) 3. No empty variables 4. Set Contribu...")
 
No edit summary
Line 1: Line 1:
# APKBUILD mistakes #
= APKBUILD mistakes =


## Style ##
These are just my note. Please read the official guidelines.
 
== Style ==


1. Use tabs
1. Use tabs
Line 24: Line 26:
7. Rebase your changes
7. Rebase your changes


## Packages ##
== Packages ==


1. Set pkgrel to 0 when when pkgver is increased
1. Set pkgrel to 0 when when pkgver is increased
Line 43: Line 45:
   community packages may only depend on main/community package
   community packages may only depend on main/community package


## Testing ##
== Testing ==


1. Test APKBUILD against edge, not current
1. Test APKBUILD against edge, not current
Line 49: Line 51:
2. Make sure the software actually works
2. Make sure the software actually works


## Build ##
== Build ==


1. No downloads during build (is already prevented)
1. No downloads during build (is already prevented)


## Languages
== Languages ==


1. Don't use language-package managers (npm, pip, cabal): the build has to be
1. Don't use language-package managers (npm, pip, cabal): the build has to be
   reproducible
   reproducible

Revision as of 21:31, 5 September 2018

APKBUILD mistakes

These are just my note. Please read the official guidelines.

Style

1. Use tabs

2. Order of functions: prepare, build, check, package (the order they are

  executed)

3. No empty variables

4. Set Contributor and Maintainer

5. Commit message repo/package: X

X: new apk

X: upgrade to Y

X: [other changes]

6. Shell: quote variables

7. Rebase your changes

Packages

1. Set pkgrel to 0 when when pkgver is increased

2. Else bump pkgrel to trigger rebuild

3. Only add very common or required dependencies

4. Use post-install rarely, don't use it for anything that can be done during

  package()

5. New packages go to testing first

6. Use spdx license names: https://spdx.org/licenses/

7. main pacakges may only depend on main packages

  community packages may only depend on main/community package

Testing

1. Test APKBUILD against edge, not current

2. Make sure the software actually works

Build

1. No downloads during build (is already prevented)

Languages

1. Don't use language-package managers (npm, pip, cabal): the build has to be

  reproducible