git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] git-cvsimport: Add support for CVSNT as an underlying client
@ 2008-03-13 17:45 Emil Medve
  0 siblings, 0 replies; only message in thread
From: Emil Medve @ 2008-03-13 17:45 UTC (permalink / raw)
  To: gitster, git; +Cc: Emil Medve

CVSNT seems to feature the following relevant differences from classic CVS:
	1. Keeps the password information in ~/.cvs/cvspass instead of ~/.cvspass
	2. Used '=' to separate fields in cvspass instead of ' '

Signed-off-by: Emil Medve <Emilian.Medve@Freescale.com>
---
 git-cvsimport.perl |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/git-cvsimport.perl b/git-cvsimport.perl
index 95c5eec..90bd6cc 100755
--- a/git-cvsimport.perl
+++ b/git-cvsimport.perl
@@ -238,12 +238,13 @@ sub conn {
 		my $rr = ":pserver:$user\@$serv:$port$repo";
 
 		unless ($pass) {
-			open(H,$ENV{'HOME'}."/.cvspass") and do {
+			(open(H,$ENV{'HOME'}."/.cvspass") or
+			 open(H,$ENV{'HOME'}."/.cvs/cvspass")) and do {
 				# :pserver:cvs@mea.tmt.tele.fi:/cvsroot/zmailer Ah<Z
 				while (<H>) {
 					chomp;
 					s/^\/\d+\s+//;
-					my ($w,$p) = split(/\s/,$_,2);
+					my ($w,$p) = split(/\s|=/,$_,2);
 					if ($w eq $rr or $w eq $rr2) {
 						$pass = $p;
 						last;
-- 
1.5.4.GIT

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2008-03-13 17:51 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-03-13 17:45 [PATCH v2] git-cvsimport: Add support for CVSNT as an underlying client Emil Medve

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).