[Pharo-dev] Iceberg - loading baseline

Jan Blizničenko bliznjan at fit.cvut.cz
Wed Oct 4 02:06:04 EDT 2017


I think I got it. The correct code for me is

SystemSettingsPersistence updateSettingNodes.
Metacello new baseline: 'NameOfMyProject'; repository:
'gitlocal:///C:/Users/User/Pharo/repo/nameofmyproject/filetree'; load.

First line loads my stored settings that look like this for Iceberg:
http://www.mediafire.com/view/br6isyeo69z1mqe/2017-10-03.png
and the second line puts my already existing git clone in filesystem into
Iceberg and successfully loads the baseline with all dependencies. So
problem solved for me.

Esteban, your code is, I guess, for loading the code directly from GitLab
without having local clone first, into default location of Iceberg, right?
Anyway that inspired me to remove my first part of code and that was what I
needed :)

Thank you
Jan


Jan Blizničenko wrote
> Hello
> 
> Unfortunately removing the /filetree does not seem to change anything - I
> end up with same error. If I run the code without /filetree, however, it
> creates the entry in Iceberg and then I can load it manually package by
> package via Iceberg GUI, but I cannot run the baseline either by this
> code,
> or by right clicking the baseline package and selecting "Install baseline
> (default)", because even that ends with the very same exception as my code
> (Could not resolve:...).
> 
> When I tried your code, either with or without /filetree, it ends up with
> LGit_GIT_EEOF: ERROR: Repository not found. I debugged it and found out it
> tries to find 

> git@

> :bliznjan/nameofmyproject.git but my project is
> on gitlab, not github. The problem may lie somewhere around 
> IceProviderRepositoryType>>#mcRepository
> which contains creation of MCGitHubRepository even for an instance of
> IceGitlabRepositoryType?
> 
> Also I do have Metacello integration checked, these are my Iceberg
> settings:
> http://www.mediafire.com/view/br6isyeo69z1mqe/2017-10-03.png
> 
> Jan
> 
> 
> 
> EstebanLM wrote
>>> On 3 Oct 2017, at 08:47, Jan Blizničenko <
> 
>> bliznjan at .cvut
> 
>> > wrote:
>>> 
>>> Hello
>>> 
>>> I have a local clone of git repository and I am looking for code that
>>> adds
>>> this repository to Iceberg and then loads its baseline into Pharo. I am
>>> using Pharo 6.1 (image 60510) and last stable Windows VM.
>>> 
>>> Right now I am experimenting with following code, it adds the project
>>> into
>>> Iceberg, but does not load the baseline. The code is:
>>> 
>>>  SystemSettingsPersistence updateSettingNodes. "sets ssh key locations"
>>> 
>>>  (Smalltalk at: #IceRepositoryCreator) new
>>> 	  url: '
> 
>> git@
> 
>> :bliznjan/nameofmyproject.git';
>>> 	  location: '/C:/Users/User/Pharo/repo/nameofmyproject/filetree'
>>> asFileReference;
>>> 	  subdirectory: 'filetree';
>>> 	  createRepository. "this part seems to work fine”
>> 
>> I think this is your error:
>> '/C:/Users/User/Pharo/repo/nameofmyproject/filetree, needs to be
>> '/C:/Users/User/Pharo/repo/nameofmyproject (without the filetree part,
>> which is the subdirectory)
>> 
>> now, I think if you do: 
>> 
>> Metacello new 
>> 	repository: ‘gitlab://bliznjan/nameofmyproject/filetree'
>> <gitlab://bliznjan/nameofmyproject/filetree'>;
>> 	baseline: ‘MyProject’
>> 	load.
>> 
>> ir will also do what you want without the two steps.
>> 
>>> 
>>>  Metacello new baseline: 'NameOfMyProject'; repository:
>>> 'gitlocal:///C:/Users/User/Pharo/repo/nameofmyproject/filetree'; load.
>>> "this
>>> one fails with exception below"
>>> 
>>> 
>>> loading the baseline ends with Exception
>>>  Could not resolve: BaselineOfNameOfMyProject
>>> [BaselineOfNameOfMyProject]
>>> in C:\Users\User\Pharo\images\TestingImage1\pharo-local\package-cache
>>> C:\Users\User\Pharo\repo\nameofmyproject\filetree (Libgit)
>>> 
>>> Those paths seem correct - the package-cache is located in exactly that
>>> position (but does not contain anything that relates to my project) and
>>> the
>>> filetree (repository) in the mentioned path and there is a
>>> BaselineOfNameOfMyProject.package directory in there.
>>> 
>>> Also, if I then try loading the baseline manually via Iceberg, by right
>>> clicking on BaselineOfNameOfMyProject in Packages tab, I get exactly
>>> same
>>> exception.
>>> 
>>> Loading packages one by one manually via Iceberg Packages tab works.
>>> Also,
>>> loading the baseline via GitFileTree works.
>>> 
>>> Thank you
>>> Jan
>>> 
>>> 
>>> 
>>> --
>>> Sent from:
>>> http://forum.world.st/Pharo-Smalltalk-Developers-f1294837.html
>>>
> 
> 
> 
> 
> 
> --
> Sent from: http://forum.world.st/Pharo-Smalltalk-Developers-f1294837.html





--
Sent from: http://forum.world.st/Pharo-Smalltalk-Developers-f1294837.html




More information about the Pharo-dev mailing list