Skip to content

Commit

Permalink
Fixes #114 and formats code as VAST only
Browse files Browse the repository at this point in the history
  • Loading branch information
eMaringolo committed Jul 6, 2022
1 parent 1ad181e commit 91db72d
Show file tree
Hide file tree
Showing 39 changed files with 246 additions and 237 deletions.
4 changes: 2 additions & 2 deletions docs/configmaps.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,9 +176,9 @@ E.g. If you have `Config Map A` and `Config Map B` in the repository, and `Confi

## Configuration Maps resolution

When you define a Configuration Map it will likely have required maps, and those maps are defined within a loading condition (`true` by default in most cases), and each prerequisite will be reference by its timestamp (the internal ID used by the ENVY Library).
When you define a Configuration Map it will likely have required maps, and those maps are defined within a loading condition (`true` by default in most cases), and each required map will be referenced by its timestamp (the internal ID used by the ENVY Library).

When working using file based repositories it's also very likely that different developers will have the same _"code"_ (Applications and Configuration Maps) but with different timestamps, so some prerequisites will be shown as _`missing`_ in the Configurations Maps Browser.
When working using file based repositories it's also very likely that different developers will have the same _"code"_ (Applications and Configuration Maps) but with different timestamps, so some required maps will be shown as _`missing`_ in the Configurations Maps Browser.

To overcome the situation described above the Tonel Tools provide different strategies to resolve the referenced Configuration Maps when looking for a configuration map.

Expand Down
18 changes: 18 additions & 0 deletions docs/strategies.md
Original file line number Diff line number Diff line change
Expand Up @@ -362,6 +362,24 @@ So to avoid having file differences when working on code that share a common rep
writer := TonelWriter new.
writer identifiersClass: Symbol.
```
### Format convenience settings

#### _"Canonical"_ format

If your objective is to export code to be used in another dialect, you can set different options as a whole like [converting shared pools](sharedpools.md) to `SharedPools` subclasses, not writing ENVY Application classes, using the Monticello extension category (as in `*PackageName` category) and will flatten SubApplications (if any) as package tags.

```smalltalk
writer := TonelWriter new.
writer beCanonical.
```
#### _"VAST Only"_ format

If the purpose of using Tonel Tools in VAST is to export code to files to be loaded back into VAST, then you can optimize a lot of settings by configuring the writer to write the files to be read only by VAST's Tonel Tools.

```smalltalk
writer := TonelWriter new.
writer beVASTOnly.
```


