Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Oomph » Empty working sets created(Project files are not imported correctly)
Empty working sets created [message #1801724] Fri, 25 January 2019 10:06 Go to next message
Ralf Heydenreich is currently offline Ralf HeydenreichFriend
Messages: 235
Registered: July 2009
Senior Member
Hi all,
if I start my Oomph setup not all projects are imported and all defined Working Sets are empty. All git resources are available and can be located at my local file system. My Working Set definition is as follows (used only one for this example):

  <setupTask
      xsi:type="setup.workingsets:WorkingSetTask">
    <workingSet
        name="MyProject"
        id="org.myproject.workingset">
      <predicate
          xsi:type="predicates:OrPredicate">
        <operand
            xsi:type="predicates:NamePredicate"
            pattern="org\.myproject.*"/>
        <operand
            xsi:type="predicates:NamePredicate"
            pattern="org\.some\.other\.project.*"/>
      </predicate>
    </workingSet>
    <description>The dynamic working sets for ${scope.project.label}</description>
  </setupTask>


On my file system the directory structure is:
└── myproject
    └── MyProject-Parent
        ├── org.myproject.common
        └── org.some.other.project.api


How can I fill the Working Set with all the relevant projects?

Thanks in advance,
Ralf.
Re: Empty working sets created [message #1801728 is a reply to message #1801724] Fri, 25 January 2019 11:07 Go to previous messageGo to next message
Ed Merks is currently offline Ed MerksFriend
Messages: 33137
Registered: July 2009
Senior Member
Working sets don't import the projects. A targlet task or a projects import task is needed to import projects into the workspace; once they're the workspace the working sets can organize them. Note that there are useful predicates such as the Repository predicate where you can specify all projects in the same Git repository as some specific project... I need that for EMF for example, because many things start with org.eclipse.emf that aren't my projects...

Ed Merks
Professional Support: https://www.macromodeling.com/
Re: Empty working sets created [message #1801736 is a reply to message #1801728] Fri, 25 January 2019 12:15 Go to previous messageGo to next message
Ralf Heydenreich is currently offline Ralf HeydenreichFriend
Messages: 235
Registered: July 2009
Senior Member
Hi Ed,
thanks for your reply, this clarifies the things. Now, I have created a Targlet definition (inside a TargletTask):
    <targlet
        name="Workspace dependencies"
        includeBinaryEquivalents="false">
      <sourceLocator
          rootFolder="${git.clone.myproject.location}"
          locateNestedProjects="true"/>
    </targlet>


where project source files are checked out via a GitCloneTask before:

  <setupTask
      xsi:type="git:GitCloneTask"
      id="git.clone.myproject"
      remoteURI="https://bitbucket.org/something/myproject.git"
      checkoutBranch="develop"
      recursive="true">
    <description>${scope.project.label}</description>
  </setupTask>


But I assume the sourceLocator tag in my targlet definition is wrong. Could you please give me a hint how to write it in the correct way?

Regards,
Ralf.
Re: Empty working sets created [message #1801743 is a reply to message #1801736] Fri, 25 January 2019 13:55 Go to previous message
Ed Merks is currently offline Ed MerksFriend
Messages: 33137
Registered: July 2009
Senior Member
You can quite easily look at other examples using Navigate -> Open Setup -> Parent Models -> Catalog Index Eclipse and then look at then look in the Eclipse Projects. Ctrl-F can be used to search, though it's a little flaky something...

The problem is your targlet has no requirements that it needs satisfied. The magical wildcard requirement is ideal for that purpose:
<?xml version="1.0" encoding="UTF-8"?>
<p2:Requirement
    xmi:version="2.0"
    xmlns:xmi="http://www.omg.org/XMI"
    xmlns:p2="http://www.eclipse.org/oomph/p2/1.0"
    name="*"/>
It expands to require everything in the source locator.


Ed Merks
Professional Support: https://www.macromodeling.com/
Previous Topic:Problem getting oomph workspace
Next Topic:Custom setup task dependencies problem
Goto Forum:
  


Current Time: Fri Apr 19 18:58:25 GMT 2024

Powered by FUDForum. Page generated in 0.02868 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top