Skip to content
Permalink
Browse files

Add support for non-pserver anon cvs access. Thanks, Jay!

Submitted by:   Jay Sachs <jay@contravariant.org>

git-svn-id: https://svn.macports.org/repository/macports/trunk/base@4458 d073be05-634f-4543-b044-5fe20cf6d1d6
  • Loading branch information
Jordan K. Hubbard
Jordan K. Hubbard committed Jan 5, 2004
1 parent d13a4fb commit 495eaea03861f629562a05d59b6018e7b558c7c0
Showing with 11 additions and 7 deletions.
  1. +11 −7 src/port1.0/portfetch.tcl
@@ -264,18 +264,22 @@ proc checkfiles {args} {
proc cvsfetch {args} {
global workpath cvs.password cvs.args cvs.post_args cvs.tag cvs.module cvs.cmd cvs.env
cd $workpath
set cvs.args login
set cvs.cmd "echo ${cvs.password} | /usr/bin/env ${cvs.env} cvs"
# XXX cvs will request a password from the tty using getpass()
# unless there is no controling terminal
if {[catch {system -notty "[command cvs] 2>&1"} result]} {
return -code error [msgcat::mc "CVS login failed"]
if {[regexp ^:pserver: cvs.root]} {
set cvs.args login
set cvs.cmd "echo ${cvs.password} | /usr/bin/env ${cvs.env} cvs"
# XXX cvs will request a password from the tty using getpass()
# unless there is no controling terminal
if {[catch {system -notty "[command cvs] 2>&1"} result]} {
return -code error [msgcat::mc "CVS login failed"]
}
} else {
set env(CVS_RSH) ssh
}
set cvs.args "co -r ${cvs.tag}"
set cvs.cmd cvs
set cvs.post_args "${cvs.module}"
if {[catch {system "[command cvs] 2>&1"} result]} {
return -code error [msgcat::mc "CVS check out failed"]
return -code error [msgcat::mc "CVS check out failed"]
}
return 0
}

0 comments on commit 495eaea

Please sign in to comment.
You can’t perform that action at this time.