SourceCodeManagerUtilitiesForContainerBasedManagers.st
author Claus Gittinger <cg@exept.de>
Sun, 01 Mar 2015 14:29:17 +0100
changeset 3819 7bf4e32e3685
parent 3772 399ff1b46d41
child 3830 2e140590a5f3
permissions -rw-r--r--
class: SourceCodeManagerUtilitiesForContainerBasedManagers changed: #checkinBuildSupportFilesForPackage:withInfo: info messages only
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
3819
7bf4e32e3685 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3772
diff changeset
     1
"{ Encoding: utf8 }"
7bf4e32e3685 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3772
diff changeset
     2
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     3
"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     4
 COPYRIGHT (c) 2012 eXept Software AG
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     5
              All Rights Reserved
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     6
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     7
 This software is furnished under a license and may be used
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     8
 only in accordance with the terms of that license and with the
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
     9
 inclusion of the above copyright notice.   This software may not
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    10
 be provided or otherwise made available to, or used by, any
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    11
 other person.  No title to or ownership of the software is
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    12
 hereby transferred.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    13
"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    14
"{ Package: 'stx:libbasic3' }"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    15
3772
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
    16
"{ NameSpace: Smalltalk }"
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
    17
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    18
SourceCodeManagerUtilities subclass:#SourceCodeManagerUtilitiesForContainerBasedManagers
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    19
	instanceVariableNames:''
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    20
	classVariableNames:''
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    21
	poolDictionaries:''
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    22
	category:'System-SourceCodeManagement'
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    23
!
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    24
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    25
!SourceCodeManagerUtilitiesForContainerBasedManagers class methodsFor:'documentation'!
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    26
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    27
copyright
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    28
"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    29
 COPYRIGHT (c) 2012 eXept Software AG
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    30
              All Rights Reserved
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    31
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    32
 This software is furnished under a license and may be used
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    33
 only in accordance with the terms of that license and with the
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    34
 inclusion of the above copyright notice.   This software may not
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    35
 be provided or otherwise made available to, or used by, any
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    36
 other person.  No title to or ownership of the software is
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    37
 hereby transferred.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    38
"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    39
! !
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    40
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    41
!SourceCodeManagerUtilitiesForContainerBasedManagers methodsFor:'utilities-cvs'!
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    42
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
    43
checkinBuildSupportFilesForPackage:packageID withInfo:checkinInfo
3573
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    44
    |anyFailure module directory mgr defClass|
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    45
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    46
    mgr := self sourceCodeManagerFor: packageID. 
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    47
    defClass := ProjectDefinition definitionClassForPackage: packageID.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    48
3141
25cd1cd26450 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3133
diff changeset
    49
    "/ already done elsewhere now
25cd1cd26450 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3133
diff changeset
    50
    "/ defClass validateDescription.
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    51
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    52
    anyFailure := false.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    53
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    54
    module := packageID asPackageId module.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    55
    directory := packageID asPackageId directory.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    56
