brunano21 / workspacemechanic

Automatically exported from code.google.com/p/workspacemechanic
0 stars 0 forks source link

Preference recorder does not work for multiline entries #58

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
1. Start recorder
2. Go to workspace preferences->validation
3. Change settings for JSP Content Validator by adding an exclude rule for 
folder target.
4. Stop the recorder

I will only list parts of the changes.
If I look manually at the settings in 
.metadata/.plugins/org.ecllipse.core.runtime/.settings/org.eclipse.wst.validatio
n.prefs I can see the following:
...
#Wed Jun 29 09:22:54 CEST 2011
override=true
USER_MANUAL_PREFERENCE=enabledManualValidatorListorg.eclipse.jst.j2ee.internal.v
alidation.UIApplicationClientValidator;org.eclipse.jst.j2ee.internal.jca.validat
ion.UIConnectorValidator;org.eclipse.jst.j2ee.internal.web.validation.UIWarValid
ator;org.eclipse.wst.wsi.ui.internal.WSIMessageValidator;org.eclipse.jst.j2ee.in
ternal.validation.UIEarValidator;org.eclipse.jst.j2ee.internal.classpathdep.Clas
spathDependencyValidator;org.eclipse.jst.j2ee.internal.ejb.workbench.validation.
UIEjbValidator;
vals/org.eclipse.jst.jsp.core.JSPBatchValidator/groups=0107include01113projectNa
ture131org.eclipse.jdt.core.javanature0107include110111contentType134org.eclipse
.jst.jsp.core.jspsourceT111contentType142org.eclipse.jst.jsp.core.jspfragmentsou
rceT111contentType134org.eclipse.jst.jsp.core.tagsourceT07fileext03jspF07fileext
04jspfF07fileext03jsfF07fileext03tagF07fileext04tagfF07fileext03jsvF07fileext04j
tplF0107exclude0104file06targetF01
suspend=false
stateTS=0
eclipse.preferences.version=1
vf.version=3
...

The preference recorder only records the following change:
/instance/org.eclipse.wst.validation/USER_MANUAL_PREFERENCE=enabledManualValidat
orListorg.eclipse.jst.j2ee.internal.validation.UIApplicationClientValidator;org.
eclipse.jst.j2ee.internal.jca.validation.UIConnectorValidator;org.eclipse.jst.j2
ee.internal.web.validation.UIWarValidator;org.eclipse.wst.wsi.ui.internal.WSIMes
sageValidator;org.eclipse.jst.j2ee.internal.validation.UIEarValidator;org.eclips
e.jst.j2ee.internal.classpathdep.ClasspathDependencyValidator;org.eclipse.jst.j2
ee.internal.ejb.workbench.validation.UIEjbValidator;
/instance/org.eclipse.wst.validation/USER_BUILD_PREFERENCE=enabledBuildValidator
Listorg.eclipse.jst.j2ee.internal.validation.UIApplicationClientValidator;org.ec
lipse.jst.j2ee.internal.jca.validation.UIConnectorValidator;org.eclipse.jst.j2ee
.internal.web.validation.UIWarValidator;org.eclipse.wst.wsi.ui.internal.WSIMessa
geValidator;org.eclipse.jst.j2ee.internal.validation.UIEarValidator;org.eclipse.
jst.j2ee.internal.classpathdep.ClasspathDependencyValidator;org.eclipse.jst.j2ee
.internal.ejb.workbench.validation.UIEjbValidator;

Maybe this is due to some multiline properties.
You can reproduce with Eclipse 3.7.0 and WTP 3.3.0

Original issue reported on code.google.com by konra...@gmx.de on 29 Jun 2011 at 7:38

GoogleCodeExporter commented 9 years ago
Arg... OK.

Original comment by konigsb...@gmail.com on 29 Jun 2011 at 12:52

GoogleCodeExporter commented 9 years ago
What happens when exporting the preferences via File > Export? Is the 
multi-lineness preserved?

Original comment by konigsb...@gmail.com on 14 Jul 2011 at 10:02

GoogleCodeExporter commented 9 years ago
Also, I'm having difficulty reading the two versions -- can you be more precise 
about what is missing please?

Original comment by konigsb...@gmail.com on 14 Jul 2011 at 10:03

GoogleCodeExporter commented 9 years ago
Sorry, my observation was not correct, the preference recorder simply does not 
detect the changes made for JSP Content Validator rules:

If I export the preferences from Eclipse I have (one!) line in the epf like:
/instance/org.eclipse.wst.validation/vals/org.eclipse.jst.jsp.core.JSPContentVal
idator/groups=0107include09111contentType134org.eclipse.jst.jsp.core.jspsourceT1
11contentType142org.eclipse.jst.jsp.core.jspfragmentsourceT07fileext03jspF07file
ext04jspfF07fileext03jsfF07fileext03tagF07fileext04tagfF07fileext03jsvF07fileext
04jtplF0107exclude0104file06targetF01

This basically contains all the inclusion and exclusion rules before running 
the validation (also the exclusion of the folder target).

If I try to record the changes with the preference recorder, it does not detect 
this change.

You can easily reproduce with the steps described above.

Original comment by konra...@gmx.de on 20 Jul 2011 at 8:03