Although preventing the accumulation of cruft in the repository is good you should take into account that distributions may be using a certain recipe and depend upon it. Therefore, before removing a recipe from the repository, do a grep in the 'conf/distro' directory. If the version you are going to remove is being explicitly used send the respective patch to the development mailing list for 'RFC'.

Although preventing the accumulation of cruft in the repository is good you should take into account that distributions may be using a certain recipe and depend upon it. Therefore, before removing a recipe from the repository, do a grep in the 'conf/distro' directory. If the version you are going to remove is being explicitly used send the respective patch to the development mailing list for 'RFC'.

−

''draft''

+

''DRAFT above''

[[Category:Policy]]

[[Category:Policy]]

Revision as of 21:25, 19 March 2009

Do you know about the powers of git-mv? If you are upgrading a package you really should.

Please follow these steps when upgrading a package to a more recent version. This is not to be seen as dogma, but rather as best practice. There are basically two cases we need to consider; a) you do want to keep the version of the bb file that is in OE now (somebody else needs this particular version) or b) you don't.

You do not need to keep the last version of the package

Use "git-mv packages/$pkg/$file_v1.bb packages/$pkg/$file_v2.bb" so that we don't accumulate unecessary cruft. Using the built-in rename function also ensures we can trace the changes for a package with "git log" even across upgrades.

make further changes to packages/$pkg/$file_v2.bb as appropriate.

At the very minimum do a compilation test "bitbake $file" to make sure the new package does at least fetch and compile.

inspect the output of "git diff packages/$pkg/". Is this really what you want to commit?

You do want to keep the last version of the package

Now, you may ask "Why rename the file first and then copy it back?" Good question! With using "git mv" to rename and then copying back we keep the "git log"-history forever. Just "cp $a $b;git add $b" means we have a truncated history once $a gets removed.

Removing recipes

DRAFT below

Although preventing the accumulation of cruft in the repository is good you should take into account that distributions may be using a certain recipe and depend upon it. Therefore, before removing a recipe from the repository, do a grep in the 'conf/distro' directory. If the version you are going to remove is being explicitly used send the respective patch to the development mailing list for 'RFC'.