1365 self checkinClasses:aCollectionOfClasses withInfo:aLogInfoOrStringNil withCheck:doCheckClassesHolder usingManager:nil |
1365 self checkinClasses:aCollectionOfClasses withInfo:aLogInfoOrStringNil withCheck:doCheckClassesHolder usingManager:nil |
1366 |
1366 |
1367 "Modified: / 21-12-2011 / 18:24:47 / cg" |
1367 "Modified: / 21-12-2011 / 18:24:47 / cg" |
1368 ! |
1368 ! |
1369 |
1369 |
1370 checkinClasses:aCollectionOfClasses withInfo:aLogInfoOrStringNil withCheck:doCheckClassesHolder usingManager:aManagerOrNil |
1370 checkinClasses:aCollectionOfClasses withInfo:aLogInfoOrStringOrNil withCheck:doCheckClassesHolder usingManager:aManagerOrNil |
1371 "check a bunch of classes into the source repository. |
1371 "check a bunch of classes into the source repository. |
1372 If the argument, aLogInfoOrStringNil isNil, ask interactively for log-message." |
1372 If the argument, aLogInfoOrStringOrNil isNil, ask interactively for log-message." |
1373 |
1373 |
1374 |classes allClasses checkinInfoOrString yesOrNoToAll unchangedClasses| |
1374 |classes allClasses checkinInfoOrString yesOrNoToAll unchangedClasses| |
1375 |
1375 |
1376 "/ ignore private classes |
1376 "/ ignore private classes |
1377 classes := aCollectionOfClasses select:[:aClass | aClass owningClass isNil]. |
1377 classes := aCollectionOfClasses select:[:aClass | aClass owningClass isNil]. |
1384 self information:'Only unloaded classes given - nothing checked in.'. |
1384 self information:'Only unloaded classes given - nothing checked in.'. |
1385 ^ self |
1385 ^ self |
1386 ]. |
1386 ]. |
1387 |
1387 |
1388 classes size == 1 ifTrue:[ |
1388 classes size == 1 ifTrue:[ |
1389 ^ self checkinClass:classes first withInfo:aLogInfoOrStringNil withCheck:doCheckClassesHolder usingManager:aManagerOrNil. |
1389 ^ self checkinClass:classes first withInfo:aLogInfoOrStringOrNil withCheck:doCheckClassesHolder usingManager:aManagerOrNil. |
1390 ]. |
1390 ]. |
1391 |
1391 |
1392 "ask once, for all classes" |
1392 "ask once, for all classes" |
1393 aLogInfoOrStringNil isNil ifTrue:[ |
1393 aLogInfoOrStringOrNil isNil ifTrue:[ |
1394 checkinInfoOrString := self |
1394 checkinInfoOrString := self |
1395 getCheckinInfoFor:(resources string:'%1 classes to checkin' with:aCollectionOfClasses size) |
1395 getCheckinInfoFor:(resources string:'%1 classes to checkin' with:aCollectionOfClasses size) |
1396 initialAnswer:nil |
1396 initialAnswer:nil |
1397 withQuickOption:true. |
1397 withQuickOption:true. |
1398 checkinInfoOrString isNil ifTrue:[^ self]. |
1398 checkinInfoOrString isNil ifTrue:[^ self]. |
1399 ] ifFalse:[ |
1399 ] ifFalse:[ |
1400 checkinInfoOrString := aLogInfoOrStringNil. |
1400 checkinInfoOrString := aLogInfoOrStringOrNil. |
1401 ]. |
1401 ]. |
1402 |
1402 |
1403 allClasses := classes. |
1403 allClasses := classes. |
1404 checkinInfoOrString quickCheckIn ifTrue:[ |
1404 (checkinInfoOrString isString not and:[checkinInfoOrString quickCheckIn]) ifTrue:[ |
1405 "/ not only the one's in the changeSet; |
1405 "/ not only the one's in the changeSet; |
1406 "/ also those which have not been checked in before. |
1406 "/ also those which have not been checked in before. |
1407 classes := classes select:[:each | each hasUnsavedChanges or:[ (each revisionOfManager:aManagerOrNil) isNil ]]. |
1407 classes := classes select:[:each | each hasUnsavedChanges or:[ (each revisionOfManager:aManagerOrNil) isNil ]]. |
1408 classes isEmpty ifTrue:[ Dialog information:'no changes to checkin (quickCheckIn)' ] |
1408 classes isEmpty ifTrue:[ Dialog information:'no changes to checkin (quickCheckIn)' ] |
1409 ]. |
1409 ]. |