#FEATURE by cg
class: CVSSourceCodeManager class
changed: #checkinClass:fileName:directory:module:source:logMessage:force:asBranch:
verify that the editoed conflict source is ok
(parses as changeset)
--- a/CVSSourceCodeManager.st Fri Dec 07 04:34:45 2018 +0000
+++ b/CVSSourceCodeManager.st Mon Dec 17 13:15:35 2018 +0100
@@ -2629,7 +2629,15 @@
(repairedText contains:[:line | line notEmptyOrNil and:[(line emphasisAt:1) = emSep]]) ifTrue:[
self warn:'You have to look at ALL conflicts, and remove ALL green lines as a confirmation !!'.
didAccept := false.
- ]
+ ] ifFalse:[
+ "/ verify that the edit yields a correct (loadable) source
+ Error handle:[:ex |
+ self warn:(self classResources stringWithCRs:'The edited source code seems to be incorrect\(probably missing exclamation marks or missing quotes)\\I will not check this in, because it will fail to compile/load later.').
+ didAccept := false.
+ ] do:[
+ (ChangeSet fromString:repairedText asString string)
+ ].
+ ].
].
].
@@ -2884,6 +2892,7 @@
"Modified: / 31-03-2017 / 15:42:32 / stefan"
"Modified: / 18-05-2018 / 12:53:43 / Stefan Vogel"
"Modified: / 09-11-2018 / 18:09:37 / Maren"
+ "Modified: / 17-12-2018 / 13:15:21 / Claus Gittinger"
!
checkoutModule:aModule directory:aPackage andDo:aBlock