-
Notifications
You must be signed in to change notification settings - Fork 83
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixes #6
- Add abstract class for common test code.
- Add IcePackageR…
…eference to model packages from our view. - Differentiate loaded from unloaded packages in a repository. -
- Loading branch information
1 parent
8a780ab
commit 31c50cf
Showing
31 changed files
with
98 additions
and
28 deletions.
There are no files selected for viewing
3 changes: 3 additions & 0 deletions
3
Iceberg.package/FileSystemDirectoryEntry.extension/instance/asIcePackage.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
*Iceberg-Core | ||
asIcePackage | ||
^ Ice packageNamed: self asFileReference basenameWithoutExtension |
2 changes: 2 additions & 0 deletions
2
Iceberg.package/FileSystemDirectoryEntry.extension/properties.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
{ | ||
"name" : "FileSystemDirectoryEntry" } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
accessing | ||
packageNamed: packageName | ||
^ MCPackage named: packageName | ||
^ IcePackageReference named: packageName |
This file was deleted.
Oops, something went wrong.
4 changes: 0 additions & 4 deletions
4
Iceberg.package/Ice.class/class/workingCopiesForRepository..st
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
accessing | ||
workingCopyForPackageNamed: packageName | ||
^ self workingCopyForPackage: (self packageNamed: packageName) | ||
^ (self packageNamed: packageName) workingCopy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
Iceberg.package/IcePackageChangeSet.class/instance/description.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
printing | ||
description | ||
^ self package packageName |
5 changes: 4 additions & 1 deletion
5
Iceberg.package/IcePackageChangeSet.class/instance/printOn..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
printing | ||
printOn: aStream | ||
aStream nextPutAll: self package name | ||
aStream nextPutAll: self class name; | ||
nextPut: $(; | ||
nextPutAll: self package packageName; | ||
nextPut: $) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
I represent a package, that could be in an IceRepository or in the image. | ||
|
||
Public API and Key Messages | ||
- isLoaded tells if the package is currently loaded in the image. | ||
|
||
In the future we should add load/unload here. | ||
We could also add commit, but in general is better to commit at the project level and not at the package level. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
instance creation | ||
named: aPackageName | ||
^ self new | ||
packageName: aPackageName; | ||
yourself |
4 changes: 4 additions & 0 deletions
4
Iceberg.package/IcePackageReference.class/instance/^equals.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
comparing | ||
= anotherPackage | ||
^ anotherPackage species = self species | ||
and: [ self packageName = anotherPackage packageName ] |
3 changes: 3 additions & 0 deletions
3
Iceberg.package/IcePackageReference.class/instance/isLoaded.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
accessing | ||
isLoaded | ||
^ RPackageOrganizer default includesPackageNamed: packageName |
3 changes: 3 additions & 0 deletions
3
Iceberg.package/IcePackageReference.class/instance/packageName..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
accessing | ||
packageName: anObject | ||
packageName := anObject |
3 changes: 3 additions & 0 deletions
3
Iceberg.package/IcePackageReference.class/instance/packageName.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
accessing | ||
packageName | ||
^ packageName |
9 changes: 9 additions & 0 deletions
9
Iceberg.package/IcePackageReference.class/instance/printOn..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
printing | ||
printOn: aStream | ||
aStream nextPutAll: self class name; | ||
nextPut: $(; | ||
nextPutAll: packageName; | ||
nextPutAll: ', '; | ||
nextPutAll: (self isLoaded ifTrue: 'loaded' ifFalse: 'not loaded'); | ||
nextPut: $) | ||
|
4 changes: 4 additions & 0 deletions
4
Iceberg.package/IcePackageReference.class/instance/workingCopy.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
querying | ||
workingCopy | ||
^ self isLoaded ifTrue: [ | ||
MCWorkingCopy forPackage: (MCPackage named: self packageName)] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
{ | ||
"category" : "Iceberg-Core", | ||
"classinstvars" : [ | ||
], | ||
"classvars" : [ | ||
], | ||
"commentStamp" : "NicoPasserini 5/25/2016 12:00", | ||
"instvars" : [ | ||
"packageName" ], | ||
"name" : "IcePackageReference", | ||
"pools" : [ | ||
], | ||
"super" : "Object", | ||
"type" : "normal" } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,3 @@ | ||
querying | ||
allPackages | ||
^ Array streamContents: [ :result | | ||
self lookupPackages collect: [ :directory | | ||
Ice packageNamed: (directory asFileReference basenameWithoutExtension) | ||
ifPresent: [ :package | result nextPut: package mcPackage ] | ||
]] | ||
^ self lookupPackages collect: #asIcePackage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 3 additions & 0 deletions
3
Iceberg.package/IceRepository.class/instance/loadedPackages.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
working copies | ||
loadedPackages | ||
^ self allPackages filter: #isLoaded |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
printing | ||
printOn: aStream | ||
aStream nextPutAll: self class name; | ||
nextPut: $(; | ||
nextPutAll: self origin url; | ||
nextPut: $) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
versions handling | ||
versionsFor: package | ||
^ self allVersionDescriptors select: [ :version | version packageName = package name ] | ||
^ self allVersionDescriptors select: [ :version | version packageName = package packageName ] |
9 changes: 9 additions & 0 deletions
9
Iceberg.package/IceRepository.class/instance/workingCopies.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
working copies | ||
workingCopies | ||
^ self loadedPackages collect: #workingCopy | ||
" ^ Array streamContents: [ :result | | ||
self lookupPackages collect: [ :directory | | ||
Ice packageNamed: (directory asFileReference basenameWithoutExtension) | ||
ifPresent: [ :package | result nextPut: package mcPackage ] | ||
]] | ||
" |
2 changes: 1 addition & 1 deletion
2
Iceberg.package/IceSimpleClassReference.class/instance/package.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
accessing | ||
package | ||
^ self targetClass package mcPackage | ||
^ Ice packageNamed: self targetClass package name |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
Iceberg.package/IceWorkingCopyList.class/instance/repository..st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
initialization | ||
repository: aGitRepository | ||
repository := aGitRepository. | ||
list items: ((Ice workingCopiesForRepository: repository) | ||
list items: (repository workingCopies | ||
sorted: [ :a :b | a name < b name ]). |
2 changes: 2 additions & 0 deletions
2
Iceberg.package/ImportingResourceHelp.extension/class/otraPrueba.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
*Iceberg | ||
otraPrueba |
2 changes: 2 additions & 0 deletions
2
Iceberg.package/ImportingResourceHelp.extension/class/prueba.st
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
*Iceberg-Core | ||
prueba |
2 changes: 2 additions & 0 deletions
2
Iceberg.package/ImportingResourceHelp.extension/properties.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
{ | ||
"name" : "ImportingResourceHelp" } |