Yeah, that's why I think it would be great if the RB engine could be extended with a(n optional) hook to call some "local/personal" formatter instead of reformatting immediately. This way we could at least make sure that the reformatting happens according to our taste and in line with whatever we use to format our code. Preserving the old formatting is likely to not be a good idea at least for some refactorings lie extract method, in addition to possibly being difficult.
The plus of such a plugin/hook approach is that this could probably be maintainable cross-platform. Every dialect could plug their formatter without changing RBs internals. I don't know if there still exists some "common code base" of RB at all, so maybe this is just stupid blah blah anywaysâ¦
But this is the case. You can pass to the pharo formatter a context and the setting browser shows you the formatting options.
Joachim
cheers -ben
On Wed, 20 May 2020 at 01:34, Vitor Medina Cruz <vitormcruz@gmail.com <mailto:vitormcruz@gmail.com>> wrote: Hello,
When I run a refactoring, Rename Method, for example, the refactoring is reformatting the code affected. Is it possible to configure Pharo to refactor without reformatting code? Depending on the refactoring, the reformat is so intrusive that make it more worth to make the refactoring by hand.
Regards, Vitor
-- ----------------------------------------------------------------------- Objektfabrik Joachim Tuchel mailto:jtuchel@objektfabrik.de <mailto:jtuchel@objektfabrik.de> Fliederweg 1 http://www.objektfabrik.de <http://www.objektfabrik.de/> D-71640 Ludwigsburg http://joachimtuchel.wordpress.com <http://joachimtuchel.wordpress.com/> Telefon: +49 7141 56 10 86 0 Fax: +49 7141 56 10 86 1
-------------------------------------------- Stéphane Ducasse http://stephane.ducasse.free.fr / http://www.pharo.org 03 59 35 87 52 Assistant: Julie Jonas FAX 03 59 57 78 50 TEL 03 59 35 86 16 S. Ducasse - Inria 40, avenue Halley, Parc Scientifique de la Haute Borne, Bât.A, Park Plaza Villeneuve d'Ascq 59650 France