Download raw body.
add got patch subcommand
On Mon, Mar 07, 2022 at 09:27:28PM +0100, Omar Polo wrote: > Hello, > > some time ago stsp suggested that got should be able to apply diffs by > itself. Using the VCS to apply them allows in fact some nice > comodities: for instance added and removed files are automatically > tracked. > > The rather long diff attached is just that. It's a simple and (i think) > straightforward implementation of patch(1) only integrated inside got. > There's a new got-read-patch libexec helpers (which borrows some lines > of code from Larry' patch, but it's mostly rewritten from scratch) that > is used to parse the content of the diff, similarly to the others > got-read-* helpers and under the same restrictions, and lib/patch.c that > wraps it. Thanks, this is great! A very good starting point. I think you should go ahead and put these changes on the main branch. They do not break the build and tests are passing. We do not lose anything even if this feature gets shipped in an incomplete state, and you will be able to make progress faster as people run into problems trying to use this. You could then also respond to reviews of your initial diff here by sending smaller diffs with fixes back to the list, which makes things easier for all of us.
add got patch subcommand