Martin Pool's blog

Generating complete patches from Arch

One thing that would be good for arch is being able to generate complete diffs that can be sent upstream to maintainers who aren't using Arch. At the moment you can send a changeset as a tarball, which is both the native format and something that can reasonably easily be read by somebody else:

,patch-10/
|-- mod-dirs-index
|-- mod-files-index
|-- modified-only-dir-metadata
|-- new-files-archive
|   |-- src
|   |   |-- lift-conn.h
|   |   `-- sftp-const.h
|   `-- {arch}
|       `-- superlifter
|           `-- superlifter--mainline
|               `-- superlifter--mainline--0.1
|                   `-- mbp@sourcefrog.net--2004-happy
|                       `-- patch-log
|                           `-- patch-10
|-- orig-dirs-index
|-- orig-files-index
|-- original-only-dir-metadata
|-- patches
|   `-- src
|       `-- lift.c.patch
`-- removed-files-archive

Pulling this apart is slightly too much work to ask of somebody who doesn't really care about using arch. If you post a tarball containing patches and newfiles to most development lists, you're likely to be knocked back and asked to just post plain diffs.

It would be nice if you could say tla show-changeset --diffs -N and get pseudo-diffs for added and removed files as well as changed files. Obviously this can't handle renamed files, but renaming files is not something that non-core developers do on this kind of project. (Actually I think, but I haven't checked, that arch would understand moved files in this case if the files had arch-tag unique IDs.) Adding new files is pretty common, so that really needs to be supported.

This would also make the submitter's patch log comments visible as files added under the {arch} directory. I'm not sure if that would be so popular with upstreams not using arch. Perhaps there needs to be an option to exclude them.

I think that if the generated patch was applied to an arch directory, it would correctly update everything including the patch log. This isn't as good, in a sense, as getting the changeset as a tarball -- you might not get permission changes, for example.

But I think being able to push around changes over email is a worthwhile model, and it's good if arch can support it. In particular many of the people currently doing loose distributed development are doing so by mailing patches. Those people are closest to using arch so it's good if the transition can be easier.

Archives 2008: Apr Feb 2007: Jul May Feb Jan 2006: Dec Nov Oct Sep Aug Jul Jun Jan 2005: Sep Aug Jul Jun May Apr Mar Feb Jan 2004: Dec Nov Oct Sep Aug Jul Jun May Apr Mar Feb Jan 2003: Dec Nov Oct Sep Aug Jul Jun May