# Common recipes
Expand Down
12 changes: 6 additions & 6 deletions source/.configmaps
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[
{
#conditions : [ ],
#ts : 3834493110,
#ts : 3834561008,
#comment : '',
#formatVersion : '1.1',
#applications : OrderedCollection [
Expand Down Expand Up @@ -32,17 +32,17 @@
},
{
#name : 'TonelTools',
#versionName : '1.5.3',
#ts : 3827303214
#versionName : '1.5.5 d',
#ts : 3834560965
},
{
#name : 'TonelWriterModel',
#versionName : '1.5.3',
#ts : 3827303214
#versionName : '1.5.5 d',
#ts : 3834559031
}
],
#name : 'ENVY/Image Tonel',
#versionName : '1.5.5 c'
#versionName : '1.5.5 d'
},
{
#conditions : [ ],
Expand Down
3 changes: 1 addition & 2 deletions source/EmLibraryToolsApp/EmClassCallbackData.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ Extension {
#name : 'EmClassCallbackData'
}

{ #category : '*EmLibraryToolsApp',
#vaCategories : ['EM-Internal'] }
{ #category : 'EM-Internal' }
EmClassCallbackData >> asEmEvent [

self subclassResponsibility
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ Extension {
#name : 'EmClassChangeCallbackData'
}

{ #category : '*EmLibraryToolsApp',
#vaCategories : ['EM-Internal'] }
{ #category : 'EM-Internal' }
EmClassChangeCallbackData >> asEmEvent [

(self changeType bitAnd: EMCAdded) == EMCAdded
Expand Down
6 changes: 2 additions & 4 deletions source/EmLibraryToolsApp/EmLibrary.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,14 @@ Extension {
#name : 'EmLibrary'
}

{ #category : '*EmLibraryToolsApp',
#vaCategories : ['Not categorized'] }
{ #category : 'Not categorized' }
EmLibrary >> operationsInterface: anEmLibraryAccesor [
"Answer the interface used to perform library operations."

libraryAccessor := anEmLibraryAccesor
]

{ #category : '*EmLibraryToolsApp',
#vaCategories : ['EM-Internal'] }
{ #category : 'EM-Internal' }
EmLibrary >> resetOperationsInterface [

libraryAccessor := nil
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ Extension {
#name : 'EmMethodChangeCallbackData'
}

{ #category : '*EmLibraryToolsApp',
#vaCategories : ['EM-Internal'] }
{ #category : 'EM-Internal' }
EmMethodChangeCallbackData >> asEmEvent [

| class methodTs |
Expand Down
6 changes: 2 additions & 4 deletions source/EmLibraryToolsApp/EmStandardAccessor.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,13 @@ Extension {
#name : 'EmStandardAccessor'
}

{ #category : '*EmLibraryToolsApp',
#vaCategories : ['EM-Internal'] }
{ #category : 'EM-Internal' }
EmStandardAccessor >> isLoggingAccessor [

^false
]

{ #category : '*EmLibraryToolsApp',
#vaCategories : ['initializing'] }
{ #category : 'initializing' }
EmStandardAccessor >> monitor [

^EmMonitor default
Expand Down
12 changes: 4 additions & 8 deletions source/TonelLoaderInteractiveApp/TonelLoader.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -2,30 +2,26 @@ Extension {
#name : 'TonelLoader'
}

{ #category : '*TonelLoaderInteractiveApp',
#vaCategories : ['strategies-convenience'] }
{ #category : 'strategies-convenience' }
TonelLoader >> beInteractive [
self useInteractivePrerequisitesSelection.
self useInteractiveBaseEditionSelection.
self useInteractiveVersioning
]

{ #category : '*TonelLoaderInteractiveApp',
#vaCategories : ['strategies-convenience'] }
{ #category : 'strategies-convenience' }
TonelLoader >> useInteractiveBaseEditionSelection [
self
baseEditionStrategy: (TonelLoaderInteractiveBaseEditionStrategy for: self)
]

{ #category : '*TonelLoaderInteractiveApp',
#vaCategories : ['strategies-convenience'] }
{ #category : 'strategies-convenience' }
TonelLoader >> useInteractivePrerequisitesSelection [
self
prerequisitesStrategy: (TonelLoaderInteractivePrereqStrategy for: self)
]

{ #category : '*TonelLoaderInteractiveApp',
#vaCategories : ['strategies-convenience'] }
{ #category : 'strategies-convenience' }
TonelLoader >> useInteractiveVersioning [
self versionStrategy: (TonelLoaderInteractiveVersionStrategy for: self)
]
3 changes: 1 addition & 2 deletions source/TonelLoaderModel/Association.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ Extension {
#name : 'Association'
}

{ #category : '*TonelLoaderModel',
#vaCategories : ['Not categorized'] }
{ #category : 'Not categorized' }
Association >> tonelTopologicalSubordinateOf: anAssociation [
"This method will return true if the current Association's key
is a topological subordinate of anAssociation's key"
Expand Down
3 changes: 1 addition & 2 deletions source/TonelLoaderModel/Behavior.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ Extension {
#name : 'Behavior'
}

{ #category : '*TonelLoaderModel',
#vaCategories : ['Tonel-Comparing'] }
{ #category : 'Tonel-Comparing' }
Behavior >> tonelTopologicalSubordinateOf: aBehavior [
"This method will returns true if the current Behavior
is a subclass of aBehavior"
Expand Down
3 changes: 1 addition & 2 deletions source/TonelLoaderModel/Collection.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ Extension {
#name : 'Collection'
}

{ #category : '*TonelLoaderModel',
#vaCategories : ['Not categorized'] }
{ #category : 'Not categorized' }
Collection >> tonelSingleEdgeTopologicallySortedCollection [
"Replica from EtMonticelloImporter application to avoid unnecesary dependency."

Expand Down
3 changes: 1 addition & 2 deletions source/TonelLoaderModel/EmSystemConfiguration.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ Extension {
#name : 'EmSystemConfiguration'
}

{ #category : '*TonelLoaderModel',
#vaCategories : ['EM-Internal'] }
{ #category : 'EM-Internal' }
EmSystemConfiguration >> defaultApplication: anApplication during: aBlock [

| previousDefault |
Expand Down
3 changes: 1 addition & 2 deletions source/TonelLoaderModel/TonelReader.extension.st
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@ Extension {
#name : 'TonelReader'
}

{ #category : '*TonelLoaderModel',
#vaCategories : ['Convenience'] }
{ #category : 'Convenience' }
TonelReader >> createLoader [

^TonelLoader on: self
Expand Down
Loading

0 comments on commit 91db72d

Please sign in to comment.