Skip to content

Commit 8d11206

Browse files
committed
squeak: re-add BlockContext extensions via new Squeak6Compatibility package
See #552 (comment)
1 parent 1698d8d commit 8d11206

18 files changed

+85
-4
lines changed

repository/BaselineOfMetacello.package/BaselineOfMetacello.class/instance/baseline..st

+9-1
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,7 @@ baseline: spec
275275
package: 'Metacello-TestsMC' with: [ spec requires: #('Gofer Tests') ];
276276
package: 'Metacello-Platform'
277277
with: [
278-
spec file: 'Metacello-Platform.squeak'; requires: #('Ston') ];
278+
spec file: 'Metacello-Platform.squeak'; requires: #('Ston' 'squeak-compatibility') ];
279279
yourself ].
280280
spec
281281
for:
@@ -294,6 +294,14 @@ baseline: spec
294294
package: 'Metacello-Platform'
295295
with: [ spec requires: #('WebClient' 'SqueakSSL-Core') ];
296296
yourself ].
297+
spec group: 'squeak-compatibility' with: #().
298+
spec
299+
for:
300+
#(#'squeak4.x' #'squeak5.x')
301+
do: [
302+
spec
303+
package: 'Metacello-Squeak6Compatibility';
304+
group: 'squeak-compatibility' with: #('Metacello-Squeak6Compatibility') ].
297305
spec
298306
for: #'gemstone'
299307
do: [

repository/BaselineOfMetacello.package/BaselineOfMetacello.class/methodProperties.json

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,10 @@
22
"class" : {
33
},
44
"instance" : {
5-
"baseline:" : "tobe 5/15/2020 20:02",
5+
"baseline:" : "ct 5/25/2022 13:05",
66
"filetree:" : "EstebanLorenzano 10/26/2017 11:42",
77
"gemstone10beta311PostLoadDoIt" : "dkh 07/24/2012 18:09",
8+
"gemstoneMetacelloGemStonePlatform3xInit" : "tobe 7/3/2020 09:57:21",
89
"gofer:" : "EstebanLorenzano 10/26/2017 11:42",
910
"reprimeRegistryIssue197" : "dkh 09/30/2014 17:40",
1011
"testResourcePostLoadDoIt" : "dkh 6/1/2012 09:18:17" } }
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
SystemOrganization addCategory: #'BaselineOfMetacello'!
1+
SystemOrganization addCategory: #BaselineOfMetacello!

repository/BaselineOfMetacello.package/monticello.meta/version

+1-1
Large diffs are not rendered by default.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"noMethodMetaData" : true,
3+
"separateMethodMetaAndSource" : false,
4+
"useCypressPropertiesFile" : true }
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
*Metacello-Squeak6Compatibility-*metacello-platform
2+
setAuthorInMetacelloConfig: aMetacelloConfig
3+
4+
aMetacelloConfig setAuthorWithBlock: self
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
*Metacello-Squeak6Compatibility-*metacello-platform
2+
setBlessingInMetacelloConfig: aMetacelloConfig
3+
4+
aMetacelloConfig setBlessingWithBlock: self
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
*Metacello-Squeak6Compatibility-*metacello-platform
2+
setDescriptionInMetacelloConfig: aMetacelloConfig
3+
4+
aMetacelloConfig setDescriptionWithBlock: self
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
*Metacello-Squeak6Compatibility-*metacello-platform
2+
setPackage: aString withInMetacelloConfig: aMetacelloConfig
3+
4+
aMetacelloConfig setPackage: aString withBlock: self
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
*Metacello-Squeak6Compatibility-*metacello-platform
2+
setProject: aString withInMetacelloConfig: aMetacelloConfig
3+
4+
aMetacelloConfig setProject: aString withBlock: self
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
*Metacello-Squeak6Compatibility-*metacello-platform
2+
setTimestampInMetacelloConfig: aMetacelloConfig
3+
4+
aMetacelloConfig setTimestampWithBlock: self
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
*Metacello-Squeak6Compatibility-*metacello-platform
2+
valueSupplyingMetacelloAnswers: aListOfPairs
3+
"evaluate the block using a list of questions / answers that might be called upon to
4+
automatically respond to Object>>confirm: or FillInTheBlank requests"
5+
6+
^ [self value]
7+
on: ProvideAnswerNotification
8+
do:
9+
[:notify | | answer caption |
10+
11+
caption := notify messageText withSeparatorsCompacted. "to remove new lines"
12+
answer := aListOfPairs
13+
detect:
14+
[:each | caption = each first or:
15+
[(caption includesSubstring: each first caseSensitive: false) or:
16+
[(each first match: caption) or:
17+
[(String includesSelector: #matchesRegex:) and:
18+
[ [ caption matchesRegex: each first ] on: Error do: [:ignored | false ]]]]]]
19+
ifNone: [nil].
20+
answer
21+
ifNotNil: [notify resume: answer second]
22+
ifNil:
23+
[ | outerAnswer |
24+
outerAnswer := ProvideAnswerNotification signal: notify messageText.
25+
outerAnswer
26+
ifNil: [notify resume]
27+
ifNotNil: [notify resume: outerAnswer]]]
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"class" : {
3+
},
4+
"instance" : {
5+
"setAuthorInMetacelloConfig:" : "dkh 6/12/2012 10:18:46.076",
6+
"setBlessingInMetacelloConfig:" : "dkh 6/12/2012 10:18:46.076",
7+
"setDescriptionInMetacelloConfig:" : "dkh 6/12/2012 10:18:46.076",
8+
"setPackage:withInMetacelloConfig:" : "dkh 6/12/2012 10:18:46.076",
9+
"setProject:withInMetacelloConfig:" : "dkh 6/12/2012 10:18:46.076",
10+
"setTimestampInMetacelloConfig:" : "dkh 6/12/2012 10:18:46.076",
11+
"valueSupplyingMetacelloAnswers:" : "dkh 6/12/2012 10:18:46.076" } }
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
{
2+
"name" : "BlockContext" }

repository/Metacello-Squeak6Compatibility.package/monticello.meta/initializers.st

Whitespace-only changes.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
(name 'Metacello-Squeak6Compatibility')

repository/Metacello-Squeak6Compatibility.package/monticello.meta/version

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
(name 'Metacello-Squeak6Compatibility-ct.1' message 'Add compatibility extensions for BlockContext from Metacello-PlatformAs of Squeak 6.0, BlockContext is no longer available in the base system, so we need to provide these extensions in a separate package to avoid a #dependencyWarning during installation. See https://github.com/Metacello/metacello/pull/552.' id '14a7bad5-7faa-f746-a541-31b9e656f2c1' date '25 May 2022' time '1:09:46.088867 pm' author 'ct' ancestors () stepChildren ())
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
{
2+
}

0 commit comments

Comments
 (0)