Using git for patch management in Fedora
Mathieu Bridon
bochecha at fedoraproject.org
Tue Nov 19 10:28:47 UTC 2013
On Tue, 2013-11-19 at 10:22 +0000, Richard W.M. Jones wrote:
> For (2) I would suggest a lightweight technique where git-managed
> patches are marked in the spec file using:
>
> ### GIT-MANAGED-PATCHES ###
> ### END-GIT-MANGED-PATCHES ###
>
> and a simple script that replaces everything between those marks with
> PatchXXXX lines. The script could be adapted from copy-patches.sh
> (see above).
>
> To apply the patches, a standard RPM macro could be created:
>
> %prep
> %setup -q
> %{git_apply_patches}
>
> which would expand to something like:
>
> git init
> git config user.email "%{name}-owner at fedoraproject.org"
> git config user.name "%{name}"
> git add .
> git commit -a -q -m "%{version} baseline"
> git am %{patches}
Or maybe we could start using %autosetup ?
http://www.rpm.org/wiki/PackagerDocs/Autosetup
--
Mathieu
More information about the devel
mailing list