buildship
buildship copied to clipboard
Undo and redo in build script editor applies to most recent opened file
Expected Behavior
Undo and redo should apply in the focused editor.
Current Behavior
Undo and redo applies to the most recently opened editor.
Context
I often open multiple build scripts, and switch back to earlier tabs. This means if I make a mistake in a build script, and try to undo it, it doesn't work. This usually leads to either rewriting a fairly significant portion of the script, or closing and reopening the editor to revert to the last save.
Steps to Reproduce
In this case, it's pretty much project agnostic.
- Create two .gradle files.
- Open both of them.
- Edit the first script.
- Edit the second script.
- Return to the first script, and press Ctrl+Z.
- Observe that the undo has been applied in the second editor.
Your Environment
Gradle version (probably) doesn't matter since the Gradle editor seems to be fairly minimal. Eclipse version is 2022-06 for Java Developers. I've had this issue since updating to 2020-03. It stopped occuring after downgrading to 2019-12.
Experiencing the same issue.
Same here, annoying!!!
Workaround: Open in text editor :/
You can also use the Groovy development plugin's editor.
You can also use the Groovy development plugin's editor.
...when it is installed. It is not part of Buildship or of any Eclipse distribution I use.
You can also use the Groovy development plugin's editor.
...when it is installed. It is not part of Buildship or of any Eclipse distribution I use.
Yes, this certainly needs fixing.
I'm using Buildship 3.1.6 and undo/redo are completely disabled in the build.gradle editor. Even the menu items under the Edit menu are disabled. This seems like a pretty major defect in the editor - I mean undo/redo is pretty much required functionality in any text editor. Is this being worked on? Have any of the contributors responded to this report?
@donat can you or any other members of the dev team comment on this issue?
I am also using Buildship 3.1.6 with Eclipse IDE for Enterprise Java and Web Developers, Version: 2022-12 (4.26.0). Undo works for me, but only in the last opened Gradle-Editor. So be sure to close any other build scripts before editing another one ;)
Am Mi., 19. Apr. 2023 um 17:58 Uhr schrieb Eric Rizzo < @.***>:
@donat https://github.com/donat can you or any other members of the dev team comment on this issue?
— Reply to this email directly, view it on GitHub https://github.com/eclipse/buildship/issues/1188#issuecomment-1514981404, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAXMBPUAE7TRLAPDWOINMXDXCADQTANCNFSM53V565JQ . You are receiving this because you are subscribed to this thread.Message ID: @.***>
I was also able to reproduce it. It seems like the editor implementation class has either the wrong superclass or something is off in its configuration.
I don't have the capacity to investigate right now. At the same time, if anyone from the community can help out with a pull request I'll be happy to review it.