Hi,
I've been tearing my hair out trying to edit the default workspace for a new install. The problem is on Windows this requires escaping backslashes in "configuration:/.settings/org.eclipse.ui.ide.prefs". So I have a TextModification task with the following properties:
<setupTask
xsi:type="setup:TextModifyTask"
url="configuration:/.settings/org.eclipse.ui.ide.prefs">
<modification
pattern="(.*=[A-Z]\:)(?:(\\)([\w|-]+))+">
<substitution>\1</substitution>
<substitution>\2\\</substitution>
<substitution>\3</substitution>
</modification>
<description>Formats workspace path in RECENT_WORKSPACES</description>
</setupTask>
The file is:
RECENT_WORKSPACES=C:\Users\Sina-\Epsilon\epsilon-Interim\workspace
MAX_RECENT_WORKSPACES=5
RECENT_WORKSPACES_PROTOCOL=3
SHOW_RECENT_WORKSPACES=false
SHOW_WORKSPACE_SELECTION_DIALOG=false
eclipse.preferences.version=1
It's obvious what I'm trying to do: replace \ with \\. But I'm not smart enough to work this out. I've looked at the source code and I get what it's doing, but for something so simple as this, isn't there an easier way?!
Thanks.
[Updated on: Sat, 28 March 2020 11:04] by Moderator