record applied patchfiles in the statefile #345
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Adds a "patch: " line to the statefile and verify this record before applying each subsequent patch. This is a very useful mechanism during port maintenance when some patches have to be rebased; it allows repeated application of
port patch
(or "higher") where only the failing patch has to be reverted and already applied patches are skipped automatically.Notes:
Currently the name of the applied patch is taken from the resolved path to the patchfile and so cannot reliably include any form of hierarchical organisation used in the
filespath
directory. Aliasing is thus possible but has never happened to me in the several years that I have been using this mod.Should the record list the entries as specified in the port's
patchfiles
rather than inpatch_main
'spatch_list
?A similar modification will have to be made to the
patch_main
override in themuniversal-1.1
PG. Hence the changes proposed forcheck_statefile
andwrite_statefile
.Closes: https://trac.macports.org/ticket/46927