-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement Import From Git option on Get Started page #15527
Comments
@beaumorley Hello, Could you please help us determinate how Import From Git workflow should be in Che Dashboard. But it also needed to keep in mind that Git repository can contain Devfile, like Che Repo has https://github.com/eclipse/che/blob/master/devfile.yaml. Then the dashboard should tell user that they are able to reuse Devfile from repo or use new one from samples. |
Sure. I am very familiar with that OpenShift screen. Will this Import from Git option be available from the Ready-To-Go Stack screen or just the new Import Dev File screen? I know that the existing Ready-To-Go Stack screen already has an import from Git option under Projects. So I will assume this is just for the Import Devfile screen for now. Here is a first stab at a simple mockup . I put the import from git first since you said the user may/may not need to add a dev file depending on their repo. Also, I am not sure what fields you need added to the form. If you let me know I can build on this. I would consider changing the name of the tabs for the two screen views:
Also, I am not sure I understand what the request is here: "... the dashboard should tell user that they are able to reuse Devfile from repo or use new one from samples." Are you thinking we need instructional text that lets the user know they only need to add a Devfile if they don't have one? Is there any way to detect whether there is one after the git import? If so we could ask for the devfile as a second step only when needed. I added some text in blue to the mockup above as a starting point. |
@beaumorley Sorry, but we cannot have this widget 'from Git' as is I think a popup which is called with the button 'Add project' could be better. The project can already contain a devfile. And it can be interesting for the user to create a new workspace for this project from another devfile(it can be one from the Ready-to-go stacks). As I understand in the case with import project 'from Git' we don't want to use an existing devfile. In the other case, we can import a devfile from the project repo. @akurinnoy, @sleshchenko, @slemeur WDYT? |
@beaumorley Hi! My thoughts about "Getting Started" page. |
@sleshchenko Hello! I see your point but "Getting Started" page should be as simple as possible that's why I don’t agree with
maybe, somewhere else, but not on this page |
@olexii4 Hi! Maybe I didn’t understand you correctly, but I seem that you mixed creating workspaces by importing already prepared devfiles and creating them from templates. Also, I don't see how your comment relates to "Getting Started” page. Authoring custom devfiles is rather an advanced usage of Che. Could you elaborate on this? |
@akurinnoy Yes. You are right. It is about 'Get Started' page.
And, as I wrote, it should be a popup. |
Another thing is that a template, which is a devfile under hood, consists of project(s), component(s) and commands bound together. Replacing existing project with another one may bring something unexpected, i.e. commands are not working, or workspace fails to start. So, my question is do we even need to implement "Import from Git" option on "Getting Started" page? |
How do you do Import from devfile stored in a Git repo? As I understand in general case you have to clone a git repo somewhere (where?) and take this devfile from sources beforehand, no? |
Currently, it's possible only with public repositories located by git providers that provide REST API to get files content, like GitHub.
You're right but we do not support it in general case. |
@sleshchenko I wonder, why not to make it more generic but instead of saying "Import from Git" (which is not truth) call it "Import from URL" (or so) and ask to provide a real URL where devfile lives instead? |
We would like to propose something like that. But also provide users an ability to use Git Repo link that does not contain devfile at all, it should allow users easy to start. So, our proposal is the following:
@gazarenkov WDYT? Maybe as an easier and more straightforward option, we could go without 2.2 and then if a user wants to start with the project without devfile - they should choose a template on Get Started page, and then replace manually its projects with their own. |
@sleshchenko
In each case it would be a good idea to let user preview the workspace's yaml/json. |
IMO the root issue here is the use case for e.g. taking our java-maven devfile and importing your own project. If one of the default templates supports the technologies we want to use, it shouldn't be hard to replace We currently have the already-mentioned issue about e.g. commands not working, but from what I recall the plan was to not hardcode commands, and it was just a workaround (see #13936 and the issue it depeneds on #13636). Alternatively, we could drop commands when the user specifies their own devfile (then the user flow is like opening a new folder in VS Code). |
Agree @amisevsk , this is the quite natural flow. Of course, user should do this some consciously and be ready to make some more modifications, e g unlikely any commands from a "sample" project can be guaranteed to work in a new project. |
Is your enhancement related to a problem? Please describe.
Implement Import From Git option on Get Started page.
Describe the solution you'd like
Describe alternatives you've considered
Additional context
The text was updated successfully, but these errors were encountered: