--- a/GitSourceCodeManagementSettingsAppl.st Tue Jul 24 18:17:26 2012 +0100
+++ b/GitSourceCodeManagementSettingsAppl.st Wed Jul 25 10:51:30 2012 +0100
@@ -53,7 +53,7 @@
defaultRepositoryName
- ^ ''
+ ^ './gitRepository'
"Created: / 19-04-2011 / 11:00:11 / cg"
! !
@@ -839,7 +839,7 @@
]
].
- GitSourceCodeManager hgCommandTimeout:(self hgCommandTimeoutHolder value).
+ GitSourceCodeManager gitCommandTimeout:(self gitCommandTimeoutHolder value).
modules := repositoriesPerModule select:[:entry | entry first == GitSourceCodeManager].
infoPerModule := Dictionary new.
@@ -859,7 +859,7 @@
self acceptChannel value.
- "Modified: / 03-03-2012 / 11:25:12 / cg"
+ "Modified: / 23-07-2012 / 13:18:38 / cg"
!
removePerModuleRoot
@@ -876,7 +876,7 @@
"Modified: / 26-01-2012 / 13:50:08 / cg"
! !
-!GitSourceCodeManagementSettingsAppl methodsFor:'actions - mercurial'!
+!GitSourceCodeManagementSettingsAppl methodsFor:'actions - git'!
addPerModuleRoot
|module gitRepository|
@@ -893,34 +893,6 @@
"Modified (format): / 02-03-2012 / 15:22:41 / cg"
!
-basicSaveGitSettings
- |hgRepository|
-
- repositoryHolder notNil ifTrue:[
- repositoryHolder value size > 0 ifTrue:[
- manager notNil ifTrue:[
- manager initializeForRepository:repositoryHolder value.
- ]
- ].
- ].
- GitSourceCodeManager gitExecutable:((self gitExecutableHolder value ? '') withoutSeparators).
- GitSourceCodeManager initializeForRepository:(hgRepository := self repositoryHolder value).
- GitSourceCodeManager verboseSourceCodeAccess: verboseSourceCodeAccess value.
- GitSourceCodeManager shownInBrowserMenus:self shownInBrowserMenusHolder value.
-
- RecentlyUsedRepositoryURLS isNil ifTrue:[
- RecentlyUsedRepositoryURLS := OrderedCollection new.
- ].
- (RecentlyUsedRepositoryURLS includes:hgRepository) ifFalse:[
- RecentlyUsedRepositoryURLS addFirst:hgRepository.
- RecentlyUsedRepositoryURLS size > 20 ifTrue:[
- RecentlyUsedRepositoryURLS removeLast.
- ].
- ].
-
- "Created: / 02-03-2012 / 15:19:22 / cg"
-!
-
checkAccess
self halt:'unimplemented feature'
@@ -940,6 +912,40 @@
"Created: / 17-01-2012 / 17:42:27 / cg"
! !
+!GitSourceCodeManagementSettingsAppl methodsFor:'actions - mercurial'!
+
+basicSaveGitSettings
+ |gitRepository|
+
+ repositoryHolder notNil ifTrue:[
+ repositoryHolder value size > 0 ifTrue:[
+ manager notNil ifTrue:[
+ manager initializeForRepository:repositoryHolder value.
+ ]
+ ].
+ ].
+ GitSourceCodeManager gitExecutable:((self gitExecutableHolder value ? '') withoutSeparators).
+ self repositoryHolder value isEmptyOrNil ifTrue:[
+ Dialog information:'You must specify a valid gitRepository directory'.
+ ^ self.
+ ].
+ GitSourceCodeManager initializeForRepository:(gitRepository := self repositoryHolder value).
+ GitSourceCodeManager verboseSourceCodeAccess: verboseSourceCodeAccess value.
+ GitSourceCodeManager shownInBrowserMenus:self shownInBrowserMenusHolder value.
+
+ RecentlyUsedRepositoryURLS isNil ifTrue:[
+ RecentlyUsedRepositoryURLS := OrderedCollection new.
+ ].
+ (RecentlyUsedRepositoryURLS includes:gitRepository) ifFalse:[
+ RecentlyUsedRepositoryURLS addFirst:gitRepository.
+ RecentlyUsedRepositoryURLS size > 20 ifTrue:[
+ RecentlyUsedRepositoryURLS removeLast.
+ ].
+ ].
+
+ "Created: / 02-03-2012 / 15:19:22 / cg"
+! !
+
!GitSourceCodeManagementSettingsAppl methodsFor:'aspects'!
gitCommandTimeoutHolder
@@ -1030,7 +1036,7 @@
repositoryHolder
repositoryHolder isNil ifTrue:[
- repositoryHolder := '' asValue.
+ repositoryHolder := self class defaultRepositoryName asValue.
repositoryHolder addDependent:self.
].
^ repositoryHolder.
@@ -1119,73 +1125,9 @@
"Created: / 14-01-2012 / 20:24:57 / cg"
!
-sourceDirChanged
- |nm fn previousDir|
- manager isNil ifTrue:[^ self].
-
- previousDir := AbstractSourceCodeManager cacheDirectoryName.
-
- nm := self sourceCacheDir value.
- nm isEmptyOrNil ifTrue:[^ self].
-
- (fn := nm asFilename) exists ifFalse:[
- (self confirm:(resources
- stringWithCRs:'SourceCache directory "%1" does not exist.\Create ?'
- with:nm)
- ) ifFalse:[
- self sourceCacheDir value:previousDir.
- ^ self.
- ].
- fn
- recursiveMakeDirectory;
- makeReadableForAll;
- makeWritableForAll;
- makeExecutableForAll.
- ^ self.
- ].
-
- (fn isDirectory) ifFalse:[
- self warn:(resources
- stringWithCRs:'Not a directory: "%1"'
- with:nm).
- self sourceCacheDir value:previousDir.
- ^ self.
- ].
-
- (fn isReadable and:[fn isWritable]) ifFalse:[
- (self confirm:(resources
- stringWithCRs:'SourceCache directory "%1" is not both readable and writable.\Change ?'
- with:nm)
- ) ifFalse:[
- self sourceCacheDir value:previousDir.
- ^ self.
- ].
- fn
- makeReadableForAll;
- makeWritableForAll;
- makeExecutableForAll.
- ].
-"/ (fn isReadableForAll and:[fn isWritableForAll]) ifFalse:[
-"/ (self confirm:(resources
-"/ stringWithCRs:'SourceCache directory "%1" is not both readable and writable for other users.\Change ?'
-"/ with:nm)
-"/ ) ifTrue:[
-"/ fn
-"/ makeReadableForAll;
-"/ makeWritableForAll;
-"/ makeExecutableForAll.
-"/ ]
-"/ ].
-!
update:something with:aParameter from:changedObject
- "/ common
- changedObject == sourceCacheDir ifTrue:[
- self sourceDirChanged.
- self updateModifiedChannel.
- ^ self
- ].
"/ cvs
changedObject == repositoryHolder ifTrue:[
@@ -1279,13 +1221,13 @@
!GitSourceCodeManagementSettingsAppl class methodsFor:'documentation'!
version
- ^ '$Id: GitSourceCodeManagementSettingsAppl.st 7954 2012-03-26 15:34:31Z vranyj1 $'
+ ^ '$Header: /cvs/stx/stx/libtool/GitSourceCodeManagementSettingsAppl.st,v 1.8 2012/07/23 11:26:05 cg Exp $'
!
version_CVS
- ^ '§Header: /cvs/stx/stx/libtool/GitSourceCodeManagementSettingsAppl.st,v 1.6 2012/03/12 11:11:48 cg Exp §'
+ ^ '§Header: /cvs/stx/stx/libtool/GitSourceCodeManagementSettingsAppl.st,v 1.8 2012/07/23 11:26:05 cg Exp §'
!
version_SVN
- ^ '$Id: GitSourceCodeManagementSettingsAppl.st 7954 2012-03-26 15:34:31Z vranyj1 $'
+ ^ '$Id: GitSourceCodeManagementSettingsAppl.st 8022 2012-07-25 09:51:30Z vranyj1 $'
! !