added: #revisionInfoFromString:inClass:
changed: #revisionInfoFromString:
repair umlaut-remover and felix's utf-8 string bugs
--- a/CVSSourceCodeManager.st Fri Jul 01 13:42:04 2011 +0200
+++ b/CVSSourceCodeManager.st Fri Jul 01 15:03:07 2011 +0200
@@ -4025,14 +4025,62 @@
"return a dictionary filled with revision info.
This extracts the relevant info from aString."
- ^ self revisionInfoFromRCSString:aString
+ ^ self revisionInfoFromString:aString inClass:nil
"
self revisionInfoFromString:(Array version_CVS)
self revisionInfoFromString:(stx_libbasic2 extensionsVersion_CVS)
"
- "Modified: 29.1.1997 / 19:00:35 / cg"
+ "Modified: / 01-07-2011 / 13:54:02 / cg"
+!
+
+revisionInfoFromString:aString inClass:aClass
+ "{ Pragma: +optSpace }"
+
+ "return a dictionary filled with revision info.
+ This extracts the relevant info from aString."
+
+ |fixedString|
+
+"/ temporary fix Felix' bad string translation:
+ (aString startsWith:'§') ifTrue:[
+ (aString endsWith:'§') ifTrue:[
+ fixedString := '$' , (aString copyFrom:3 to:(aString size - 2)) , '$'.
+
+ aClass isNil ifTrue:[
+ Dialog information:'Attention: the CVS version string is corrupted (§-bug). Please fix it manually'.
+ ] ifFalse:[
+ (Dialog confirm:'Attention: the CVS version string is corrupted (§-bug). Fix it?') ifTrue:[
+ self updateVersionMethodOf:aClass for:fixedString.
+ ].
+ ].
+ ].
+ ].
+
+"/ temporary fix Jan's bad Umlaut-removal (which results in Felix's bad § being removed):
+ (aString startsWith:'Header: ') ifTrue:[
+ (aString endsWith:'Exp ') ifTrue:[
+ fixedString := '$' , aString , '$'.
+
+ aClass isNil ifTrue:[
+ Dialog information:'Attention: the CVS version string is corrupted (Umlaut remover-bug). Please fix it manually'.
+ ] ifFalse:[
+ (Dialog confirm:'Attention: the CVS version string is corrupted (Umlaut remover-bug). Fix it?') ifTrue:[
+ self updateVersionMethodOf:aClass for:fixedString.
+ ].
+ ].
+ ].
+ ].
+
+ ^ self revisionInfoFromRCSString:(fixedString ? aString)
+
+ "
+ self revisionInfoFromString:(Array version_CVS)
+ self revisionInfoFromString:(stx_libbasic2 extensionsVersion_CVS)
+ "
+
+ "Created: / 01-07-2011 / 13:51:41 / cg"
!
revisionLogOf:clsOrNil fromRevision:firstRevOrNil toRevision:lastRevOrNil numberOfRevisions:numRevisionsOrNil fileName:classFileName directory:packageDir module:moduleDir
@@ -4846,12 +4894,8 @@
!CVSSourceCodeManager class methodsFor:'documentation'!
-version
- ^ '$Header: /cvs/stx/stx/libbasic3/CVSSourceCodeManager.st,v 1.388 2011-05-20 10:31:50 stefan Exp $'
-!
-
version_CVS
- ^ '$Header: /cvs/stx/stx/libbasic3/CVSSourceCodeManager.st,v 1.388 2011-05-20 10:31:50 stefan Exp $'
+ ^ '$Header: /cvs/stx/stx/libbasic3/CVSSourceCodeManager.st,v 1.389 2011-07-01 13:03:07 cg Exp $'
! !
CVSSourceCodeManager initialize!