Skip to content

New GIF demo #4

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

Closed
matt9ucci opened this issue Oct 18, 2018 · 9 comments
Closed

New GIF demo #4

matt9ucci opened this issue Oct 18, 2018 · 9 comments

Comments

@matt9ucci
Copy link
Owner

matt9ucci commented Oct 18, 2018

Delete the current demo and create a new one.

Requirements

Mandatory

  • Use PowerShell Core, not ISE
  • Use docker as the name of docker cli
  • Show completion for management commands
  • Show completion for subcommands
  • Show completion for options
  • Show completion for command/option arguments

Optional

  • Use d as the alias of docker cli (in this case, add an another file like "demo-alias.gif")
  • Show "Tab" being pressed at least once to clarify how to trigger completion
  • Show "Ctrl + Space" being pressed at least once to clarify how to trigger completion as a list
@dima-matsola
Copy link

dima-matsola commented May 15, 2019

+1 for alias completion.

I suspect that I can achieve that creating ps1 file with content similar to completers.ps1 but having Register-Completer d ($managementCommands + $topLevelCommands) and than adding it as custom completion with -ArgumentList

Right?

Update: no I cant :)

@matt9ucci
Copy link
Owner Author

I suspect that I can achieve that creating ps1 file

You do not need to do that :)
Please check the issue #1

@dima-matsola
Copy link

oh, niiiice! thanks!

@NikoTurunen
Copy link

Any clue why this works only right after installation, but doesnt work anymore if I restart powershell?

@matt9ucci
Copy link
Owner Author

@NikoTurunen Did you run Import-Module DockerCompletion after restarting powershell?

@NikoTurunen
Copy link

@NikoTurunen Did you run Import-Module DockerCompletion after restarting powershell?

Actually I didnt. Think if I add this to profile.ps1 file, it should work automatically.

@matt9ucci
Copy link
Owner Author

@NikoTurunen Try to run Get-Module DockerCompletion after restarting powershell. The output will be:

PS> Get-Module DockerCompletion

ModuleType Version    Name                                ExportedCommands
---------- -------    ----                                ----------------
Script     1.1903.0.… DockerCompletion

If not, the DockerCompletion module is not imported in your current powershell session. Try to check your profile.ps1 file or run Import-Module DockerCompletion manually.

@NikoTurunen
Copy link

@NikoTurunen Try to run Get-Module DockerCompletion after restarting powershell. The output will be:

PS> Get-Module DockerCompletion

ModuleType Version    Name                                ExportedCommands
---------- -------    ----                                ----------------
Script     1.1903.0.… DockerCompletion

If not, the DockerCompletion module is not imported in your current powershell session. Try to check your profile.ps1 file or run Import-Module DockerCompletion manually.

Thank you for quick responses. I got it working now. I added :
Import-Module DockerCompletion
to my profile.ps1 file.

@dzmitry-lahoda
Copy link

please update to new slick and nice Windows Terminal OR WSL2 (better to do both - to make linux people to shit onto pwsh:) )

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

No branches or pull requests

4 participants