9 Commits

Author SHA1 Message Date
Paul Eggert
95e0092f97 maint: make update-copyright 2025-01-05 13:33:00 -08:00
Paul Eggert
d18c05d5bd Update copyright notices
Switch to single intervals for FSF notices,
and consistently put them first.
Update copyright notices for 2024.
* cfg.mk (update-copyright-env): Use UPDATE_COPYRIGHT_FORCE=1,
UPDATE_COPYRIGHT_USE_INTERVALS=2.
* patch.man: Always use \(co, so that update-copyright
updates these dates.
* src/version.c: Correct Larry Wall copyright years.
2024-08-28 23:13:44 -07:00
Quentin Casasnovas
c80b1a06a9 test-lib.sh: factorize require_* functions
Since the code is identical when just checking if a utility is present on
the system or not, we can factorize it.

Signed-off-by: Quentin Casasnovas <quentin.casasnovas@oracle.com>
2015-01-31 22:14:01 +01:00
Andreas Gruenbacher
99f2638763 Fix file truncation when switching from git diff to non-git diff
* src/patch.c (main): Output queued output files only when switching from a git
diff to a non-git diff.  This can modify the input file, so make sure to
stat() it again.
* tests/concat-git-diff: Add test case growing a file with a git diff and then
with a non-git diff; without this fix; the result would be truncated.
2012-09-18 12:53:38 +02:00
Andreas Gruenbacher
a18960d31e Detect concatenated git-style patches by tracking what's in the output queue
* src/patch.c (main): Instead of looking at the SHA hashes to detect
concatenated git-style patches, detect when a file to write to is already in
the output queue.
* tests/concat-git-diff: Add create/delete tests.
2012-08-08 13:39:08 +02:00
Dmitry V. Levin
3980c923dc Add another git-style diff concatenation regression test
* tests/concat-git-diff: Add test case here.
2012-08-08 13:02:31 +02:00
Andreas Gruenbacher
1e6c0d07ab In git-style diffs, create new files immediatetly and only remember files to modify
* src/patch.c (output_file): Create new files immediately.  Document why
things are implemented that way.
* tests/concat-git-diff: Fix glitch in test case.
2012-08-02 20:38:31 +02:00
Andreas Gruenbacher
120927804d Add file create test case which still needs to be fixed
* tests/concat-git-diff: Add file create test case.
2012-08-01 15:10:22 +02:00
Andreas Gruenbacher
6be1a126bd Try to recognize concatenated git diffs and handle them appropriately
* src/patch.c (main): Remember the "before" SHA1 hashes of git-style patches;
the same patch will always use the same "before" SHA1 for a specific file.
Try to recognize concatenated patches based on that.
* tests/concat-git-diff: New test case.
* tests/Makefile.am (TESTS): Add new test case.
2012-08-01 04:28:07 +02:00