--- a/AbstractSettingsApplication.st Mon Oct 27 10:29:32 2003 +0100
+++ b/AbstractSettingsApplication.st Mon Oct 27 11:01:43 2003 +0100
@@ -8950,10 +8950,9 @@
makeExecutableForAll.
]
].
- (fn exists
- and:[fn isDirectory
+ (fn isDirectory
and:[fn isReadable
- and:[fn isWritable]]]) ifTrue:[
+ and:[fn isWritable]]) ifTrue:[
AbstractSourceCodeManager cacheDirectoryName:(self sourceCacheDir value).
] ifFalse:[
self warn:'Invalid sourceCache directory.'
@@ -9089,27 +9088,28 @@
cvsRootHolder
cvsRootHolder isNil ifTrue:[
- cvsRootHolder := ValueHolder new.
+ cvsRootHolder := self cvsRootFromCVSRootFileOrNil asValue.
cvsRootHolder onChangeSend:#updateModifiedChannel to:self
].
^ cvsRootHolder.
!
cvsRootPrototypeList
+ |cvsRoot|
cvsRootPrototypeList isNil ifTrue:[
- OperatingSystem getDomainName = 'exept' ifFalse:[
+ OperatingSystem getDomainName = 'exept' ifTrue:[
+ cvsRootPrototypeList := #(
+ '/cvs/stx'
+ 'exept:/cvs/stx'
+ ).
+ cvsRootPrototypeList := cvsRootPrototypeList copyWith:(':pserver:' , OperatingSystem getLoginName , '@exept:/cvs/stx')
+ ] ifFalse:[
cvsRootPrototypeList := #(
'host:/cvs/stx'
':pserver:user@host:/cvs/stx'
).
cvsRootPrototypeList := cvsRootPrototypeList copyWith:(':pserver:' , OperatingSystem getLoginName , '@host:/cvs/stx')
- ] ifTrue:[
- cvsRootPrototypeList := #(
- '/cvs/stx'
- 'exept:/cvs/stx'
- ).
- cvsRootPrototypeList := cvsRootPrototypeList copyWith:(':pserver:' , OperatingSystem getLoginName , '@exept:/cvs/stx')
].
OperatingSystem isUNIXlike ifTrue:[
@@ -9125,6 +9125,11 @@
"there might be more here in the future"
]
].
+
+ cvsRoot := self cvsRootFromCVSRootFileOrNil.
+ (cvsRoot notNil and:[(cvsRootPrototypeList includes:cvsRoot) not]) ifTrue:[
+ cvsRootPrototypeList := (Array with:cvsRoot) , cvsRootPrototypeList
+ ].
].
^ cvsRootPrototypeList.
!
@@ -9227,10 +9232,9 @@
^ self.
].
].
- (fn exists
- and:[fn isDirectory
+ (fn isDirectory
and:[fn isReadable
- and:[fn isWritable]]]) ifTrue:[
+ and:[fn isWritable]]) ifTrue:[
AbstractSourceCodeManager cacheDirectoryName:nm.
] ifFalse:[
self warn:'Invalid sourceCache directory.'.
@@ -9277,6 +9281,19 @@
!AbstractSettingsApplication::SourceCodeManagementSettingsAppl methodsFor:'queries'!
+cvsRootFromCVSRootFileOrNil
+ |cvsDir cvsRootFile cvsRoot|
+
+ cvsDir := 'CVS' asFilename.
+ cvsDir isDirectory ifTrue:[
+ cvsRootFile := cvsDir construct:'Root'.
+ cvsRootFile isReadable ifTrue:[
+ cvsRoot := cvsRootFile contents firstIfEmpty:nil.
+ ].
+ ].
+ ^ cvsRoot
+!
+
hasManager
^ AbstractSourceCodeManager notNil
and:[AbstractSourceCodeManager isLoaded]
@@ -10894,5 +10911,5 @@
!AbstractSettingsApplication class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libtool/AbstractSettingsApplication.st,v 1.117 2003-10-21 22:55:18 cg Exp $'
-! !
+ ^ '$Header: /cvs/stx/stx/libtool/AbstractSettingsApplication.st,v 1.118 2003-10-27 10:01:19 cg Exp $'
+! !