Bug 461889 - Allow editing launch configurations using an editor
Summary: Allow editing launch configurations using an editor
Status: ASSIGNED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Debug (show other bugs)
Version: 4.5   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Cole Markham CLA
QA Contact:
URL:
Whiteboard:
Keywords: contributed
Depends on:
Blocks:
 
Reported: 2015-03-11 03:23 EDT by Cole Markham CLA
Modified: 2018-01-10 18:55 EST (History)
6 users (show)

See Also:
daniel_megert: review? (sarika.sinha)


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Cole Markham CLA 2015-03-11 03:23:22 EDT
Launch configurations that get saved as a workspace file open by default with the text editor. It would be nice if these could be opened with a real editor instead. This would also be a good alternative to the modal dialog currently used to edit launch configurations.
Comment 1 Eclipse Genie CLA 2015-03-11 03:37:58 EDT
New Gerrit change created: https://git.eclipse.org/r/43646
Comment 2 Eclipse Genie CLA 2015-03-11 14:50:03 EDT
New Gerrit change created: https://git.eclipse.org/r/43690
Comment 3 Sarika Sinha CLA 2015-03-17 02:19:39 EDT
As M6 is at the end, will be looking at it in 4.5 M7.
Thanks for the contribution.
Comment 4 Cole Markham CLA 2015-03-17 15:29:07 EDT
I have some more things I'd like to implement around this if it's something that will make it into the release. I've heard there is some controversy around using editors for launch configurations. If the Platform Debug team is on board, here are some of the other things I want to look at implementing:

* Launch actions on the editor (much like the PDE product editor)
* A view to show all launch configurations (like the left pane in the current dialog)
* Integration with the Launch Bar (from CDT), add a preference to open configurations in an editor instead of a dialog.
Comment 5 Sarika Sinha CLA 2015-03-30 05:33:02 EDT
Patch looks good and does not have any API change.
Comment 6 Sarika Sinha CLA 2015-04-08 06:40:33 EDT
(In reply to Cole Markham from comment #4)
> I have some more things I'd like to implement around this if it's something
> that will make it into the release. I've heard there is some controversy
> around using editors for launch configurations. If the Platform Debug team
> is on board, here are some of the other things I want to look at
> implementing:
> 
> * Launch actions on the editor (much like the PDE product editor)
> * A view to show all launch configurations (like the left pane in the
> current dialog)
> * Integration with the Launch Bar (from CDT), add a preference to open
> configurations in an editor instead of a dialog.


Can you please clarify "I've heard there is some controversy around using editors for launch configurations" !! I don't have the context.
Comment 7 Cole Markham CLA 2015-04-08 12:15:51 EDT
(In reply to Sarika Sinha from comment #6)
> (In reply to Cole Markham from comment #4)
> > I have some more things I'd like to implement around this if it's something
> > that will make it into the release. I've heard there is some controversy
> > around using editors for launch configurations. If the Platform Debug team
> > is on board, here are some of the other things I want to look at
> > implementing:
> 
> 
> Can you please clarify "I've heard there is some controversy around using
> editors for launch configurations" !! I don't have the context.

It was just something I heard while asking around at EclipseCon. If the current committers are not opposed to editors, then either I misunderstood or it is in the past.

Thanks for looking at this. I realized that I created two separate Gerrit changes which was not my intention. Still trying to figure that process out. Would you like me to combine them?
Comment 8 Sarika Sinha CLA 2015-04-09 03:53:03 EDT
Yes it will be good to have one gerrit change .
Comment 9 Dani Megert CLA 2015-04-09 06:27:31 EDT
(In reply to Sarika Sinha from comment #6)
> Can you please clarify "I've heard there is some controversy around using
> editors for launch configurations" !! I don't have the context.

Mike, can you remember of anything here?
Comment 10 Michael Rennie CLA 2015-04-09 11:18:08 EDT
(In reply to Dani Megert from comment #9)
> (In reply to Sarika Sinha from comment #6)
> > Can you please clarify "I've heard there is some controversy around using
> > editors for launch configurations" !! I don't have the context.
> 
> Mike, can you remember of anything here?

Traditionally we have always said "don't edit them except in the launch dialog" - the reason being, if you change the configuration in an editor in a way the launch dialog bits cannot handle, the config is useless - and in some cases will cause the dialog to fail.

That said, the proposed fix is very cool, and seems to use the launch dialog logic / UI for the editing, so I think we would be OK (we get the same validation / saving / etc as we do in the dialog itself).
Comment 11 Cole Markham CLA 2015-04-09 11:47:30 EDT
I removed the extra Gerrit change and merged those changes into the original.
Comment 12 Sarika Sinha CLA 2015-04-14 05:31:41 EDT
Some review comments:
From Code : Please add Copyright in new files and update the year for existing files.

From Test: 
1. If I have editor open in workspace and open the configuration from Run Configurations. I do some changes and Apply, there is no dirty sign in the launch configuration opened in the workspace editor. Save does get enabled.
2. If I have editor open in workspace and open the configuration from Run Configurations. I go to Common Tab and change "Save As" to Local File. file gets removed from Package Explorer but file remains opened in the editor window. I can save and it brings back the file in Package Explorer.
Comment 13 Sarika Sinha CLA 2015-04-26 02:23:19 EDT
Cole, Do you plan to fix these comments in Mars time frame ?
Comment 14 Sarika Sinha CLA 2015-04-28 01:54:53 EDT
Moving it to 4.6 for better testing participation.
Comment 15 Dani Megert CLA 2015-11-23 03:11:39 EST
(In reply to Sarika Sinha from comment #13)
> Cole, Do you plan to fix these comments in Mars time frame ?

Ping!
Comment 16 Cole Markham CLA 2016-03-11 19:37:55 EST
(In reply to Sarika Sinha from comment #12)
> Some review comments:
> From Code : Please add Copyright in new files and update the year for
> existing files.
> 
> From Test: 
> 1. If I have editor open in workspace and open the configuration from Run
> Configurations. I do some changes and Apply, there is no dirty sign in the
> launch configuration opened in the workspace editor. Save does get enabled.
> 2. If I have editor open in workspace and open the configuration from Run
> Configurations. I go to Common Tab and change "Save As" to Local File. file
> gets removed from Package Explorer but file remains opened in the editor
> window. I can save and it brings back the file in Package Explorer.

I updated the copyright headers and changed the listeners to handle 1 and 2.
Comment 17 Sarika Sinha CLA 2016-04-04 01:23:13 EDT
Thanks Cole, I will be looking into it.
Comment 18 Sarika Sinha CLA 2016-04-05 04:10:07 EDT
Thanks Cole,
I see one problem and that is missing error message for invalid inputs for the tabs in the editor.
Comment 19 Sarika Sinha CLA 2016-04-25 03:05:01 EDT
Moving to 4.7
Comment 20 Sarika Sinha CLA 2017-05-18 03:30:45 EDT
No work happening on this.
Comment 21 Michael Keppler CLA 2017-07-25 17:45:59 EDT
If possible, I would like to take over work on this change, since it fulfills a need I also have.

I've locally rebased and fixed some further exceptions related to invalid thread access from the listeners. However, I'm not clear about the policy of taking over "foreign" gerrit changes. Is it okay to submit a new patch set with the original author (if I'm even allowed by gerrit)?
Comment 22 Sarika Sinha CLA 2017-07-25 23:55:38 EDT
Yes, you can add him as co-author.