The Trunk: System-edc.259.mcz

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

The Trunk: System-edc.259.mcz

commits-2
Edgar J. De Cleene uploaded a new version of System to project The Trunk:
http://source.squeak.org/trunk/System-edc.259.mcz

==================== Summary ====================

Name: System-edc.259
Author: edc
Time: 22 February 2010, 4:19:55.809 pm
UUID: 837b65aa-e3d4-4325-a5d1-279fda51b4d0
Ancestors: System-ul.258

Add CodeLoaderEnh as sended to list.

Examples os use:

| loader |
        loader _ CodeLoader new.
        loader baseURL: 'http://www.squeaksource.com/Ladrillos/'.
        loader loadSourceFiles: #('FFI-Kernel-ar.7.mcz' 'Network-IRC-fc.10.7.6.mcz');installSourceFiles.
       
        | loader |
        loader _ CodeLoader new.
        loader baseURL: 'http://www.squeaksource.com/MathMorphsRevival/'.
        loader loadSourceFiles: #('MorphicWrappers-edc.3.mcz' 'Functions-zz.4.mcz');installSourceFiles.
       




=============== Diff against System-ul.258 ===============

Item was added:
+ ----- Method: CodeLoader>>lookLastVersion: (in category 'installing') -----
+ lookLastVersion: packageName
+ | mcw montiNames package version |
+ mcw := MCWorkingCopyBrowser new
+ repository: (MCHttpRepository
+ location: baseURL
+ user: 'squeak'
+ password: 'squeak').
+ mcw repository
+ ifNotNilDo: [:repos | montiNames := repos readableFileNames].
+ package := montiNames
+ detect: [:any | any beginsWith: packageName]
+ ifNone: [].
+ package
+ ifNotNil: [Utilities
+ informUser: 'Installing ' , packageName printString
+ during: [version := mcw repository loadVersionFromFileNamed: package.
+ version load]].
+ MCPackageManager
+ managersForCategory: packageName
+ do: [:wc | wc repositoryGroup
+ addRepository: (MCHttpRepository new location: baseURL)]!

Item was added:
+ ----- Method: CodeLoader>>installMonticelloFor: (in category 'installing') -----
+ installMonticelloFor: aList
+ "Install the previously loaded source files"
+ aList
+ do: [:packName | self lookMonticelloVersion: packName].
+ sourceFiles := nil!

Item was added:
+ ----- Method: CodeLoader>>segments (in category 'accessing') -----
+ segments
+ ^ segments!

Item was added:
+ ----- Method: CodeLoader>>tryVersion: (in category 'debugging') -----
+ tryVersion: packageName
+ | mcw montiNames package version |
+
+ mcw := MCWorkingCopyBrowser new repository: (MCHttpRepository
+ location: baseURL
+ user: ''
+ password: '').
+ mcw repository ifNotNilDo: [:repos | montiNames := repos readableFileNames ].
+
+
+
+ package := (montiNames detect:[:ea| ea beginsWith: packageName] ifNone:[] ) .
+ package ifNotNil: [MCWorkingCopy allManagers do: [:each |
+ each  repositoryGroup
+ addRepository: (MCHttpRepository new location: baseURL)]..
+ version := mcw repository loadVersionFromFileNamed: package.
+ version load].
+ ^version!

Item was changed:
  ----- Method: CodeLoader>>installSourceFiles (in category 'installing') -----
  installSourceFiles
  "Install the previously loaded source files"
+ | aSuffix |
+ sourceFiles == nil
+ ifTrue: [^ self].
+ sourceFiles
+ do: [:req | aSuffix :=  (req url  findTokens: '.') last..
+
+ aSuffix caseOf: {
+ [ 'mcz'] -> [MczInstaller installStream: req contentStream].
+ ['sar'] ->[ SARInstaller new fileInFrom: req contentStream]}
+ otherwise: [self installSourceFile: req contentStream]].
+ sourceFiles := nil!
- sourceFiles == nil ifTrue:[^self].
- sourceFiles do:[:req| self installSourceFile: req contentStream].
- sourceFiles := nil.!

Item was added:
+ ----- Method: CodeLoader>>installLastMonticelloFor: (in category 'installing') -----
+ installLastMonticelloFor: aList
+ "Install the previously loaded source files"
+
+ aList
+ do: [:packName |
+
+ self lookLastVersion: packName].
+ sourceFiles := nil!

Item was added:
+ ----- Method: CodeLoader>>lookMonticelloVersion: (in category 'installing') -----
+ lookMonticelloVersion: packageName
+ | mcw montiNames package version |
+ mcw := MCWorkingCopyBrowser new
+ repository: (MCHttpRepository
+ location: baseURL
+ user: 'squeak'
+ password: 'squeak').
+ mcw repository
+ ifNotNilDo: [:repos | montiNames := repos readableFileNames].
+ package := montiNames
+ detect: [:any | any = packageName]
+ ifNone: [].
+ package
+ ifNotNil: [Utilities
+ informUser: 'Installing ' , packageName printString
+ during: [version := mcw repository loadVersionFromFileNamed: package.
+ version load]].
+ MCPackageManager
+ managersForCategory: packageName
+ do: [:wc | wc repositoryGroup
+ addRepository: (MCHttpRepository new location: baseURL)]!