Che: Duplicate directory specifying multiple projects in a devfile.

Created on 6 Jan 2020  路  8Comments  路  Source: eclipse/che

Is there a way with a multi-project devfile to not duplicate the root of a project already defined in source control?

Gitlab / github
image

devfile ( it's a bit of a mess, but I'm trying different things)

projects:
  - name: parent
    source:
      location: 'https://gitlab.example.com/User/project.git'
      type: git
      sparseCheckoutDir: /parent/
    clonePath: projects
  - name: config-service
    source:
      location: 'https://gitlab.example.com/User/project.git'
      type: git
      sparseCheckoutDir: /config-service/
    clonePath: ''
  - name: gateway-service
    source:
      location: 'https://gitlab.example.com/User/project.git'
      type: git
      sparseCheckoutDir: /gateway-service/
    clonePath: projects
  - name: discovery-service
    source:
      location: 'https://gitlab.example.com/User/project.git'
      type: git
      sparseCheckoutDir: /discovery-service*

Workspace RESULT: Duplicated project root directory when using sparseCheckoutDir to add a project in source control.
image

che version 7.6.0

areplugins kinbug severitP2

All 8 comments

@Mbd06b that looks like a bug. Can you please help me to organize the test repository and test devfile to make sure we are talking about the same thing.

@skabashnyuk
here's a remote of the actual repository... (notice the project directories at the root)
https://github.com/Mbd06b/bright

here's the devfile
https://github.com/Mbd06b/bright/blob/master/devfile.yaml

Above is the screenshot of what results in the Theia worskpace, directory paths...
projects/config-service/config-service/src
projects/discovery-service/discovery-service/src
...

Here are some related issues where I think this feature was added.
Discussion: https://github.com/eclipse/che/issues/13671
Feature Merge: https://github.com/eclipse/che/pull/14823

@mmorhun maybe you can weigh in here and determine if this is a bug or just me?

@Mbd06b I've just tried your devfile, it's indeed a bug. Thank you for reporting.

Issues go stale after 180 days of inactivity. lifecycle/stale issues rot after an additional 7 days of inactivity and eventually close.

Mark the issue as fresh with /remove-lifecycle stale in a new comment.

If this issue is safe to close now please do so.

Moderators: Add lifecycle/frozen label to avoid stale mode.

Issues go stale after 180 days of inactivity. lifecycle/stale issues rot after an additional 7 days of inactivity and eventually close.

Mark the issue as fresh with /remove-lifecycle stale in a new comment.

If this issue is safe to close now please do so.

Moderators: Add lifecycle/frozen label to avoid stale mode.

/remove-lifecycle stale

I need to re-test this to see if it still happening.

This issue is really important for eclipse-che to ease microservice development for teams with a mono-repo.

I've updated area to plugins as it's related to Che Theia Workspace Plugin
cc @ericwill

Would https://github.com/eclipse/che/issues/15347 work as a fix to that one?
It looks like we want to clone only once here, but display specific subfolders

This epic looks to be related to this issue. #15529

Was this page helpful?
0 / 5 - 0 ratings