3819
7bf4e32e3685 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3772
diff changeset
    57
    self activityNotification:(resources string:'Checking in build-support files...').
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    58
    (mgr checkForExistingModule:module directory:directory) ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    59
        mgr createModule:module directory:directory
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    60
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    61
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    62
    defClass forEachFileNameAndGeneratedContentsDo:[:fileName :fileContents |
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    63
        |realFileName realDirectory|
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    64
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    65
        "/ care for subdirectories
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    66
        (fileName includes:$/) ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    67
            realDirectory := (directory asFilename construct:(fileName asFilename directoryName)) name.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    68
            realFileName := fileName asFilename baseName.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    69
        ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    70
            realDirectory := directory.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    71
            realFileName := fileName.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    72
        ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    73
        realDirectory := realDirectory replaceAll:$\ with:$/.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    74
3819
7bf4e32e3685 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3772
diff changeset
    75
        self activityNotification:(resources string:'Checking in %1...' with:realFileName).
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    76
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    77
        UserInformation
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    78
            handle:[:ex | Transcript showCR:ex description ]
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    79
            do:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    80
                (mgr isContainerBased
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
    81
                 and:[(mgr checkForExistingContainer:realFileName inModule:module directory:realDirectory) not]
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
    82
                ) ifTrue:[
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    83
                    realDirectory ~= directory ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    84
                        (mgr checkForExistingModule:module directory:realDirectory) ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    85
                            mgr createModule:module directory:realDirectory
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    86
                        ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
    87
                    ].
3573
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    88
                    [:exit |
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    89
                        |answer|
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    90
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    91
                        (mgr
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    92
                            createContainerForText:fileContents
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    93
                            inModule:module
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    94
                            package:realDirectory
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    95
                            container:realFileName) ifTrue:[ exit value:nil ].
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    96
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    97
                        answer := Dialog 
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    98
                            confirmWithCancel:(resources
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
    99
                                    stringWithCRs:'Cannot create new container: ''%3'' (in %1:%2).\\Retry?'
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
   100
                                    with:module
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
   101
                                    with:realDirectory
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
   102
                                    with:realFileName).
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
   103
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
   104
                         answer == nil ifTrue:[
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
   105
                            AbortOperationRequest raise
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
   106
                        ].
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
   107
                        answer == false ifTrue:[ exit value:nil ].
af8f051e0a8b class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3537
diff changeset
   108
                    ] loopWithExit.
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   109
                ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   110
                    (mgr
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   111
                        checkin:realFileName
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   112
                        text:fileContents
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   113
                        directory:realDirectory
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   114
                        module:module
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   115
                        logMessage:checkinInfo logMessage
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   116
                        force:false
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   117
                    ) ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   118
                        checkinInfo isStable ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   119
                            self tagPath:(module, '/', realDirectory, '/', realFileName) as:#stable usingManager:mgr.
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   120
                        ].
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   121
                        checkinInfo tagIt ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   122
                            self tagPath:(module, '/', realDirectory, '/', realFileName) as:checkinInfo tag usingManager:mgr.
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   123
                        ].
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   124
                    ] ifFalse:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   125
                        Transcript showCR:'checkin of ' , realFileName , ' failed'.
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   126
                        anyFailure := true.
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   127
                    ].
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   128
                ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   129
            ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   130
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   131
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   132
    defClass instAndClassMethodsDo:[:m | m package:defClass package].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   133
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   134
    self
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   135
        checkinClasses:(Array with:defClass)
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   136
        withInfo:checkinInfo
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   137
        withCheck:false.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   138
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   139
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   140
    self activityNotification:nil.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   141
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   142
    anyFailure ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   143
        self warn:'Checkin failed - see Transcript.'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   144
        self activityNotification:'Checkin of build-support files failed - see Transcript.'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   145
    ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   146
        self activityNotification:'Build-support files checked into the repository.'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   147
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   148
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   149
    "Created: / 09-08-2006 / 18:59:42 / fm"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   150
    "Modified: / 12-10-2011 / 11:36:34 / Jan Vrany <jan.vrany@fit.cvut.cz>"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   151
    "Modified: / 25-07-2012 / 14:27:30 / cg"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   152
    "Modified (format): / 25-07-2012 / 22:25:48 / cg"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   153
