http://book.pharo-project.org/book/TipsAndTricks/FixingUnderscores/

:)


On Apr 12, 2010, at 12:51 AM, Fernando olivero wrote:

> Hi all, i just wanted to re post the fix underscore code Lukas posted a while 
> ago.
> 
> I've just imported Connectors package into pharo, (i'm trying to get a 
> minimal version working ), and stumbled upon the problem of the underscores..
> but now thanks to SmallInt rules it was easy and fast to overcome this 
> problem!
> 
> Thanks!!!!
> 
> Fernando
> 
> 
> pd: From previous mail from lukas.
> 
> 
> 1. Load the code:
> 
>   Gofer new
>       squeaksource: 'rb';
>       package: 'AST-Core';
>       package: 'Refactoring-Core';
>       load.
> 
> 2. Select the code (packages) you want to fix:
> 
>   environment := BrowserEnvironment new
>       forPackageNames: #('Connectors-Base' 'Connectors-Lines and Curves').
> 
> 3. Create the transformation rule:
> 
>   rule := RBUnderscoreAssignmentRule new.
> 
> 4. Perform the search:
> 
>   SmalllintChecker runRule: rule onEnvironment: environment.
> 
> 5. Perform the transformation:
> 
>   change := CompositeRefactoryChange new.
>   change changes: rule changes.
>   change execute                                                      
> _______________________________________________
> Pharo-project mailing list
> [email protected]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[email protected]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

Reply via email to