https://github.com/rajyraman/power-platform-cli-completion
Add auto completions for Power Platform CLI when using PowerShell
https://github.com/rajyraman/power-platform-cli-completion
pac powerapps powerplatform
Last synced: 8 months ago
JSON representation
Add auto completions for Power Platform CLI when using PowerShell
- Host: GitHub
- URL: https://github.com/rajyraman/power-platform-cli-completion
- Owner: rajyraman
- License: mit
- Created: 2022-12-16T19:18:52.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-11-23T23:17:46.000Z (over 2 years ago)
- Last Synced: 2025-03-26T20:21:51.003Z (about 1 year ago)
- Topics: pac, powerapps, powerplatform
- Language: PowerShell
- Homepage:
- Size: 102 KB
- Stars: 8
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Power Platform CLI - Code Completion
Add Code Completion on Power Platform CLI using PowerShell. PAC [JSON](./PowerPlatformCLIAutoComplete/pac.doc.json) file is from pac release [1.29.6](https://www.nuget.org/packages/Microsoft.PowerApps.CLI/1.29.6) released on 14-Nov-2023.
# Installation
```powershell
Install-Module -Name PowerPlatformCLIAutoComplete; Import-Module -Name PowerPlatformCLIAutoComplete;
```
If you have organization restrictions for installing PowerShell modules globally, install it in the scope of the current user like below.
```powershell
Install-Module -Name PowerPlatformCLIAutoComplete -Scope CurrentUser; Import-Module -Name PowerPlatformCLIAutoComplete;
```
Once you have installed the module, add the `Import-Module` to your PowerShell profile. Open your profile in PowerShell by running the command below.
```
notepad $profile
```
Then add this line in the end to import the auto-complete module.
```powershell
Import-Module -Name PowerPlatformCLIAutoComplete
```
Below is a sample PowerShell profile that I use.
```powershell
Import-Module posh-git
Import-Module PSReadLine
Import-Module Terminal-Icons
Set-PSReadLineOption -PredictionSource HistoryAndPlugin
Set-PSReadLineOption -PredictionViewStyle ListView
Import-Module -Name PowerPlatformCLIAutoComplete
Import-Module F7History
oh-my-posh init pwsh --config "$env:POSH_THEMES_PATH/cloud-native-azure.omp.json" | Invoke-Expression
```
This will ensure that you will get auto-complete for Power Platform CLI everytime your start a new PowerShell terminal.