Created
December 11, 2024 20:23
-
-
Save turlockmike/3a177b8476289d4df259f2a9c30fdc4d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# EC Command Reference | |
Version: @extend/extend-cli/1.0.5 | |
## Core Commands | |
``` | |
ec help | |
- Display help for ec commands and topics | |
ec update [version] | |
- Update the CLI to the latest version | |
- Optional: Specify a specific version to update to | |
ec autocomplete | |
- Display autocomplete installation instructions | |
ec plugins | |
- List installed plugins | |
``` | |
## Development Commands | |
### Build Command | |
``` | |
ec build <glob> -t <target> [options] | |
Alias: ec b | |
Required parameters: | |
- glob: Pattern to specify files to build | |
- -t, --target: Target type (lambda or package) | |
Optional parameters: | |
- -b, --[no-]bundleDeps: Bundle node_modules | |
- -e, --externals: List of externals to exclude | |
- -f, --outfile: Output file | |
- -n, --node: Node version | |
- -o, --outdir: Output directory (default: dist) | |
- --installDeps: Install dependencies | |
- --tsconfig: Custom tsconfig path | |
- --withTypes: Include types | |
``` | |
### Branch and PR Commands | |
``` | |
ec branch [options] | |
Alias: ec br | |
Optional parameters: | |
- -d, --description: Description of the Jira issue (default: empty) | |
- -i, --issueNumber: Existing Jira issue number (default: creates new) | |
- -k, --projectKey: Jira Board project key (default: userConfig) | |
- -p, --prefix: Type of issue (default: feat) | |
- -s, --summary: Summary of the Jira issue | |
Example: | |
ec branch -i "DX-1234" -s "Feature summary" -d "Description" -p "feat" -k "PROJ" | |
ec pr | |
- Create PR automatically using current branch and commit info | |
ec pre-commit-checks | |
- Validate repository for branch naming and package.json placeholders | |
ec s / ec start | |
- Run commands defined in local user configuration | |
``` | |
## Service Management | |
### Service Commands | |
``` | |
ec service approve [options] | |
Aliases: ec service a, ec s approve, ec s a | |
Required flags: | |
- -s, --service: Service name to approve | |
Optional: | |
- -e, --env: Environment to append with service name | |
Example: | |
ec service approve --service my-service --env prod | |
ec service direct-deploy [options] | |
Aliases: ec service dd, ec s direct-deploy, ec s dd | |
Required flags: | |
- -v, --service: Service's name | |
Optional: | |
- -s, --skipLambdas: Skip lambda builds/uploads | |
Example: | |
ec service direct-deploy --service my-service --skip-lambdas | |
ec service deploy-sandbox [options] | |
Aliases: ec service ds, ec s deploy-sandbox, ec s ds | |
Required flags: | |
- -e, --env: Sandbox to deploy | |
- -s, --service: Service's name | |
Optional: | |
- -u, --skipLambdas: Skip lambda builds/uploads | |
Example: | |
ec service deploy-sandbox --service my-service --env sandbox-name --skip-lambdas | |
``` | |
### ProtoKit Commands | |
``` | |
ec protokit deploy [options] | |
Aliases: ec protokit d, ec pk deploy, ec pk d | |
Required flags: | |
- -a, --account: Account ID | |
Optional flags: | |
- -r, --alias: Repository alias | |
- -p, --approval: Require approval for IAM changes (always|never, default: never) | |
- -c, --buildConfig: Path to build config | |
- -d, --dryrun: Perform dry run | |
- -h, --hotswap: Enable hotswap fallback | |
- -l, --logs: Show Cloudwatch logs | |
- -m, --parameters: Include platform parameters | |
- -w, --watch: Watch for changes | |
- -b, --watchNoBuild: Watch without build script | |
Example: | |
ec protokit deploy --account 123456789012 --alias repo-alias | |
``` | |
### Environment Broker Commands | |
``` | |
ec environmentbroker environments | |
Commands: | |
- create, c: Create new environment | |
- list, l: List environments with query parameters | |
- update, u: Update environment status | |
ec environmentbroker jobs | |
Commands: | |
- cancel, c: Cancel jobs based on query parameters | |
- Uses dry run by default | |
- Use --force to actually cancel jobs | |
- list, l: List jobs based on query parameters | |
``` | |
## Configuration & Authentication | |
``` | |
ec config | |
Topics: | |
- user: Update EC configuration | |
Commands: | |
- l, list: List EC configuration | |
Optional flags: | |
- -f, --format: Format of output (json|text) | |
- -p, --profile: AWS profile | |
- -r, --region: AWS region | |
ec okta | |
- [DEPRECATED] Log in using Okta | |
``` | |
### AWS Integration | |
``` | |
ec aws assume [options] | |
Aliases: ec aws a, ec a assume, ec a a | |
Optional flags: | |
- -a, --accountId: AWS Account Id | |
- -n, --accountName: AWS Account Name | |
- --email: Email address | |
- -d, --noDefaults: Skip user config defaults | |
- --output: AWS CLI output format (default: json) | |
- --profile: AWS profile (default: default) | |
- --region: AWS Region | |
- -l, --roleName: Role Name | |
ec aws console [options] | |
Aliases: ec aws c, ec a console, ec a c | |
Optional flags: | |
- --environment: Extend environment | |
- --iic: Use IIC console | |
- -l, --link: Get console link instead of browser | |
- --profile: AWS profile (default: default) | |
ec aws code-artifact | |
Commands: | |
- l, login: Get CodeArtifact NPM auth token | |
ec aws creds | |
Commands: | |
- a, assume: Assume AWS role | |
- c, clear: Clear AWS config/credentials | |
- i, init: Initialize Hub/Spoke config | |
- l, login: Login to AWS Hub account | |
ec aws iic console [options] | |
Aliases: ec aws i c, ec a i c | |
Optional flags: | |
- -l, --link: Provide a link instead of opening in browser | |
``` | |
### Package Management | |
``` | |
ec pip | |
Commands: | |
- l, login: Setup pip.conf with AWS/CodeArtifact credentials | |
ec yarn | |
Commands: | |
- l, login: Configure yarn with AWS/CodeArtifact credentials | |
Topics: | |
- package: Copy package versions to destination repository | |
ec yarn package versions [options] | |
Aliases: ec y p v | |
Optional flags: | |
- -l, --limit: Limit the number of results (default: 100) | |
- --domain: CodeArtifact domain | |
- --domainOwner: Domain owner | |
- --format: Package format | |
- --namespace: Package namespace | |
- --packageName: Package name | |
- --profile: AWS profile | |
- --region: AWS region | |
- --repository: CodeArtifact repository (default: extend) | |
``` | |
## Repository Management | |
``` | |
ec repo | |
Commands: | |
- a, add: Add repository alias to local config | |
Required flags: | |
- -a, --alias: Repository alias | |
Optional flags: | |
- -l, --location: Repository location (uses current directory if not specified) | |
- code, d: Open repository in VS Code | |
Required flags: | |
- -a, --alias: Repository alias | |
- delete, d: Remove repository from local config | |
Required flags: | |
- -a, --alias: Repository alias | |
``` | |
## GitHub Operations | |
``` | |
ec gh search | |
Required flags: | |
- -f, --filename: Filename to restrict search to | |
- -s, --searchTerm: Search term to look for in code | |
- -t, --topic: Topic to search for in repositories | |
Optional: | |
- -o, --organization: GitHub organization name (default: helloextend) | |
ec gh files | |
- Command: stats | |
- Search for files across repositories with optional content comparison | |
ec gh packages | |
Commands: | |
- s: Search for specific package | |
- stats: Search for package with version in package.json files | |
ec gh repos | |
Commands: | |
- list: List all repositories with details | |
Optional flags: | |
- -a, --classify: Use OpenAI for repository classification | |
- -c, --csv: Output as CSV with optional filename | |
- -f, --fetch: Fetch live data instead of using cache | |
- -l, --limit: Maximum number of repositories (default: 500) | |
- -o, --organization: GitHub organization (default: helloextend) | |
- view: View details about a specific repository | |
Required: | |
- repository: Repository name to view | |
Optional flags: | |
- --classify: Use OpenAI to classify repository type | |
- --fetch: Fetch live data instead of using cache | |
- --org: GitHub organization (default: helloextend) | |
``` | |
## Feature Management | |
### Feature Flags (LaunchDarkly) | |
``` | |
ec featureflags get [options] | |
Aliases: ec featureflags g, ec ff get, ec ff g | |
Required flags: | |
- -e, --environment: LaunchDarkly environment | |
- -f, --flag: Feature flag key | |
- -j, --project: LaunchDarkly project | |
Optional: | |
- --query: Filter flags | |
``` | |
### Action Flags | |
``` | |
ec actionflags create [options] | |
Aliases: ec actionflags c, ec af create, ec af c | |
Required flags: | |
- -a, --customActionName: Custom action name | |
- -n, --pipelineName: Pipeline name | |
- -s, --pipelineStage: Pipeline stage | |
Optional: | |
- -m, --minutesToPause: Minutes to pause | |
- -p, --profile: AWS profile | |
- -r, --region: AWS region | |
ec actionflags get [options] | |
Aliases: ec actionflags g, ec af get, ec af g | |
Required flags: | |
- -a, --customActionName: Custom action name | |
- -n, --pipelineName: Pipeline name | |
- -s, --pipelineStage: Pipeline stage | |
``` | |
## Admin & Utilities | |
### Kafka Administration | |
``` | |
ec admin kafka-consumer-state-change [options] | |
Aliases: ec admin-plane consumer-state, ec ap c | |
Required flags: | |
- -e, --environment: Target environment | |
- -s, --newState: Enable or Disable consumer | |
Optional: | |
- -h, --host: Target host | |
- -i, --interactive: Use interactive mode | |
- -l, --lambdaFxName: Target lambda function | |
- -p, --profile: AWS profile | |
- -r, --region: AWS region (default: us-east-1) | |
ec admin kafka-set-offset [options] | |
Aliases: ec admin-plane set-kafka-offset, ec ap o | |
Required flags: | |
- -o, --byTimestamp: ISO Timestamp for offset | |
- -e, --environment: Target environment | |
- -t, --topic: Kafka topic | |
Optional: | |
- -h, --host: Target host | |
- -i, --interactive: Use interactive mode | |
- -l, --lambdaFxName: Target lambda function | |
- -p, --profile: AWS profile | |
- -r, --region: AWS region (default: us-east-1) | |
``` | |
### Local Development Tools | |
``` | |
ec local dynamodb | |
Topics: | |
- database: Open database console | |
- table: Backup a table | |
ec local server | |
Commands: | |
- start: Start local lambda server | |
ec local mock | |
- Proxy command for @mockoon/cli | |
``` | |
### Utility Functions | |
``` | |
ec utilities generate-secret [options] | |
Aliases: ec utilities gs, ec utils gs, ec u gs | |
Optional flags: | |
- -b, --bytes: Number of bytes for secret (default: 48) | |
- -h, --help: Show CLI help | |
``` | |
## Notes | |
- Run any command with `--help` for detailed parameter information | |
- Many commands have shorthand aliases (e.g., `b` → `build`) | |
- Version 1.0.5 features may vary by platform | |
- Some commands require specific AWS or service permissions | |
- The `okta` command is deprecated |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment