@pmate/cli
v0.6.12
Published
CLI utilities for the pMate project
Readme
pMate CLI
A TypeScript-powered command-line tool scaffold for future pMate automation.
Development
npm install
npm run dev -- --helpnpm run devexecutes the TypeScript entry point withts-node.npm run buildemits compiled JavaScript intodist/.npm startruns the compiled CLI (dist/index.js).
Usage
After running npm run build, you can invoke the CLI locally via:
node dist/index.js --name AliceWhen published or linked (e.g., npm link), the binary will be available as pmate:
pmate --help
pmate --name Bob
pmate add-dns --type A --value 1.2.3.4 --rr api
pmate login
pmate sts
pmate oss list
pmate oss upload --file ./path/to/file --key assets/file.txt
pmate pr
pmate commit
pmate commit --push
pmate pr merge
pmate linear update ENG-123 --title "Updated title"
pmate linear update ENG-123 --desc $'line1\nline2'
pmate notion view <page-id-or-url>
pmate notion create --parent <page-id-or-url> --title "Sprint Notes" --content "Initial notes"
pmate notion create --private --title "Private Notes" --file ./notes.md
pmate notion update <page-id-or-url> --file ./notes.md --appendNotes:
pmate prnormalizes generated PR titles to start withfeat:,fix:, orchore:(exactly one space after:).pmate commitcreates an AI-generated commit from local changes.pmate commit --pushalso pushes the current branch to origin.pmate pr mergeuses squash merge and deletes the branch by default (--squash --delete-branch).
Aliyun credentials config
You can set Aliyun credentials in ~/.pmate/config.yaml:
aliyun:
ak: your_ak
sk: your_sk
region: cn-hangzhou
domain: example.comLinear config
Add one or more Linear accounts to ~/.pmate/config.yaml:
linear:
teamKey: ENG
accounts:
- title: work
apiKey: your_linear_api_key
- title: personal
apiKey: your_other_linear_api_keyWhen multiple accounts exist, pmate linear will ask you to choose once per working directory and cache it in ~/.pmate/linear-selection.json.
Auth session
pmate login stores a session token in ~/.pmate/session.json. Commands like
pmate sts require this session; if it is missing, log in first.
Notion config
Add a Notion integration token to ~/.pmate/config.yaml:
notion:
token: your_notion_integration_token