Re: Command-line option to exclude files from the conversion

Michael Haggerty <[email protected]> Mon, 06 Apr 2015 11:21:31 +0200
Newsgroups gmane.comp.version-control.subversion.cvs2svn.devel
Message-ID <[email protected]>
On 04/06/2015 12:53 AM, sags wrote:
> In case it will be of some use to someone, I attach a patch that adds
> a "--exclude-path=3DREPOPATH/REPOFILE,v" command-line option. Its
> purpose is to specify one or more files (can be used repeatedly) to
> be excluded from the conversion without the need of a *.options
> file.
>=20
> I used it to exclude a .gitatributes file that I added to the CVS
> repo in preparation of the conversion to GIT, but which finally had
> to be left out. I think it can be also used to selectively exclude
> main/attic files when there are name conflicts.

Hi,

Thanks for all the patches! The changes to support CVSNT, in particular,
have been requested by a lot of people and are especially welcome.

To make it easier for myself and other people to see your patches, I
just pushed versions to the GitHub mirror of the repository [1], as the
following branches:

A: sags/rcsparse-newphrases
B: sags/cvsnt-modes
C: sags/svntest-alignment
D: sags/cvs2git-default-eol
E: sags/exclude-path

It would be great if you could commit using your real name so that we
know who you are and can give you credit for the work, and please
confirm that you are OK with your work being released under the license
found in COPYING.

I looked at series E and pushed another commit on top if it that I think
makes it fit better into the code. Please let me know what you think.

Before these changes can get merged, they need some tests to show that
they work and to prevent regressions after future changes.

The easiest way to test the "--exclude-path" option would be to convert
an existing test repo, like "main", using

    args=3D['--exclude-path=3Dsingle-files/twoquick,v']

and then assert that the path doesn't exist in the output repository
with something like

    if conv.path_exists('trunk', 'single-files', 'twoquick'):
      raise Failure()

There are lots of examples in run-tests.py that you can imitate.

Thanks,
Michael

[1] https://github.com/mhagger/cvs2svn

--=20
Michael Haggerty
[email protected]

------------------------------------------------------
http://cvs2svn.tigris.org/ds/viewMessage.do?dsForumId=3D1667&dsMessageId=3D=
3110917

To unsubscribe from this discussion, e-mail: [[email protected]=
s.org].