Clearing objects from .changes

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

Clearing objects from .changes

Peter Uhnak
Is it possible to remove all references to a class after it has been removed everywhere?

For example I can delete all classes of package 'Roassal2-Builder-Grapher'

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
pkg := RPackageOrganizer default packageNamed: 'Roassal2'.
grapherTag := pkg classTags detect: [ :each | each name = #'Builder-Grapher' ].
grapherTag classes do: [ :each | removeClass value: each ].
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

However this leaves the .changes file intact, even after I do "Smalltalk cleanUp: true".

The reason why I am doing this is to lower the size of .changes/.images files which are massive just after loading my project... so it takes a lot of space for testing...

Thanks,
Peter
Reply | Threaded
Open this post in threaded view
|

Re: Clearing objects from .changes

Sven Van Caekenberghe-2
What you (probably) want is called 'condensing the changes'.
Have a look at the class PharoChangesCondenser.

<< I create a new more compact changes files with a single version of each method in the image. >>

> On 06 Jul 2015, at 11:08, Peter Uhnák <[hidden email]> wrote:
>
> Is it possible to remove all references to a class after it has been removed everywhere?
>
> For example I can delete all classes of package 'Roassal2-Builder-Grapher'
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> pkg := RPackageOrganizer default packageNamed: 'Roassal2'.
> grapherTag := pkg classTags detect: [ :each | each name = #'Builder-Grapher' ].
> grapherTag classes do: [ :each | removeClass value: each ].
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> However this leaves the .changes file intact, even after I do "Smalltalk cleanUp: true".
>
> The reason why I am doing this is to lower the size of .changes/.images files which are massive just after loading my project... so it takes a lot of space for testing...
>
> Thanks,
> Peter


Reply | Threaded
Open this post in threaded view
|

Re: Clearing objects from .changes

Peter Uhnak
Excellent!

Now I have successfully lowered the build size from 38MB to just 13MB. :)

Thanks,
Peter

On Mon, Jul 6, 2015 at 11:10 AM, Sven Van Caekenberghe <[hidden email]> wrote:
What you (probably) want is called 'condensing the changes'.
Have a look at the class PharoChangesCondenser.

<< I create a new more compact changes files with a single version of each method in the image. >>

> On 06 Jul 2015, at 11:08, Peter Uhnák <[hidden email]> wrote:
>
> Is it possible to remove all references to a class after it has been removed everywhere?
>
> For example I can delete all classes of package 'Roassal2-Builder-Grapher'
>
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> pkg := RPackageOrganizer default packageNamed: 'Roassal2'.
> grapherTag := pkg classTags detect: [ :each | each name = #'Builder-Grapher' ].
> grapherTag classes do: [ :each | removeClass value: each ].
> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>
> However this leaves the .changes file intact, even after I do "Smalltalk cleanUp: true".
>
> The reason why I am doing this is to lower the size of .changes/.images files which are massive just after loading my project... so it takes a lot of space for testing...
>
> Thanks,
> Peter