fidley / ABAPQuickFix

ABAP Quick Fix
https://abapblog.com
MIT License
42 stars 9 forks source link

Replace all Operators #27

Open g-back opened 2 years ago

g-back commented 2 years ago

We have the already great fixes to replace single instances of EQ, GE, LE etc. - would be cool if we could replace ALL instances of these operators in a file.

Will try to take a crack at this myself, when I find the time 🙂

fidley commented 2 years ago

Hello @g-back, that sounds good. But be careful those quick fixes were done using regex. I'd recommend to use the tokens like in here https://github.com/fidley/ABAPQuickFix/blob/master/ABAP%20Quick%20Fix%20Plugin/src/com/abapblog/adt/quickfix/assist/formatter/AlignOperators.java

Could solve some issues. Would be great also to have preference to switch it on/off as in some cases it can be time consuming.

Cheers

fidley commented 2 years ago

An ideas to extend this:

  1. Maybe could be a good option to create a Toolbar menu entry which will serve to apply such mass quick fixes?
  2. There could be one entry in such menu or even quick fix with possiblity to switch on/off in preferences, that would apply all selected quick fixes in the full or selected code?
fidley commented 1 year ago

@g-back any news here? Or you quit the idea of doing it yourself? :)