How can I list files CVS without an initial checkout?
如何在没有初始结账的情况下列出CVS文件?
In subversion I can simply do "svn ls http://svn.svn.com" in CVS how can I do this?
在颠覆中我可以简单地在CVS中做“svn ls http://svn.svn.com”我该怎么做?
For example I've got this CVS connection:
例如,我有这个CVS连接:
pserver:anonymous@evocms.cvs.sourceforge.net:/cvsroot/evocms
How can I list all files in it?
如何列出其中的所有文件?
UPDATE:
I'm doing this:
我这样做:
c:\>set CVSROOT=pserver:anonymous@evocms.cvs.sourceforge.net:/cvsroot/evocms
c:\>cvs -list ---> doesn't work, prints out the help screen
8 个解决方案
#1
If it's a one-off operation you don't need to set the CVSROOT
environment variable. Just use the -d
argument for ad-hoc repository specification.
如果是一次性操作,则无需设置CVSROOT环境变量。只需将-d参数用于ad-hoc存储库规范。
If your version of CVS/CVSNT is not too old (to be exact you'd need either CVS 1.12.8 or higher or CVSNT) then, as others have said, after having logged in
如果您的CVS / CVSNT版本不是太旧(确切地说您需要CVS 1.12.8或更高版本或CVSNT),那么,正如其他人所说,在登录后
cvs ls
should work just fine.
应该工作得很好。
If your version of CVS/CVSNT does not support the ls
command then you can try
如果您的CVS / CVSNT版本不支持ls命令,那么您可以尝试
cvs checkout -c
which will only dump the list of predefined modules.
这将只转储预定义模块的列表。
If your version of CVS/CVSNT is old enough you might get lucky with the following hack (does not work with more recent versions of CVSNT unless compatibility mode has been enabled on the server):
如果您的CVS / CVSNT版本足够老,您可能会幸运得到以下hack(除非在服务器上启用了兼容模式,否则不能与更新版本的CVSNT一起使用):
First check out the root of the repository to some temp location , so we have the necessary metadata:
首先将存储库的根目录检出到某个临时位置,这样我们就拥有了必要的元数据:
cvs -d[your CVSROOT string] co -l -dTemp .
Then simulate an update (with directories) of that folder:
然后模拟该文件夹的更新(包含目录):
cd Temp
cvs -n up -d
This will emit (almost) the same output as an actual checkout without actually getting the files from the server.
这将发出(几乎)与实际结账相同的输出,而不实际从服务器获取文件。
If you're on Windows and using a fairly recent version of CVSNT as the client then cvs ls
will actually automatically fall back to this mechanism when it detects a server that does not support ls
itself.
如果您使用的是Windows并且使用相当新版本的CVSNT作为客户端,则当cvs ls检测到不支持ls的服务器时,它实际上将自动回退到此机制。
Oh yes, and AFAICT there is no such thing as cvs -list
. It's not even valid CVS command line syntax: -list
would have to be a global argument rather than a command as it follows directly after the cvs
and there is no actual command specified. But then again, all multi-letter arguments (such as --help
) would have to start with a double dash, e.g. cvs --version
. Were you all maybe thinking of cvs list
which would be a mere alias for cvs ls
?
哦,是的,AFAICT没有cvs -list这样的东西。它甚至不是有效的CVS命令行语法:-list必须是全局参数而不是命令,因为它直接跟在cvs之后,并且没有指定实际命令。但话说回来,所有多字母参数(例如--help)都必须以双短划线开头,例如: cvs --version。大家都在想cvs列表,这只是cvs ls的别名吗?
#2
cvs -d $CVSROOT rls
hope this helps (cvs ver. 1.12.13)
希望这会有所帮助(cvs ver.1.12.13)
#3
You need to do a login first, like this:
您需要先登录,如下所示:
cvs -d :pserver:anonymous@evocms.cvs.sourceforge.net:/cvsroot/evocms login
cvs -d:pserver:anonymous@evocms.cvs.sourceforge.net:/ cvsroot / evocms login
Then, as others have said, use the ls command.
然后,正如其他人所说,使用ls命令。
For background, see a discussion of remote repositories
有关背景信息,请参阅远程存储库的讨论
#4
This is what I use. msolorzano is my login, and password, and "Deployer" is the module:
这就是我使用的。 msolorzano是我的登录名和密码,“Deployer”是模块:
cvs -d :pserver:msolorzano:password@gtess-cvs:/cvsdata/data1 rlog -R Deployer
...as a matter of fact, you can vet a cvs list of files in a "clean way" if you are executing commands in a UNIX/Linux environment, like this:
...事实上,如果您在UNIX / Linux环境中执行命令,则可以以“干净的方式”审查文件的cvs列表,如下所示:
cvs -d :pserver:msolorzano:password@gtess-cvs:/cvsdata/data1 rlog Deployer | grep ',v' | sed 's/RCS file: //g' | sed s/,v//g
#5
there is a similiar command in cvs
在cvs中有一个类似的命令
Usage: cvs ls
cvs -list to list modules, ls to list contents of modules.
用法:cvs ls cvs -list列出模块,ls列出模块内容。
EDIT: They are right, the commands list and ls are the same, I´m sorry for that.
编辑:他们是对的,命令列表和ls是相同的,我很抱歉。
well I don´t really see how to list a cvs dir without actually checking it out. Does the repo your are trying to access have a cvsweb access?
好吧,我真的没有看到如何列出一个cvs目录而没有实际检查出来。您尝试访问的repo是否具有cvsweb访问权限?
#6
#7
All,
Here is a comprehensive way to do it:
这是一个全面的方法:
- Fire up the command prompt
- Copy this cvs -d CVSROOT login (or, whatever your corresponding CVSROOT is)
- Type in your password and press enter when prompted. It may take a while, but after that is done, a new prompt will be available.
- Type in cvs –d cvs -d CVSROOT ls
- BAM! There's your listing
启动命令提示符
复制此cvs -d CVSROOT登录(或者,无论您的相应CVSROOT是什么)
输入您的密码,然后在出现提示时按Enter键。可能需要一段时间,但在此之后,将提供新的提示。
输入cvs -d cvs -d CVSROOT ls
BAM!这是你的清单
Keep in mind, if you don't have CVSROOT defined, you can just copy and paste your own CVSROOT here.
请记住,如果您没有定义CVSROOT,您可以在此复制并粘贴您自己的CVSROOT。
#8
cvs -d [CVS_ROOT] rlog {module_name}
cvs -d [CVS_ROOT] rlog {module_name}
#1
If it's a one-off operation you don't need to set the CVSROOT
environment variable. Just use the -d
argument for ad-hoc repository specification.
如果是一次性操作,则无需设置CVSROOT环境变量。只需将-d参数用于ad-hoc存储库规范。
If your version of CVS/CVSNT is not too old (to be exact you'd need either CVS 1.12.8 or higher or CVSNT) then, as others have said, after having logged in
如果您的CVS / CVSNT版本不是太旧(确切地说您需要CVS 1.12.8或更高版本或CVSNT),那么,正如其他人所说,在登录后
cvs ls
should work just fine.
应该工作得很好。
If your version of CVS/CVSNT does not support the ls
command then you can try
如果您的CVS / CVSNT版本不支持ls命令,那么您可以尝试
cvs checkout -c
which will only dump the list of predefined modules.
这将只转储预定义模块的列表。
If your version of CVS/CVSNT is old enough you might get lucky with the following hack (does not work with more recent versions of CVSNT unless compatibility mode has been enabled on the server):
如果您的CVS / CVSNT版本足够老,您可能会幸运得到以下hack(除非在服务器上启用了兼容模式,否则不能与更新版本的CVSNT一起使用):
First check out the root of the repository to some temp location , so we have the necessary metadata:
首先将存储库的根目录检出到某个临时位置,这样我们就拥有了必要的元数据:
cvs -d[your CVSROOT string] co -l -dTemp .
Then simulate an update (with directories) of that folder:
然后模拟该文件夹的更新(包含目录):
cd Temp
cvs -n up -d
This will emit (almost) the same output as an actual checkout without actually getting the files from the server.
这将发出(几乎)与实际结账相同的输出,而不实际从服务器获取文件。
If you're on Windows and using a fairly recent version of CVSNT as the client then cvs ls
will actually automatically fall back to this mechanism when it detects a server that does not support ls
itself.
如果您使用的是Windows并且使用相当新版本的CVSNT作为客户端,则当cvs ls检测到不支持ls的服务器时,它实际上将自动回退到此机制。
Oh yes, and AFAICT there is no such thing as cvs -list
. It's not even valid CVS command line syntax: -list
would have to be a global argument rather than a command as it follows directly after the cvs
and there is no actual command specified. But then again, all multi-letter arguments (such as --help
) would have to start with a double dash, e.g. cvs --version
. Were you all maybe thinking of cvs list
which would be a mere alias for cvs ls
?
哦,是的,AFAICT没有cvs -list这样的东西。它甚至不是有效的CVS命令行语法:-list必须是全局参数而不是命令,因为它直接跟在cvs之后,并且没有指定实际命令。但话说回来,所有多字母参数(例如--help)都必须以双短划线开头,例如: cvs --version。大家都在想cvs列表,这只是cvs ls的别名吗?
#2
cvs -d $CVSROOT rls
hope this helps (cvs ver. 1.12.13)
希望这会有所帮助(cvs ver.1.12.13)
#3
You need to do a login first, like this:
您需要先登录,如下所示:
cvs -d :pserver:anonymous@evocms.cvs.sourceforge.net:/cvsroot/evocms login
cvs -d:pserver:anonymous@evocms.cvs.sourceforge.net:/ cvsroot / evocms login
Then, as others have said, use the ls command.
然后,正如其他人所说,使用ls命令。
For background, see a discussion of remote repositories
有关背景信息,请参阅远程存储库的讨论
#4
This is what I use. msolorzano is my login, and password, and "Deployer" is the module:
这就是我使用的。 msolorzano是我的登录名和密码,“Deployer”是模块:
cvs -d :pserver:msolorzano:password@gtess-cvs:/cvsdata/data1 rlog -R Deployer
...as a matter of fact, you can vet a cvs list of files in a "clean way" if you are executing commands in a UNIX/Linux environment, like this:
...事实上,如果您在UNIX / Linux环境中执行命令,则可以以“干净的方式”审查文件的cvs列表,如下所示:
cvs -d :pserver:msolorzano:password@gtess-cvs:/cvsdata/data1 rlog Deployer | grep ',v' | sed 's/RCS file: //g' | sed s/,v//g
#5
there is a similiar command in cvs
在cvs中有一个类似的命令
Usage: cvs ls
cvs -list to list modules, ls to list contents of modules.
用法:cvs ls cvs -list列出模块,ls列出模块内容。
EDIT: They are right, the commands list and ls are the same, I´m sorry for that.
编辑:他们是对的,命令列表和ls是相同的,我很抱歉。
well I don´t really see how to list a cvs dir without actually checking it out. Does the repo your are trying to access have a cvsweb access?
好吧,我真的没有看到如何列出一个cvs目录而没有实际检查出来。您尝试访问的repo是否具有cvsweb访问权限?
#6
#7
All,
Here is a comprehensive way to do it:
这是一个全面的方法:
- Fire up the command prompt
- Copy this cvs -d CVSROOT login (or, whatever your corresponding CVSROOT is)
- Type in your password and press enter when prompted. It may take a while, but after that is done, a new prompt will be available.
- Type in cvs –d cvs -d CVSROOT ls
- BAM! There's your listing
启动命令提示符
复制此cvs -d CVSROOT登录(或者,无论您的相应CVSROOT是什么)
输入您的密码,然后在出现提示时按Enter键。可能需要一段时间,但在此之后,将提供新的提示。
输入cvs -d cvs -d CVSROOT ls
BAM!这是你的清单
Keep in mind, if you don't have CVSROOT defined, you can just copy and paste your own CVSROOT here.
请记住,如果您没有定义CVSROOT,您可以在此复制并粘贴您自己的CVSROOT。
#8
cvs -d [CVS_ROOT] rlog {module_name}
cvs -d [CVS_ROOT] rlog {module_name}