Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 351159 - Smart paste in pom editor
Summary: Smart paste in pom editor
Status: CLOSED INVALID
Alias: None
Product: z_Archived
Classification: Eclipse Foundation
Component: m2e (show other bugs)
Version: unspecified   Edit
Hardware: PC Mac OS X - Carbon (unsup.)
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-05 06:09 EDT by Pascal Rapicault CLA
Modified: 2021-04-19 13:23 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Pascal Rapicault CLA 2011-07-05 06:09:46 EDT
On a lot of webpage I can find snippets of XML explaining how to consume a library with Maven. It would be great if I could copy  those as is, paste them into the pom editor and have the editor take  care of putting them in the appropriate place in my XML.
Comment 1 Milos Kleint CLA 2011-07-18 06:12:03 EDT
I see the main problem with the feature in discoverability. I personally would not expect the editor to do it so I would always paste into the right position only.
are there other examples of similar behaviour in other eclipse (xml) editors? 

2 main cases: 
a. enclosing element(s) is missing in the file - wrap the pasted snipped into the enclosing ones on paste at current location or best guess location. Do we take caret position in file as context? eg. when in <profile> do we generate the <dependencies> section in the profile?
b. enclosing elements are present elsewhere - paste in the right location and jump to the new location with caret
Comment 2 Igor Fedorenko CLA 2013-09-28 23:50:52 EDT
closing old/stale bugreports
Comment 3 Denis Roy CLA 2021-04-19 13:23:41 EDT
Moved to https://github.com/eclipse-m2e/m2e-core/issues/