Bug#342296: 'man plotchangelog' typos / auto patching
On Sat, 10 Dec 2005 20:47:28 + Julian Gilbey [EMAIL PROTECTED] wrote: Almost. This should be perfect: --- annotate-output.1 16:08:58.0 -0500 +++ /tmp/annotateoutput.1.192812005-12-06 02:27:58.0 -0500 The first line could have the path in it but not necessarily. The key thing, though, is that you are patching the *uncompressed* pages, so don't have a .gz suffix in the original file name. Well, I've written then tested some code, (what you suggested, with a kludgy variation of the 'mktemp -d' stuff), that displays it like so: --- annotate-output.1 2005-12-03 16:08:58.0 -0500 +++ /tmp/annotate-output.1 2005-12-14 02:58:27.0 -0500 Note that the date of the original is preserved. Thanks again for the good suggestions and resulting improvement. More later on the other points from your 12/7 reply. -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#342296: 'man plotchangelog' typos / auto patching
On Wed, Dec 14, 2005 at 03:38:17AM -0500, A. Costa wrote: --- annotate-output.1 16:08:58.0 -0500 +++ /tmp/annotateoutput.1.192812005-12-06 02:27:58.0 -0500 The first line could have the path in it but not necessarily. The key thing, though, is that you are patching the *uncompressed* pages, so don't have a .gz suffix in the original file name. Well, I've written then tested some code, (what you suggested, with a kludgy variation of the 'mktemp -d' stuff), that displays it like so: --- annotate-output.1 2005-12-03 16:08:58.0 -0500 +++ /tmp/annotate-output.1 2005-12-14 02:58:27.0 -0500 Note that the date of the original is preserved. Thanks again for the good suggestions and resulting improvement. More later on the other points from your 12/7 reply. Great, thanks! (patch ignores the date, but it's nice to keep it!) Julian -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#342296: 'man plotchangelog' typos / auto patching
On Sat, Dec 10, 2005 at 02:24:29AM -0500, A. Costa wrote: Hi, thanks for the useful critique, for which to simplify things I'd prefer to reply to one thing at a time if that's OK; and first up is: OK! On Wed, 7 Dec 2005 17:40:33 + Julian Gilbey [EMAIL PROTECTED] wrote: - patch against the actual original file rather than something from stdin: the patch file headings such as: --- - 2005-12-06 02:27:58.437196000 -0500 +++ /tmp/annotateoutput.1.gz.19281 2005-12-06 02:27:58.0 -0500 make it impossible to use patch automatically. Thanks very very much for pointing that out. Should be easy to code, assuming I correctly understand the format, (I'm working on this typo-tool, which is why all the typo bugs are boilerplate). Would you say if the following would be what's needed: --- /usr/share/man/man1/annotate-output.1.gz 16:08:58.0 -0500 +++ /tmp/annotateoutput.1.gz.19281 2005-12-06 02:27:58.0 -0500 ...or if that's wrong, (I'm not a maintainer), suggest what the better format should be? Almost. This should be perfect: --- annotate-output.1 16:08:58.0 -0500 +++ /tmp/annotateoutput.1.192812005-12-06 02:27:58.0 -0500 The first line could have the path in it but not necessarily. The key thing, though, is that you are patching the *uncompressed* pages, so don't have a .gz suffix in the original file name. Or consider the source code (shell script) that's making the errant diff: zdiff --unified --minimal $MANPAGELONGNAME $EDITABLEMANPAGE $DIFFNAME ...where $MANPAGELONGNAME is the full path and file name of the man page, and $EDITABLEMANPAGE and $DIFFNAME are just what they sound like and live in '/tmp'. Perhaps there are better ways or tools; if not, once I know the right format I could code something to parse the '.diff' after the fact into something better for patching. If possible, please advise! Ah, I see. If you can either pass the zdiff output through a perl script or do the following short script, it would be better. (You may want to do this much more safely, making a temporary directory first with mktemp -d depending on your setup.) cp $MANPAGELONGNAME /tmp gunzip /tmp/$MANPAGESHORTNAME diff --unified --minimal /tmp/$MANPAGESHORTNAME $DIFFNAME rm /tmp/$MANPAGESSHORTNAME Julian -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]
Bug#342296: 'man plotchangelog' typos / auto patching
Hi, thanks for the useful critique, for which to simplify things I'd prefer to reply to one thing at a time if that's OK; and first up is: On Wed, 7 Dec 2005 17:40:33 + Julian Gilbey [EMAIL PROTECTED] wrote: - patch against the actual original file rather than something from stdin: the patch file headings such as: --- - 2005-12-06 02:27:58.437196000 -0500 +++ /tmp/annotateoutput.1.gz.192812005-12-06 02:27:58.0 -0500 make it impossible to use patch automatically. Thanks very very much for pointing that out. Should be easy to code, assuming I correctly understand the format, (I'm working on this typo-tool, which is why all the typo bugs are boilerplate). Would you say if the following would be what's needed: --- /usr/share/man/man1/annotate-output.1.gz 16:08:58.0 -0500 +++ /tmp/annotateoutput.1.gz.19281 2005-12-06 02:27:58.0 -0500 ...or if that's wrong, (I'm not a maintainer), suggest what the better format should be? Or consider the source code (shell script) that's making the errant diff: zdiff --unified --minimal $MANPAGELONGNAME $EDITABLEMANPAGE $DIFFNAME ...where $MANPAGELONGNAME is the full path and file name of the man page, and $EDITABLEMANPAGE and $DIFFNAME are just what they sound like and live in '/tmp'. Perhaps there are better ways or tools; if not, once I know the right format I could code something to parse the '.diff' after the fact into something better for patching. If possible, please advise! -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of unsubscribe. Trouble? Contact [EMAIL PROTECTED]