/powerplatform-alm:alm-setup [--minimal] [--with-cicd] [--with-pcf]from powerplatform-alm
Guides through Power Platform ALM setup — installs PAC CLI, configures authentication (interactive or service principal), and optionally sets up CI/CD pipelines and PCF development environments.
Ships in powerplatform-alm. Installing the plugin adds it to Claude Code.
Guide the user through setting up their Power Platform ALM tooling, authentication, and optional CI/CD and PCF development environments.
| Flag | Behavior |
|---|---|
--minimal | PAC CLI install + authentication only (steps 1-4, 9) |
--with-cicd | Include CI/CD pipeline setup (step 7) |
--with-pcf | Include PCF control development environment (step 8) |
| (no flags) | Full guided setup (all steps) |
Verify the following are installed and meet minimum versions:
node --version and confirm the major version is >= 18dotnet --version and confirm the major version is >= 6pwsh --version and confirm the major version is >= 7Report each as installed (with version) or missing. If Node.js is missing, warn that the preferred PAC CLI install method (npm) will not work. If .NET SDK is missing, warn that the dotnet fallback install method will not work. If both are missing, halt and ask the user to install at least one.
Install the PAC CLI using the best available method:
npm install -g @microsoft/powerplatform-clidotnet tool install --global Microsoft.PowerApps.CLI.ToolIf the PAC CLI is already installed, skip installation and move to verification.
Run pac --version and report the installed version. If the command fails, troubleshoot:
Ask the user which authentication method to use:
For local development with a user account:
pac auth create --environment {url}
Prompt for the environment URL (e.g., https://org12345.crm.dynamics.com). This opens a browser-based login flow.
For automated pipelines and non-interactive use:
pac auth create \
--applicationId {clientId} \
--clientSecret {secret} \
--tenant {tenantId} \
--environment {url}
Prompt the user for environment URLs for each deployment stage:
Store the values in a .env file in the project root:
PP_DEV_URL=https://orgdev.crm.dynamics.com
PP_TEST_URL=https://orgtest.crm.dynamics.com
PP_PROD_URL=https://orgprod.crm.dynamics.com
If a .env file already exists, merge the new values without overwriting unrelated entries.
Prompt the user for:
ContosoCore)contoso)Append to the .env file:
PP_SOLUTION_NAME=ContosoCore
PP_PUBLISHER_PREFIX=contoso
Skip this step if --minimal is passed. Only run if --with-cicd is passed or the user confirms during full setup.
Ask the user which CI/CD platform they use:
az --versionaz extension list --query "[?name=='azure-devops']"az extension add --name azure-devopsTENANT_ID — Azure AD tenant GUIDCLIENT_ID — App registration application IDCLIENT_SECRET — App registration secret valuegh CLI is available, offer to set secrets directly:
gh secret set TENANT_ID --body "{tenantId}"
gh secret set CLIENT_ID --body "{clientId}"
gh secret set CLIENT_SECRET --body "{secret}"
gh secret set PP_DEV_URL --body "{devUrl}"
gh secret set PP_TEST_URL --body "{testUrl}"
gh secret set PP_PROD_URL --body "{prodUrl}"
Skip this step if --minimal is passed. Only run if --with-pcf is passed or the user confirms during full setup.
npm install -g pcf-scripts pcf-start
npx tsc --version (or tsc --version if globally installed)npm install -g typescriptpac pcf init --namespace {publisherPrefix} --name {controlName} --template field --run-npm-install
Run pac org who to confirm the authenticated connection works. Report:
If the command fails, troubleshoot authentication issues and offer to re-run step 4.
Generate a Markdown report summarizing everything that was set up:
## Power Platform ALM Setup — Summary
| Item | Status |
|------|--------|
| PAC CLI version | v1.xx.x |
| Auth profile | [email protected] (interactive) |
| Dev environment | https://orgdev.crm.dynamics.com |
| Test environment | https://orgtest.crm.dynamics.com |
| Prod environment | https://orgprod.crm.dynamics.com |
| Solution | ContosoCore (prefix: contoso) |
| CI/CD | GitHub Actions configured |
| PCF tooling | Installed (TypeScript 5.x) |
Include any warnings or items that need follow-up (e.g., missing optional tools, environments not yet provisioned).
Files this command reads when invoked
What the command file sets; muted values are Claude Code's defaults
7-day visitors to each command page
npx claudepluginhub thelobbi/claude-m --plugin powerplatform-alm10 commands in this plugin
/alm-env-createCreate and configure a Power Platform environment with specified settings (type, region, language, currency, security group)./alm-env-listList Power Platform environments with status, URL, type, and capacity information./alm-envvar-setSet Power Platform environment variable values for a specific environment, or generate deployment settings files./alm-pcf-buildBuild a PCF control and optionally deploy it to a development environment or package it in a solution./alm-pcf-initScaffold a new PCF (PowerApps Component Framework) control from template — field, dataset, or React-based./alm-pipeline-generateGenerate CI/CD pipeline YAML for Azure DevOps or GitHub Actions to automate Power Platform solution deployment.Other plugins' commands for the same job