[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gnu-arch-users] Re: script to convert set of dirs into arch repo
From: |
Aspect |
Subject: |
Re: [Gnu-arch-users] Re: script to convert set of dirs into arch repo |
Date: |
Tue, 9 Sep 2003 13:16:43 +1000 |
User-agent: |
Mutt/1.2.5i |
On Tue, Sep 09, 2003 at 11:06:18AM +0900, Miles Bader wrote:
> Zack Brown <address@hidden> writes:
> > Has anyone written a script to convert a set of directories, each
> > representing one version of a project, into an arch repo? ideally it
> > would also be possible to run the same script on additional
> > directories later on, and have them add future versions of the same
> > project to that repo.
>
> My impression from earlier conversations on this list is that the
> easiest way is to:
>
> (1) Import the first directory, and get an arch project tree.
>
> (2) For each subsequent directory, compute a diff against the previous
> one, apply it to the project tree using patch, and commit the
> project tree. You may need to fiddle with file id-tags after
> running patch and before committing (you can use my tla-update-tags
> script :-).
I'm in a similar situation of needing to import archives like this .. but
using huge trees (one is a complete installable filesystem image) so `diff`
isn't much of an option for me. Besides, I want to version permissions changes
between the trees.
(WARNING - arch newbie - the following may read like a horror story to others)
What presently seems the best way to do this is:
cd project-0.1
tla make-category project
tla make-branch project--mainline
tla make-version project--mainline--0.1
tla init-tree project--mainline--0.1
vi `tla make-log`
tla tagging-method implicit # YMMV - use tree-lint to fix tagging properly
tla import
tla commit
cd ..
# prepare for a new version
tla make-version project--mainline--0.2
tla project--mainline--0.2 project--mainline--0.1
# here comes the dirty hack:
cd 0.2
tla get project--mainline--0.2 .
mv {arch} ../project-0.2
cd ../project-0.2
vi `tla make-log`
tla tree-lint
tla commit
... this appears to have worked on some small test trees .. is it even
remotely safe??