!
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   154
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   155
checkinExtensionMethods:aCollectionOfMethods forPackage:aPackageID withInfo:aLogInfoOrStringOrNil
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   156
    "checkin a projects extensions into the source repository.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   157
     If the argument, aLogInfoOrStringOrNil isNil, ask interactively for log-message."
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   158
3133
14d574b2f82e extensions with utf8
Claus Gittinger <cg@exept.de>
parents: 2946
diff changeset
   159
    |logMessage checkinInfo mgr pri module directory containerFileName extensionsSource|
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   160
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   161
    "/ the following is wrong - must ask the projectDefinition !!
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   162
    aPackageID asPackageId projectDefinitionClass notNil ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   163
        mgr := self sourceCodeManagerFor:aPackageID asPackageId projectDefinitionClass.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   164
    ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   165
        mgr := self sourceCodeManagerFor:aCollectionOfMethods first mclass.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   166
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   167
    mgr isNil ifTrue:[ ^ false ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   168
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   169
    module := aPackageID asPackageId module.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   170
    directory := aPackageID asPackageId directory.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   171
    containerFileName := self nameOfExtensionsContainer.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   172
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   173
    aLogInfoOrStringOrNil isNil ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   174
        checkinInfo := self getCheckinInfoFor:containerFileName allBold initialAnswer:nil.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   175
        checkinInfo isNil ifTrue:[^ false].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   176
        logMessage := checkinInfo logMessage.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   177
    ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   178
        aLogInfoOrStringOrNil isString ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   179
            logMessage := aLogInfoOrStringOrNil
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   180
        ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   181
            checkinInfo := aLogInfoOrStringOrNil.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   182
            logMessage := checkinInfo logMessage.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   183
        ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   184
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   185
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   186
    (mgr checkForExistingContainer:containerFileName inModule:module directory:directory) ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   187
        (self checkForExistingModule:module usingManager:mgr allowCreate:true) ifFalse:[^ false].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   188
        LastModule := module.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   189
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   190
        (self checkForExistingModule:module directory:directory usingManager:mgr allowCreate:true) ifFalse:[^ false].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   191
        LastPackage := directory.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   192
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   193
        (self checkForExistingModule:module directory:directory container:containerFileName usingManager:mgr allowCreate:true) ifFalse:[^ false].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   194
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   195
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   196
    self activityNotification:(resources string:'Checking in %1' with:containerFileName).
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   197
    pri := Processor activePriority.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   198
    Processor activeProcess 
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   199
        withPriority:pri-1 to:pri
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   200
        do:[
3133
14d574b2f82e extensions with utf8
Claus Gittinger <cg@exept.de>
parents: 2946
diff changeset
   201
            extensionsSource := self sourceCodeForExtensions:aCollectionOfMethods package:aPackageID forManager:mgr.
14d574b2f82e extensions with utf8
Claus Gittinger <cg@exept.de>
parents: 2946
diff changeset
   202
            "Care for non-ASCII/non-ISO-8859 characters in extension methods"
14d574b2f82e extensions with utf8
Claus Gittinger <cg@exept.de>
parents: 2946
diff changeset
   203
            extensionsSource isWideString ifTrue:[
14d574b2f82e extensions with utf8
Claus Gittinger <cg@exept.de>
parents: 2946
diff changeset
   204
                extensionsSource := '"{ Encoding: utf8 }"' , Character cr asString , Character cr asString , extensionsSource.                
14d574b2f82e extensions with utf8
Claus Gittinger <cg@exept.de>
parents: 2946
diff changeset
   205
                extensionsSource := extensionsSource utf8Encoded.
14d574b2f82e extensions with utf8
Claus Gittinger <cg@exept.de>
parents: 2946
diff changeset
   206
            ].
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   207
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   208
            UserInformation handle:[:ex |
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   209
                Transcript showCR:ex description.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   210
                ex proceed.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   211
            ] do:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   212
                Transcript showCR:('checking in ',containerFileName,' ...').
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   213
                (mgr 
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   214
                    checkin:containerFileName
3133
14d574b2f82e extensions with utf8
Claus Gittinger <cg@exept.de>
parents: 2946
diff changeset
   215
                    text:extensionsSource
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   216
                    directory:directory 
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   217
                    module:module
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   218
                    logMessage:logMessage
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   219
                    force:false) 
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   220
                ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   221
                    Transcript showCR:'Checkin of ''' , containerFileName , ''' failed'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   222
                    self warn:'Checkin of ''' , containerFileName allBold , ''' failed'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   223
                    ^ false.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   224
                ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   225
                checkinInfo notNil ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   226
                    |path|
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   227
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   228
                    path := (module, '/', directory, '/', containerFileName).
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   229
                    checkinInfo isStable ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   230
                        "set stable tag for class that has been checked in"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   231
                        self tagPath:path as:#stable usingManager:mgr.    
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   232
                    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   233
                    checkinInfo tagIt ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   234
                        "set an additional tag for class that has been checked in"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   235
                        self tagPath:path as:(checkinInfo tag) usingManager:mgr.    
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   236
                    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   237
                ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   238
                mgr postCheckInExtensionsForPackage:aPackageID    
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   239
            ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   240
        ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   241
    ^ true
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   242
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   243
    "Modified: / 25-07-2012 / 18:38:40 / cg"
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   244
!
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   245
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   246
checkinPackage:packageToCheckIn classes:doClasses extensions:doExtensions buildSupport:doBuild askForMethodsInOtherPackages:askForMethodsInOtherPackages
3196
d91dbd26f40c class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3172
diff changeset
   247
    |mgr classesToCheckIn methodsToCheckIn methodsInPrjDef
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   248
     methodsInOtherPackages looseMethods otherPackages
3507
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   249
     msg classesInChangeSet newClasses checkinInfo originalCheckinInfo classesToTag
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   250
     answer|
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   251
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   252
    mgr := self sourceCodeManagerFor: packageToCheckIn.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   253
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   254
    classesToCheckIn := IdentitySet new.
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   255
    classesInChangeSet := IdentitySet new.
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   256
    methodsToCheckIn := IdentitySet new.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   257
    methodsInOtherPackages := IdentitySet new.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   258
    looseMethods := IdentitySet new.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   259
3164
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   260
    "/ collect classes and individual methods...
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   261
    (doClasses or:[doExtensions]) ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   262
        Smalltalk allClassesDo:[:aClass | 
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   263
            |owner classPackage|
3141
25cd1cd26450 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3133
diff changeset
   264
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   265
            (owner := aClass owningClass) notNil ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   266
                classPackage := aClass topOwningClass package
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   267
            ] ifFalse:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   268
                classPackage := aClass package
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   269
            ].
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   270
            (classPackage = packageToCheckIn) ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   271
                classesToCheckIn add:aClass.
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   272
            ].
3164
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   273
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   274
            doExtensions ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   275
                aClass isMeta ifFalse:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   276
                    "/ ... whose class is not in the checkIn-set
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   277
                    (classesToCheckIn includes:aClass) ifFalse:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   278
                        aClass instAndClassSelectorsAndMethodsDo:[:sel :mthd |
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   279
                            "/ methods in this project ...
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   280
                            (mthd package = packageToCheckIn) ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   281
                                methodsToCheckIn add:mthd
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   282
                            ]
3164
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   283
                        ]
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   284
                    ].
3164
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   285
                ].
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   286
            ].
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   287
        ].
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   288
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   289
        "/ cg: O(n^2) algorithm
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   290
        "/  classesInChangeSet := classesToCheckIn select:[:cls | cls hasUnsavedChanges].
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   291
        "/ replaced by: O(n) algorithm
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   292
        classesInChangeSet := ChangeSet current selectClassesForWhichIncludesChangeForClassOrMetaclassOrPrivateClassFrom:classesToCheckIn. 
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   293
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   294
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   295
    doExtensions ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   296
        methodsToCheckIn notEmpty ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   297
            doClasses ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   298
                msg := '%1 classes (%4 changed) '.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   299
            ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   300
                msg := ''.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   301
            ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   302
            doExtensions ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   303
                doClasses ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   304
                    msg := msg , 'and '.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   305
                ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   306
                msg := msg , '%2 extensions '.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   307
            ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   308
            msg := msg , 'of project "%3"'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   309
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   310
            checkinInfo := self
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   311
                        getCheckinInfoFor:(msg
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   312
                                                    bindWith:classesToCheckIn size
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   313
                                                    with:methodsToCheckIn size
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   314
                                                    with:packageToCheckIn allBold
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   315
                                                    with:classesInChangeSet size)
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   316
                        initialAnswer:nil
3141
25cd1cd26450 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3133
diff changeset
   317
                        withQuickOption:(classesToCheckIn size > 0)
25cd1cd26450 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3133
diff changeset
   318
                        withValidateConsistencyOption:true.
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   319
            checkinInfo isNil ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   320
                ^ self.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   321
            ].
3145
e59d8d1ab71a class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3141
diff changeset
   322
e59d8d1ab71a class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3141
diff changeset
   323
            checkinInfo validateConsistency ifTrue:[
3772
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   324
                |setInProjectDef setForCheckin onlyInPrjDef onlyForCheckin moreInfo|
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   325
3145
e59d8d1ab71a class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3141
diff changeset
   326
                self validateConsistencyOfPackage:packageToCheckIn doClasses:doClasses doExtensions:doExtensions.
3196
d91dbd26f40c class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3172
diff changeset
   327
                "/ could have changed/recompiled methods...
d91dbd26f40c class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3172
diff changeset
   328
                "/ mhmh - should we checkin what is specified in the prj-def,
d91dbd26f40c class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3172
diff changeset
   329
                "/ or what is actually present in the image (in case user did not repair)???
d91dbd26f40c class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3172
diff changeset
   330
                
d91dbd26f40c class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3172
diff changeset
   331
                methodsInPrjDef  := packageToCheckIn asPackageId projectDefinitionClass extensionMethods.
d91dbd26f40c class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3172
diff changeset
   332
                methodsInPrjDef := methodsInPrjDef reject:[:m | m isNil].
3772
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   333
                (setInProjectDef := methodsInPrjDef asSet) ~= (setForCheckin := methodsToCheckIn asSet) ifTrue:[
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   334
                    onlyInPrjDef := setInProjectDef copy removeAllFoundIn:setForCheckin.
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   335
                    onlyForCheckin := setForCheckin copy removeAllFoundIn:setInProjectDef.
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   336
                    moreInfo := ''.
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   337
                    onlyInPrjDef notEmpty ifTrue:[
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   338
                        moreInfo := moreInfo , '\Only in Project: '.
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   339
                        moreInfo := moreInfo , ((onlyInPrjDef asOrderedCollection copyTo:(5 min:onlyInPrjDef size))
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   340
                                                collect:#whoString) asStringWith:', '.
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   341
                        onlyInPrjDef size > 5 ifTrue:[ moreInfo := moreInfo , '...' ].
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   342
                    ].
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   343
                    onlyForCheckin notEmpty ifTrue:[
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   344
                        moreInfo := moreInfo , '\Only in Image: '.
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   345
                        moreInfo := moreInfo , ((onlyForCheckin asOrderedCollection copyTo:(5 min:onlyForCheckin size))
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   346
                                                collect:#whoString) asStringWith:', '.
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   347
                        onlyForCheckin size > 5 ifTrue:[ moreInfo := moreInfo , '...' ].
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   348
                    ].
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   349
                    moreInfo notEmpty ifTrue:[ (moreInfo := moreInfo , '\') withCRs ].
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   350
self halt.
3507
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   351
                    answer:= Dialog 
3772
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   352
                        confirmWithCancel:('The set of methods in image is different from what is specified in the project definition.\%1\You should probably make sure that all extension methods are all associated to the correct package.\\Check in image methods (%2) or definition methods (%3)?'
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   353
                                        bindWith: moreInfo
399ff1b46d41 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3651
diff changeset
   354
                                        with: methodsToCheckIn size
3651
d58c178282c0 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3603
diff changeset
   355
                                        with: methodsInPrjDef size) withCRs
3507
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   356
                        labels:#('Image Methods' 'Definition Methods' 'Cancel') 
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   357
                        values:#(true false nil) 
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   358
                        default:nil.
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   359
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   360
"/                    answer := Dialog 
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   361
"/                        confirm:('Set of methods in image is different from what is specified in the project definition.\Check in image methods (%1) or definition methods (%2)?'
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   362
"/                                        bindWith: methodsToCheckIn size
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   363
"/                                        with: methodsInPrjDef size)
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   364
"/                        yesLabel:'Image Methods' 
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   365
"/                        noLabel:'Definition Methods'.
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   366
                    answer isNil ifTrue:[AbortOperationRequest raise].
ef4dad1a2b32 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3400
diff changeset
   367
                    answer ifFalse:[
3196
d91dbd26f40c class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3172
diff changeset
   368
                        methodsToCheckIn := methodsInPrjDef.
d91dbd26f40c class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3172
diff changeset
   369
                    ].
d91dbd26f40c class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3172
diff changeset
   370
                ].
3145
e59d8d1ab71a class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3141
diff changeset
   371
            ].
e59d8d1ab71a class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3141
diff changeset
   372
3250
fe3f6d8ead83 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3196
diff changeset
   373
            "/ also need the extensionVersion methods in the projectDefinition class,
fe3f6d8ead83 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3196
diff changeset
   374
            "/ which are kept in the extensions container. (the reason is that we need the proper
fe3f6d8ead83 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3196
diff changeset
   375
            "/ CVS id for the extensions container, not for the projDefinition container.
fe3f6d8ead83 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3196
diff changeset
   376
            packageToCheckIn asPackageId projectDefinitionClass theMetaclass selectorsAndMethodsDo:[:sel :mthd |
fe3f6d8ead83 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3196
diff changeset
   377
                (AbstractSourceCodeManager isExtensionsVersionMethodSelector:sel) ifTrue:[
fe3f6d8ead83 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3196
diff changeset
   378
                    methodsToCheckIn add:mthd
fe3f6d8ead83 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3196
diff changeset
   379
                ].
fe3f6d8ead83 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3196
diff changeset
   380
            ].
fe3f6d8ead83 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3196
diff changeset
   381
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   382
            (self
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   383
                checkinExtensionMethods:methodsToCheckIn
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   384
                forPackage:packageToCheckIn
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   385
                withInfo:checkinInfo)
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   386
            ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   387
                Dialog warn:(resources string:'Could not check in extensions for project %1' with:packageToCheckIn).
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   388
                ^ self.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   389
            ]
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   390
        ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   391
            "/ there may have been extension-methods previously - if so, remove them
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   392
            (mgr
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   393
                checkForExistingContainer:'extensions.st' inPackage:packageToCheckIn)
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   394
            ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   395
"/ self halt.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   396
                (self
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   397
                    checkinExtensionMethods:#()
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   398
                    forPackage:packageToCheckIn
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   399
                    withInfo:'No extensions any more')
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   400
                ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   401
                    Dialog warn:(resources string:'Could not check in extensions for project %1' with:packageToCheckIn).
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   402
                    ^ self.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   403
                ]
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   404
            ]
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   405
        ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   406
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   407
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   408
    checkinInfo isNil ifTrue:[
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   409
        |infoString|
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   410
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   411
        doExtensions ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   412
            infoString := '%1 classes (%4 changed) and %2 extensions for project "%3"'.
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   413
        ] ifFalse:[doClasses ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   414
            infoString := '%1 classes (%4 changed) for project "%3"'.
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   415
        ] ifFalse:[doBuild ifTrue:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   416
            infoString := 'Build support files for project "%3"'.
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   417
        ] ifFalse:[
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   418
            infoString := 'I don''t know what I am doing'.
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   419
        ]]].
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   420
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   421
        infoString := infoString
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   422
                        bindWith:classesToCheckIn size
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   423
                        with:methodsToCheckIn size
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   424
                        with:packageToCheckIn allBold
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   425
                        with:classesInChangeSet size.
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   426
    
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   427
        checkinInfo := self
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   428
                    getCheckinInfoFor:infoString
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   429
                    initialAnswer:nil
3141
25cd1cd26450 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3133
diff changeset
   430
                    withQuickOption:(classesToCheckIn size > 0)
25cd1cd26450 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3133
diff changeset
   431
                    withValidateConsistencyOption:true.
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   432
        checkinInfo isNil ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   433
            ^ self.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   434
        ].
3145
e59d8d1ab71a class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3141
diff changeset
   435
        checkinInfo validateConsistency ifTrue:[
e59d8d1ab71a class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3141
diff changeset
   436
            self validateConsistencyOfPackage:packageToCheckIn doClasses:doClasses doExtensions:doExtensions.
e59d8d1ab71a class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3141
diff changeset
   437
        ].
3141
25cd1cd26450 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3133
diff changeset
   438
    ].
25cd1cd26450 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3133
diff changeset
   439
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   440
    checkinInfo quickCheckIn ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   441
        (checkinInfo isStable or:[checkinInfo tagIt]) ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   442
            classesToTag := classesToCheckIn.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   443
            originalCheckinInfo := checkinInfo.
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   444
            checkinInfo := checkinInfo deepCopy.
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   445
            checkinInfo isStable:false.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   446
            checkinInfo tag:nil.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   447
        ].
3164
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   448
        "/ not only the one's in the changeSet;
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   449
        "/ also those which have not been checked in before.
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   450
        newClasses := classesToCheckIn select:[:class | (class revisionOfManager:mgr) isNil ].
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   451
        classesToCheckIn := Set new 
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   452
                                addAll:classesInChangeSet; 
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   453
                                addAll:newClasses; 
e54571b3021f class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3145
diff changeset
   454
                                yourself.
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   455
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   456
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   457
    "/ check if any of the classes contains methods for other packages ...
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   458
    classesToCheckIn do:[:eachClass |
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   459
        eachClass instAndClassMethodsDo:[:eachMethod |
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   460
            |mPgk|
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   461
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   462
            mPgk := eachMethod package.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   463
            (mPgk = packageToCheckIn) ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   464
                mPgk == PackageId noProjectID ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   465
                    looseMethods add:eachMethod
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   466
                ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   467
                    methodsInOtherPackages add:eachMethod
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   468
                ]
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   469
            ]
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   470
        ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   471
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   472
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   473
    askForMethodsInOtherPackages ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   474
        methodsInOtherPackages notEmpty ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   475
            otherPackages := Set new.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   476
            methodsInOtherPackages do:[:eachMethod | otherPackages add:eachMethod package].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   477
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   478
            methodsInOtherPackages size == 1 ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   479
                msg := 'The ''%4'' method in ''%5'' is contained in the ''%2'' package.'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   480
                msg := msg , '\\This method will remain in its package.'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   481
            ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   482
                otherPackages size == 1 ifTrue:[
3651
d58c178282c0 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3603
diff changeset
   483
                    msg := 'The %1 methods from the %2 package will remain in their package.'
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   484
                ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   485
                    msg := 'The %1 methods from %3 other packages will remain in their packages.'
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   486
                ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   487
                msg := msg , '\\Hint: if these are meant to belong to this package,'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   488
                msg := msg , '\move them first, then repeat the checkin operation.'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   489
            ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   490
            msg := msg withCRs.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   491
            msg := msg bindWith:methodsInOtherPackages size
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   492
                           with:otherPackages first allBold
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   493
                           with:otherPackages size
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   494
                           with:methodsInOtherPackages first selector allBold
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   495
                           with:methodsInOtherPackages first mclass name allBold.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   496
            (Dialog confirm:msg noLabel:(resources string:'Cancel')) ifFalse:[^ self].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   497
        ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   498
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   499
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   500
    doClasses ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   501
        classesToCheckIn notEmpty ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   502
            looseMethods notEmpty ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   503
                looseMethods size == 1 ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   504
                    msg := 'The ''%2'' method in ''%3'' is unassigned (loose).'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   505
                    msg := msg , '\\If you proceed, this method will be moved to the ''%4'' package'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   506
                    msg := msg , '\\Hint: if this is meant to be an extension of another package,'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   507
                    msg := msg , '\cancel and move it to the appropriate package first.'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   508
                ] ifFalse:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   509
                    msg := 'There are %1 unassigned (loose) methods in classes from this project.'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   510
                    msg := msg , '\\If you proceed, those will be moved to the ''%4'' package ?'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   511
                    msg := msg , '\\Hint: if these are meant to be extensions of another package,'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   512
                    msg := msg , '\cancel and move them to the appropriate package first.'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   513
                ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   514
                doClasses ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   515
                    msg := msg , '\\If you answer with "No" here, you will be asked for each class individually.'.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   516
                ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   517
                msg := msg withCRs.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   518
                msg := msg bindWith:looseMethods size
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   519
                               with:(looseMethods isEmpty ifTrue:[''] ifFalse:[looseMethods first selector allBold])
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   520
                               with:(looseMethods isEmpty ifTrue:[''] ifFalse:[looseMethods first mclass name allBold])
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   521
                               with:packageToCheckIn allBold.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   522
                (Dialog confirm:msg noLabel:(resources string:'Cancel')) ifFalse:[^ self].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   523
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   524
                looseMethods do:[:mthd |
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   525
                    mthd package:packageToCheckIn
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   526
                ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   527
            ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   528
            self checkinClasses:classesToCheckIn withInfo:checkinInfo.
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   529
        ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   530
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   531
        originalCheckinInfo notNil ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   532
            originalCheckinInfo isStable ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   533
                classesToTag do:[:eachClass |
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   534
                    self tagClass:eachClass as:#stable
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   535
                ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   536
            ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   537
            originalCheckinInfo tagIt ifTrue:[
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   538
                classesToTag do:[:eachClass |
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   539
                    self tagClass:eachClass as:(originalCheckinInfo tag)
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   540
                ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   541
            ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   542
        ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   543
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   544
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   545
    doBuild ifTrue:[
3367
dc9d785a4ca7 Open a checkin info dialog for build support files checkin
Stefan Vogel <sv@exept.de>
parents: 3362
diff changeset
   546
        self checkinBuildSupportFilesForPackage:packageToCheckIn withInfo:(originalCheckinInfo ? checkinInfo).
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   547
    ].
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   548
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   549
    "Created: / 13-10-2011 / 11:15:22 / Jan Vrany <jan.vrany@fit.cvut.cz>"
2906
b4c09eb4e63a method renamed for clarity
Claus Gittinger <cg@exept.de>
parents: 2848
diff changeset
   550
    "Modified: / 04-09-2012 / 14:05:36 / cg"
3537
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   551
!
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   552
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   553
comparePackages:packages askForRevision:askForRevision
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   554
    "Compares code of given packages (loaded in the image) against a specific revision
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   555
     and opens a diff browser on differences.
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   556
     
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   557
     If `askForRevision` is true, then user is asked to specify to which revision to
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   558
     update. If `askForRevision` is false, then packages are updated to a 'newest'
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   559
     revision.
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   560
     
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   561
     NOTE: Definition of `newest` revision may vary. For SCMs which allows for multiple
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   562
     heads, it is not clear which one it is. In that case, even if `askForRevision` is
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   563
     false, this method may result in user interation, asking user to select which of the
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   564
     newest she wants."
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   565
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   566
    |dateFormat string dateOrNil symbolicName|
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   567
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   568
    dateFormat := UserPreferences current dateInputFormat.
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   569
    string := Dialog
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   570
                request:(resources
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   571
                        string:'Compare with version from date (%1) or tag (any other format):'
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   572
                        with:dateFormat)
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   573
                initialAnswer:(Date today printStringFormat:dateFormat).
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   574
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   575
    string isEmptyOrNil ifTrue:[^ self].
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   576
    dateOrNil := Date readFrom:string printFormat:dateFormat onError:nil.
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   577
    dateOrNil isNil ifTrue:[
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   578
        symbolicName := string
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   579
    ].
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   580
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   581
    packages value do:[:eachProject |
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   582
        dateOrNil notNil ifTrue:[
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   583
            self compareProject:eachProject withRepositoryVersionFrom:dateOrNil
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   584
        ] ifFalse:[
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   585
            self compareProject:eachProject withRepositoryVersionTaggedAs:symbolicName
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   586
        ]
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   587
    ].
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   588
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   589
ee6b24d5f0f8 Compare packages functionality moved from browser to SourceCoeManagerUtilities
Jan Vrany <jan.vrany@fit.cvut.cz>
parents: 3507
diff changeset
   590
    "Created: / 04-04-2014 / 15:29:33 / Jan Vrany <jan.vrany@fit.cvut.cz>"
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   591
! !
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   592
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   593
!SourceCodeManagerUtilitiesForContainerBasedManagers class methodsFor:'documentation'!
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   594
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   595
version
3819
7bf4e32e3685 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3772
diff changeset
   596
    ^ '$Header: /cvs/stx/stx/libbasic3/SourceCodeManagerUtilitiesForContainerBasedManagers.st,v 1.25 2015-03-01 13:29:17 cg Exp $'
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   597
!
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   598
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   599
version_CVS
3819
7bf4e32e3685 class: SourceCodeManagerUtilitiesForContainerBasedManagers
Claus Gittinger <cg@exept.de>
parents: 3772
diff changeset
   600
    ^ '$Header: /cvs/stx/stx/libbasic3/SourceCodeManagerUtilitiesForContainerBasedManagers.st,v 1.25 2015-03-01 13:29:17 cg Exp $'
2848
f182780810d6 initial checkin
Claus Gittinger <cg@exept.de>
parents:
diff changeset
   601
! !
3133
14d574b2f82e extensions with utf8
Claus Gittinger <cg@exept.de>
parents: 2946
diff changeset
   602