On 31. 03. 23 13:58, Petr Menšík wrote:
Is there also documented and preferred way to apply just single patch when
%autosetup -N -S git is used? I mean, if I want to have all patches applied
git-like way, I know I can use -m or -M parameters to %autopatch. But
%autopatch -m 1 -M 1 does not look nice.
I haven't found how to do that from comments in /usr/lib/rpm/macros. Can you help?
%autopatch 1
https://github.com/rpm-software-management/rpm/blob/rpm-4.18.1-release/macros.in#L1236-L1239
> %autopatch
> Apply patches using %autosetup configured SCM.
> Typically used with no arguments to apply all patches in the order
> introduced in the spec, but alternatively can be used to apply indvidual
> patches in arbitrary order by passing them as arguments.
Also documented in
https://rpm-software-management.github.io/rpm/manual/autosetup.html#autopatch
> Some examples:
> Apply patches with number >= 100
> %autopatch -m 100
>
> Apply patches with number <= 400
> %autopatch -M 400
>
> Apply patches 80 to 99, inclusive
> %autopatch -m 80 -M 99
>
> Apply patches 1, 4 and 6
> %autopatch 1 4 6
The individual patch numbers as arguments feature is available since RPM 4.17,
see https://github.com/rpm-software-management/rpm/pull/1697
--
Miro Hrončok
--
Phone: +420777974800
IRC: mhroncok
_______________________________________________
devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx
Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue