On Jan 22, 2008, at 2:51 PM, Kevin Horn wrote:
> On Jan 20, 2008 7:20 PM, Ian Bicking <[EMAIL PROTECTED]> wrote:
>
> My thoughts for this (which I've never got around to implementing) is
> that paster create could write .filename.orig everytime it writes a
> file, and when doing another create you could check if the file has
> changed.
>
> Another possibility, which is harder to code but probably nicer, is if
> you could do a merge of sorts; make sure the raw paster create'd files
> are committed, store that revision somehow (maybe in a log message
> that
> you could search for). Then to update the template branch at the
> revision of the original generated code, write over it with the new
> templates, check that in, then take that and merge it back to the
> trunk.
> Any conflict should be a genuine conflict, that happened because they
> edited the files.
>
>
> As I said I'd like to start with the simplest possible case . I
> think tying everything in with version control would be a mistake.
I think what would be ideal is:
o paster create also makes a copy of the template in a dir of the
project (say .base_template):
myproj/
setup.py
myproj/
__init__.py
firstmodule.py
. base_template/
setup.py
myproj/
__init__.py
firstmodule.py
o when we run paster create (or upgrade/restart) later, it
uses .base_template dir for a 3 way merge (and updates
the .base_template dir when it's finished)
I think we could utilize mercurial's hgmerge code for doing this --
it just attempts a 3 way merge with diff3 if it exists, and if it
fails it falls back to an interactive merge tool if it detects one.
Of course I don't think it works at all with Windows, but who cares? =]
--
Philip Jenvey
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears Trunk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/turbogears-trunk?hl=en
-~----------~----~----~----~------~----~------~--~---