Skip to content
This repository has been archived by the owner on Apr 4, 2023. It is now read-only.

Display by default only containers defined with recipe source. #49

Merged
merged 5 commits into from
Feb 18, 2019

Conversation

AndrienkoAleksandr
Copy link
Contributor

@AndrienkoAleksandr AndrienkoAleksandr commented Feb 4, 2019

Display only containers defined by user(recipe source attribute). Simplify a bit code. In case if user want to create new terminal for tool container - user should use 'New terminal for specific container' command and type Ctrl + ` shortcut.

Referenced issue:

Minimal set terminal improvements

forflorent

Signed-off-by: Oleksandr Andriienko oandriie@redhat.com

Signed-off-by: Oleksandr Andriienko <oandriie@redhat.com>
@benoitf
Copy link
Contributor

benoitf commented Feb 5, 2019

@AndrienkoAleksandr so it means user don't see anymore theia-ide terminal for example ?
I think it's an issue right now as AFAIK, to get code completion user need to launch yarn in this container

@AndrienkoAleksandr
Copy link
Contributor Author

@AndrienkoAleksandr so it means user don't see anymore theia-ide terminal for example ?

Yes, you understood correctly.

I think it's an issue right now as AFAIK, to get code completion user need to launch yarn in this container

@benoitf I could apply temporary workaround to display theia container. Is it OK for you?

@benoitf
Copy link
Contributor

benoitf commented Feb 6, 2019

@AndrienkoAleksandr
is there a flag that we can add on the workspace config if we want to be able to connect to all containers of the workspace ?

or like hitting a special key before clicking on the menu (like macos key CMD on some macOS menus)

@AndrienkoAleksandr
Copy link
Contributor Author

AndrienkoAleksandr commented Feb 6, 2019

@benoitf

or like hitting a special key before clicking on the menu (like macos key CMD on some macOS menus)

I am not sure that command palette has such feature.

@AndrienkoAleksandr
is there a flag that we can add on the workspace config if we want to be able to connect to all containers of the workspace ?

I guess we could save some flags to the workspace attributes. But I talked with @garagatyi about filtering terminal containers. There some tool containers, which should be always hidden, it is no make sense to show them for users. So "all containers" looks not very good for me. @garagatyi , What do you think?

@azatsarynnyy
Copy link
Member

I am not sure that command palette has such feature.

@AndrienkoAleksandr the Quick Open API doesn't provide it but such behavior can be implemented in a particular implementation - treminal-quick-open. You can look at how it's implemented for Go to File. When quick open widget is opened and Ctrl+P has been pressed again then quick open list is updated with the hidden files included.

@azatsarynnyy
Copy link
Member

@AndrienkoAleksandr I've found that the Quick Open API actually allows to set hidden attr for list items. I've never used it but I guess it might help
https://github.com/theia-ide/theia/blob/master/packages/core/src/browser/quick-open/quick-open-model.ts#L39

@azatsarynnyy
Copy link
Member

I agree that we shouldn't completelly dissalow user to open a terminal into tooling container. For example Che k8s Plugin provides kubectl tool in its container. And user should be able to use it.

@AndrienkoAleksandr
Copy link
Contributor Author

I see that commands could be not visible, we could try to use this ability too:

https://github.com/theia-ide/theia/blob/master/packages/core/src/common/command.ts#L86

@garagatyi
Copy link

@AndrienkoAleksandr overall I like double CTRL+P solution. We could add additional filtering by introducing some new label, like no-terminal-access

@garagatyi
Copy link

But it doesn't have to go into this PR

…ainer command. Fix terminal creation for container plugin.

Signed-off-by: Oleksandr Andriienko <oandriie@redhat.com>
Signed-off-by: Oleksandr Andriienko <oandriie@redhat.com>
@AndrienkoAleksandr AndrienkoAleksandr changed the title Display only containers defined with recipe source. Display by default only containers defined with recipe source. Feb 17, 2019
@AndrienkoAleksandr
Copy link
Contributor Author

@benoitf I handled your feedback about ability create new terminal for tool containers. Take a look screen shot, please. Is it OK for you?

@AndrienkoAleksandr AndrienkoAleksandr merged commit 38ffd96 into master Feb 18, 2019
@AndrienkoAleksandr AndrienkoAleksandr deleted the filterContainers branch February 18, 2019 15:14
@benoitf
Copy link
Contributor

benoitf commented Feb 18, 2019

@AndrienkoAleksandr very nice !

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants