sourceforge: Do not consider Attic as a valid CVS module

The Attic folder that can sometimes be found in a CVS respository
is a special one used by CVS to store RCS files and should not be
considered as a valid module name when listing CVS projects.
This commit is contained in:
Antoine Lambert 2022-04-21 16:08:06 +02:00
parent 20c1351aa0
commit 63a744559f
2 changed files with 9 additions and 7 deletions

View file

@ -386,14 +386,15 @@ class SourceForgeLister(Lister[SourceForgeListerState, SourceForgeListerPage]):
match = re.search(rf".*/cvsroot/{project} co -P (.+)", text)
if match is not None:
module = match.group(1)
url = f"{cvs_base_url}/{project}/{module}"
hits.append(
SourceForgeListerEntry(
vcs=VcsNames(tool_name),
url=url,
last_modified=last_modified,
if module != "Attic":
url = f"{cvs_base_url}/{project}/{module}"
hits.append(
SourceForgeListerEntry(
vcs=VcsNames(tool_name),
url=url,
last_modified=last_modified,
)
)
)
continue
url = CLONE_URL_FORMAT.format(
vcs=tool_name,

View file

@ -16,6 +16,7 @@
You can run a per-module CVS checkout via pserver protocol:
<li><b>cvs -z3 -d:pserver:anonymous@a.cvs.sourceforge.net:/cvsroot/aaron co -P aaron</b></li>
<li><b>cvs -z3 -d:pserver:anonymous@a.cvs.sourceforge.net:/cvsroot/aaron co -P www</b></li>
<li><b>cvs -z3 -d:pserver:anonymous@a.cvs.sourceforge.net:/cvsroot/aaron co -P Attic</b></li>
<p>You can view a list of files or copy all the CVS repository data via rsync (the 1st command lists the files, the 2nd copies):
<li><b>rsync -a a.cvs.sourceforge.net::cvsroot/aaron/</b></li>
<li><b>rsync -ai a.cvs.sourceforge.net::cvsroot/aaron/ /my/local/dest/dir/</b></li>