Skip to content

Commit bbe2875

Browse files
committed
Add documentation
1 parent 750dd0c commit bbe2875

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

README.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -412,7 +412,7 @@ the `call_silent()` method instead.
412412

413413
### Autocompletion
414414

415-
Cleo supports automatic (tab) completion in `bash`, `zsh` and `fish`.
415+
Cleo supports automatic (tab) completion in `bash`, `zsh`, `fish` and `PowerShell`.
416416

417417
By default, your application will have a `completions` command. To register these completions for your application, run one of the following in a terminal (replacing `[program]` with the command you use to run your application):
418418

@@ -433,4 +433,7 @@ echo "fpath+=~/.zfunc" >> ~/.zshrc
433433

434434
# Fish
435435
[program] completions fish > ~/.config/fish/completions/[program].fish
436+
437+
# PowerShell
438+
[program] completions PowerShell > $PROFILE
436439
```

src/cleo/commands/completions_command.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515

1616
class CompletionsCommand(Command):
17-
17+
1818
name = "completions"
1919
description = "Generate completion scripts for your shell."
2020

@@ -98,6 +98,13 @@ class CompletionsCommand(Command):
9898
9999
For the new completions to take affect.
100100
101+
<option=bold>PowerShell</>:
102+
103+
PowerShell profiles are stored at $PROFILE path, so you can simply \
104+
run command like this:
105+
106+
`<options=bold>{script_name} {command_name} PowerShell > $PROFILE</>`
107+
101108
<options=bold>CUSTOM LOCATIONS</>:
102109
103110
Alternatively, you could save these files to the place of your choosing, \

0 commit comments

Comments
 (0)