Skip to content

Commit

Permalink
Merge pull request #1304 from SeasideSt/pharo10
Browse files Browse the repository at this point in the history
Pharo10
  • Loading branch information
jbrichau authored Apr 9, 2022
2 parents 77ab380 + f6e129a commit 9774169
Show file tree
Hide file tree
Showing 98 changed files with 650 additions and 34 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
strategy:
fail-fast: false
matrix:
smalltalk: [ Pharo64-9.0, Pharo64-8.0, Pharo64-7.0, Pharo-6.1, GemStone64-3.6.3, GemStone64-3.5.5, GemStone64-3.4.5, GemStone64-3.3.9, GemStone64-3.2.17, GemStone64-3.1.0.6 ]
smalltalk: [ Pharo64-10, Pharo64-9.0, Pharo64-8.0, Pharo64-7.0, Pharo-6.1, GemStone64-3.6.3, GemStone64-3.5.5, GemStone64-3.4.5, GemStone64-3.3.9, GemStone64-3.2.17, GemStone64-3.1.0.6 ]
experimental: [ false ]
include:
- smalltalk: Pharo64-alpha
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ baselinecommon: spec
with: [
spec
loads: #('Grease-Core');
repository: 'github://SeasideSt/Grease:v1.8.x/repository' ].
repository: 'github://SeasideSt/Grease:master/repository' ].
spec
project: 'Grease Core Tests' copyFrom: 'Grease' with: [
spec loads: #('Core Tests') ]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,10 @@ baselinepharo: spec
for: #(#'pharo8.x' #'pharo9.x')
do: [ spec
package: 'Seaside-Tools-Core' with: [ spec includes: #('Seaside-Pharo-Tools-Spec2') ];
package: 'Seaside-Pharo-Tools-Spec2' with: [ spec requires: #('Seaside-Tools-Core') ] ]
package: 'Seaside-Pharo-Tools-Spec2' with: [ spec requires: #('Seaside-Tools-Core') ] ].

spec
for: #(#'pharo10.x')
do: [ spec
package: 'Seaside-Tools-Core' with: [ spec includes: #('Seaside-Pharo100-Tools-Spec2') ];
package: 'Seaside-Pharo100-Tools-Spec2' with: [ spec requires: #('Seaside-Tools-Core') ] ]
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ baselinerest: spec
].

spec
for: #(#'pharo9.x')
for: #('pharo9.x' 'pharo10.x')
do:[
spec
package: 'Seaside-Pharo90-REST-Core';
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@
seasideVersion
"Answer the Seaside version"

^ (GRVersion major: 3 minor: 4 revision: 6)
^ (GRVersion major: 3 minor: 4 revision: 7)
yourself
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
private
tempNamedAndValuesInSqueak: aContext do: aTwoArgumentBlock

aContext tempNames doWithIndex: [ :each :index |
aTwoArgumentBlock value: each value: (aContext namedTempAt: index) ]
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
private
tempNamesAndValuesIn: aContext do: aTwoArgumentBlock
(((SystemVersion current asString includesSubstring: 'Pharo')
((SystemVersion current asString includesSubstring: 'Pharo')
and: [ SystemVersion current major >= 8 ])
or: [ (SystemVersion current asString includesSubstring: 'Squeak')
and: [ SystemVersion current majorVersionNumber >= 5 ] ])
ifTrue: [ aContext tempNames
doWithIndex:
[ :each :index | aTwoArgumentBlock value: each value: (aContext namedTempAt: index) ] ]
ifTrue: [ ^ self tempNamesAndValuesInPharo8Plus: aContext do: aTwoArgumentBlock ].

((SystemVersion current asString includesSubstring: 'Squeak')
and: [ SystemVersion current majorVersionNumber >= 5 ])
ifTrue: [ ^ self tempNamedAndValuesInSqueak: aContext do: aTwoArgumentBlock ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
private
tempNamesAndValuesInPharo8Plus: aContext do: aTwoArgumentBlock

aContext tempNames do: [ :each |
aTwoArgumentBlock value: each value: (aContext tempNamed: each) ]
5 changes: 5 additions & 0 deletions repository/Seaside-Pharo100-Tools-Spec2.package/.filetree
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"separateMethodMetaAndSource" : false,
"noMethodMetaData" : true,
"useCypressPropertiesFile" : true
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
*Seaside-Pharo100-Tools-Spec2
seasidePharoToolsSpec2
^ self new
name: 'Seaside-Pharo100-Tools-Spec2';
description: 'Spec based server adapter browser for Pharo';
addDependency: 'Seaside-Tools-Core';
url: #seasideUrl;
yourself
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{
"name" : "GRPackage"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Description
--------------------

I am an action to register a new adaptor in Seaside.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
accessing
adaptorClasses
^ (WAServerAdaptor allSubclasses reject: #isAbstract) sorted: #name ascending
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
converting
asSpecCommand
^ super asSpecCommand
iconName: #add;
yourself
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
hooks
execute
| allAdaptors |
allAdaptors := self adaptorClasses.
(UIManager default
chooseFrom: (allAdaptors collect: #name)
values: allAdaptors
lines: #()
title: 'Add Seaside Adaptor' translated)
ifNotNil: [ :class |
(UIManager default request: 'Enter a port number' initialAnswer: class basicNew defaultPort greaseString)
ifNotNil: [ :port |
(port isEmpty or: [ port isAllDigits not ])
ifFalse: [ class port: port greaseInteger.
context updateAdaptorsTable ] ] ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
initialization
initialize
super initialize.
self
name: 'Add adaptor';
description: 'Allows one to create a new adaptor.'
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "CyrilFerlicot 8/26/2019 12:06",
"super" : "WAControlPanelCommand",
"category" : "Seaside-Pharo100-Tools-Spec2",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "WAAddAdaptorCommand",
"type" : "normal"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Description
--------------------

I am an action to clear the caches of seaside configurations.
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
converting
asSpecCommand
^ super asSpecCommand
iconName: #remove;
yourself
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
hooks
execute
WAAdmin clearConfigurationCaches
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
initialization
initialize
super initialize.
self
name: 'Clear configuration caches';
description: 'Cleat all the caches of the configuration.'
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "CyrilFerlicot 8/26/2019 12:07",
"super" : "WAControlPanelCommand",
"category" : "Seaside-Pharo100-Tools-Spec2",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "WAClearConfigurationCachesCommand",
"type" : "normal"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Description
--------------------

I am an action to clear seaside sessions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
converting
asSpecCommand
^ super asSpecCommand
iconName: #remove;
yourself
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
hooks
execute
WAAdmin clearSessions
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
initialization
initialize
super initialize.
self
name: 'Clear sessions';
description: 'Clear all the sessions.'
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "CyrilFerlicot 8/26/2019 12:07",
"super" : "WAControlPanelCommand",
"category" : "Seaside-Pharo100-Tools-Spec2",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "WAClearSessionsCommand",
"type" : "normal"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Description
--------------------

I am an abstract class to manage commands of the controle panel of Seaside.

My context is a WAPharoControlPanel.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
testing
isAbstract
^ self = WAControlPanelCommand
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
accessing
adaptor
^ self context selectedAdaptor
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
hooks
hasAdaptor
^ self adaptor isNotNil
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "CyrilFerlicot 8/26/2019 12:06",
"super" : "CmCommand",
"category" : "Seaside-Pharo100-Tools-Spec2",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "WAControlPanelCommand",
"type" : "normal"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Description
--------------------

I am an action to inspect the currently selected adaptor.
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
converting
asSpecCommand
^ super asSpecCommand
iconName: #smallInspectIt;
yourself
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
hooks
execute
self adaptor ifNotNil: #inspect
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
initialization
initialize
super initialize.
self
name: 'Inspect';
description: 'Inspect the currently selected adaptor.'
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "CyrilFerlicot 8/26/2019 12:07",
"super" : "WAControlPanelCommand",
"category" : "Seaside-Pharo100-Tools-Spec2",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "WAInspectAdaptorCommand",
"type" : "normal"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Description
--------------------

I am an action to open a web browser on the localhost defined by the adaptor depending on its port.
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
converting
asSpecCommand
^ super asSpecCommand
iconName: #window;
yourself
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
hooks
execute
self adaptor
ifNotNil: [ :adaptor |
adaptor isRunning ifFalse: [ ^ self ].
WebBrowser openOn: 'http://localhost:' , adaptor port asString ]
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
initialization
initialize
super initialize.
self
name: 'Open';
description: 'Opoen localhost on the port of the adaptor.'
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"commentStamp" : "CyrilFerlicot 8/26/2019 12:08",
"super" : "WAControlPanelCommand",
"category" : "Seaside-Pharo100-Tools-Spec2",
"classinstvars" : [ ],
"pools" : [ ],
"classvars" : [ ],
"instvars" : [ ],
"name" : "WAOpenBrowserCommand",
"type" : "normal"
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
Description
--------------------

I am a controle panel for seaside. I will present to the user the list of adaptors registered in Seaside and let the user do some actions such as:
- Adding a new adaptor
- Removing an adaptor
- Starting an adaptor
- Removing an adaptor
...

Examples
--------------------

self class open

Internal Representation and Key Implementation Points.
--------------------

Instance Variables
actionBar: <aToolbarPresenter> A toolbar containing actions to execute on the selected adaptor
adaptors: <aTablePresenter> A table providing informations about the registered adaptors
infos: <aTextPresenter> A text giving informations to the user about the selected adaptor
Loading

0 comments on commit 9774169

Please sign in to comment.