Kilon,Regarding Pharo4.0 and Metacello, I just recently added Pharo4.0 support to Metacello[1] and buildCI[2].If you are using github, then you should checkout builderCI. BuilderCI let's you hook into travis-ci[3] and run unit tests on every commit. It's especially useful when you get a pull request, because the unit tests are run against the MERGED version of the pull request (BEFORE you do the merge), so you can be assured that when you do the merge, your tests will be green ...Let me know if the builderCI instructions[4] work for you...It's been awhile since I've reviewed the docs:)DaleOn Sat, Nov 15, 2014 at 8:55 AM, kilon alios <kilon.alios@gmail.com> wrote:YESSSS!!!!thanks Dale, you are awesome, it works like a charm for me now.��Yes you needed to download the Pharo3DarkTheme because the Theme is installed by default in Pharo 4 and I dont intent on supporting pharo 3 with my project. If you tried Pharo 4 you would have no such issue.��I would appreciate it if other people could spend just a minute getting latest Pharo 4 and trying this in a WorkspaceMetacello new��baseline:'Nireas';repository:'github://kilon/nireas:master';get.Metacello new��baseline:'Nireas';repository:'github://kilon/nireas:master';load.Then open a System Browser and make sure Nireas package exist and please report it here if its not much trouble.�� This solution is super easy for installing git repos and we could make a class to make it even easier with a single line command.��Question: Why Pharo 4 has not got the latest Metacello ?��On Sat, Nov 15, 2014 at 6:33 PM, Dale Henrichs <dale.henrichs@gemtalksystems.com> wrote:Kilon,This code:Metacello new��baseline:'Nireas';repository:'github://kilon/Nireas:master';get;load.does require a pretty recent version of Metacello ("chaining" the get and load)[1].�� I tried the following in a stock pharo3.0 and got an error about requiring Pharo3DarkTheme, so I was able to load the package:Metacello new��baseline:'Nireas';repository:'github://kilon/Nireas:master';get.Metacello new��baseline:'Nireas';repository:'github://kilon/Nireas:master';load.DaleOn Sat, Nov 15, 2014 at 3:13 AM, kilon alios <kilon.alios@gmail.com> wrote:ok after rereading your emails more carefully i realised that you meant that BaselineOf should go to its own package, so I moved the class to BaselineOfNireas package and now it does not report the same error but now it complain that project,baseline or configuration not specified.��Is it mandatory to specify a configuration for my project , I though the baseline class was enough. Would love to hear more info on the subject, I am looking also at the Metacello chapter which by the way is in Deep Into Pharo and not PBE , I see loads of info on the subject but does not seem to mention anything about the BaselineOf class .��Will love it if we can gave a simple way to load git repos to pharo 4.��On Sat, Nov 15, 2014 at 12:53 PM, kilon alios <kilon.alios@gmail.com> wrote:small typo in my paste��the actual code i used is��Metacello new��baseline:'Nireas';repository:'github://kilon/Nireas:master';get;load.any help is appreciated :)��On Sat, Nov 15, 2014 at 12:50 PM, kilon alios <kilon.alios@gmail.com> wrote:hello Dale I tried your approach with a new project I created called Nireas, its a theme manager for pharo 4. I followed your instructions and it complains that it cannot find the BaselineOfNireasThis is the code I usedMetacello new��baseline:'Nireas';repository:'github://kilon/nireas:master';get;load.here is the repo��and here is the errorMetacelloFetchingMCSpecLoader(MetacelloCommonMCSpecLoader)>>retryingResolvePackageSpecReferences:gofer:linearLoadPackageSpec: packageSpec gofer: goferMetacelloPlatform currentdo: [��| references nearestReference cachedReference externalReference mcVersion loadedVersionInfos |"check to see if mcz file is already in cacheRepository"cachedReference := self resolvePackageSpec: packageSpec cachedGofer: self loaderPolicy cacheGofer.(cachedReference ~~ nil and: [ packageSpec getFile ~~ nil ])ifTrue: [��cachedReference name = packageSpec fileifTrue: [��"exact match between packageSpec file and cache"^ self scheduleFetchFor: packageSpec cachedReference: cachedReference ] ]. "look up mcz file"references := self retryingResolvePackageSpecReferences: packageSpec gofer: gofer.nearestReference := references last asMetacelloCachingResolvedReference. "If the mcz is already in the cacheRepository, no need to copy"(cachedReference ~~ nil and: [ cachedReference name = nearestReference name ])ifTrue: [��"latest reference in repository matches cachedReference ... "^ self scheduleFetchFor: packageSpec nearestReference: nearestReference ]. "If the mcz is already loaded into the image, no need to copy"(self ignoreImage not and: [ (loadedVersionInfos := self ancestorsFor: packageSpec) ~~ nil ])ifTrue: [��loadedVersionInfosdo: [ :info |��info name = nearestReference nameifTrue: [ ^ self ] ] ].externalReference := (references select: [ :ref | ref name = nearestReference name ]) firstasMetacelloCachingResolvedReference.self repositoryMap at: externalReference name put: externalReference repository.(selfresolveDependencies: externalReferencenearest: nearestReferenceinto: (OrderedCollection with: nearestReference))do: [ :reference |��| pSpec l |mcVersion := reference version.(l := (GoferVersionReference name: reference name) resolveAllWith: self loaderPolicy cacheGofer) isEmptyifTrue: [��self cacheRepository storeVersion: mcVersion.reference == nearestReferenceifTrue: [ pSpec := packageSpec ]ifFalse: [��pSpec := packageSpec project packageSpec.pSpec name: mcVersion package name ].self loadDataaddVersion: mcVersionversionInfo: mcVersion inforesolvedReference: referencepackageSpec: pSpec ] ].self scheduleFetchFor: packageSpec externalReference: externalReference ]displaying: 'Fetching ' , packageSpec file in MetacelloFetchingMCSpecLoader>>linearLoadPackageSpec:gofer: in Block: linearLoadPackageSpec: packageSpec gofer: gofer...MetacelloPharo30Platform(MetacelloPlatform)>>do:displaying:MetacelloFetchingMCSpecLoader>>linearLoadPackageSpec:gofer:MetacelloPackageSpec>>loadUsing:gofer:[ :pkg | pkg loadUsing: self gofer: gofer ] in MetacelloFetchingMCSpecLoader(MetacelloCommonMCSpecLoader)>>linearLoadPackageSpecs:repositories: in Block: [ :pkg | pkg loadUsing: self gofer: gofer ]Array(SequenceableCollection)>>do:MetacelloFetchingMCSpecLoader(MetacelloCommonMCSpecLoader)>>linearLoadPackageSpecs:repositories:[ super linearLoadPackageSpecs: packageSpecs repositories: repositories ] in MetacelloFetchingMCSpecLoader>>explicitLoadPackageSpecs:repositories: in Block: [ super linearLoadPackageSpecs: packageSpecs repos...etc...BlockClosure>>ensure:MetacelloLoaderPolicy>>pushLoadDirective:during:MetacelloLoaderPolicy>>pushExplicitLoadDirectivesDuring:for:MetacelloFetchingMCSpecLoader>>explicitLoadPackageSpecs:repositories:MetacelloPackageSpec>>explicitLoadUsing:MetacelloPackageSpec>>load[��self setDefaultsAndValidateProjectSpec.spec := self projectSpec.projectPackage := spec projectPackage.projectPackage repositorySpecs do: [ :repoSpec | repoSpec createRepository flushForScriptGet ].projectPackage load.self root: (Smalltalk at: spec className asSymbol) project.MetacelloProjectRegistrationregistrationForProjectSpec: specifAbsent: [ :new | new registerProject ]ifPresent: [ :existing :new |��existingcopyOnWrite: [ :existingCopy |��speccopyForRegistration: existingCopyonWrite: [ :specCopy | specCopy ifNil: [ existingCopy merge: new ] ifNotNil: [ specCopy mergeScriptRepository: spec ] ] ] ] ] in MetacelloScriptEngine>>get in Block: [ ...BlockClosure>>ensure:MetacelloProjectRegistration class>>copyRegistryRestoreOnErrorWhile:MetacelloScriptEngine>>get[ :projectSpec |��| engine |engine := MetacelloScriptEngine newoptions: self options copy;projectSpec: projectSpec;yourself.engine perform: actionArg key withArguments: actionArg value.engine root ifNotNil: [ :root | self roots add: root ] ] in MetacelloScriptApiExecutor(MetacelloScriptExecutor)>>execute: in Block: [ :projectSpec | ...[ :projectSpec | projectSpec ifNotNil: [ projectSpecBlock value: (self applyArgsToProjectSpec: projectSpec copy) ] ] in MetacelloScriptApiExecutor>>executeString:do: in Block: [ :projectSpec | projectSpec ifNotNil: [ projectSp...etc...Array(SequenceableCollection)>>do:MetacelloScriptApiExecutor>>executeString:do:ByteString(String)>>execute:against:MetacelloScriptApiExecutor(MetacelloScriptExecutor)>>execute:Metacello>>executeMetacello>>getUndefinedObject>>DoItOpalCompiler>>evaluateRubSmalltalkEditor>>evaluateSelectionAndDo:On Tue, Oct 21, 2014 at 10:55 PM, kilon alios <kilon.alios@gmail.com> wrote:Thank you Dale very much , this is very clear :)��On Tue, Oct 21, 2014 at 10:53 PM, Dale Henrichs <dale.henrichs@gemtalksystems.com> wrote:On Tue, Oct 21, 2014 at 12:04 PM, kilon alios <kilon.alios@gmail.com> wrote:Thank you Dale, this is more simple than I expected.��From what you linked it looks like by [:comitish] you mean the git branch .Which in my case is master so it should be�������� repository: 'github://kilon/phEphestos:master/'�� Metacello new������ baseline: 'BaselineOfXXX';������ get;������ load.From looking at your repo on githug, the expression would be:
���� Metacello new
���������� baseline: 'Ephestos';
���������� repository: 'github://kilon/phEphestos:master'������ get;������ load.A commitish is a branch, SHA or tag. Note also, that my example was wrong ... the 'BaselineOf' shouldn't�� be used in the baseline: argument, just the base name of the project.
You also need to create a BaselineOfEphestos which specifies package load order. BaselineOfEphestos would be created as a subclass of BaselineOf and have a single method:�� baseline: spec������ <baseline>������ spec
���������� for: #pharo���������� do: [�������������� spec package: 'Ephestos' ].Then the above expression would load the Epestos package.
If you were to add another package, say EphestosTests, then you'd update the baseline to declare that EphestosTests requires Ephestos to be loaded first you'd edit the baseline: method:baseline: spec������ <baseline>������ spec
���������� for: #pharo���������� do: [�������������� spec
������������������ package: 'Ephestos';�� �� �� �� �� package: 'EphestosTests' with: [ spec requires: #( 'Ephestos' ) ] ].You commit the BaselineOf along with the rest of the packages for your project ...For more information see the Metacello chapter in Pharo by Example...Dale