@gpc-cli/core 0.1.0 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +74 -0
- package/package.json +8 -5
package/README.md
ADDED
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
# @gpc-cli/core
|
|
2
|
+
|
|
3
|
+
Business logic and command orchestration for GPC. Contains all command implementations, validation, output formatting, and plugin management.
|
|
4
|
+
|
|
5
|
+
## Install
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
npm install @gpc-cli/core
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
```typescript
|
|
14
|
+
import {
|
|
15
|
+
uploadRelease,
|
|
16
|
+
promoteRelease,
|
|
17
|
+
getVitalsOverview,
|
|
18
|
+
listReviews,
|
|
19
|
+
formatOutput,
|
|
20
|
+
} from "@gpc-cli/core";
|
|
21
|
+
|
|
22
|
+
// Upload a release
|
|
23
|
+
const result = await uploadRelease(context, {
|
|
24
|
+
file: "app.aab",
|
|
25
|
+
track: "internal",
|
|
26
|
+
});
|
|
27
|
+
|
|
28
|
+
// Promote between tracks
|
|
29
|
+
await promoteRelease(context, {
|
|
30
|
+
from: "internal",
|
|
31
|
+
to: "production",
|
|
32
|
+
rollout: 0.1,
|
|
33
|
+
});
|
|
34
|
+
|
|
35
|
+
// Check vitals
|
|
36
|
+
const vitals = await getVitalsOverview(context);
|
|
37
|
+
|
|
38
|
+
// Format output
|
|
39
|
+
console.log(formatOutput(vitals, "table"));
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
## Command Groups
|
|
43
|
+
|
|
44
|
+
| Group | Functions |
|
|
45
|
+
|-------|-----------|
|
|
46
|
+
| **Releases** | `uploadRelease`, `promoteRelease`, `updateRollout`, `getReleasesStatus`, `listTracks` |
|
|
47
|
+
| **Listings** | `getListings`, `updateListing`, `pullListings`, `pushListings`, `diffListings` |
|
|
48
|
+
| **Images** | `listImages`, `uploadImage`, `deleteImage` |
|
|
49
|
+
| **Reviews** | `listReviews`, `getReview`, `replyToReview`, `exportReviews` |
|
|
50
|
+
| **Vitals** | `getVitalsOverview`, `getVitalsCrashes`, `getVitalsAnr`, `getVitalsStartup`, `compareVitalsTrend`, `checkThreshold` |
|
|
51
|
+
| **Subscriptions** | `listSubscriptions`, `createSubscription`, `updateSubscription`, `deleteSubscription`, `listOffers`, `createOffer` |
|
|
52
|
+
| **IAP** | `listInAppProducts`, `createInAppProduct`, `syncInAppProducts` |
|
|
53
|
+
| **Purchases** | `getProductPurchase`, `acknowledgeProductPurchase`, `refundOrder` |
|
|
54
|
+
| **Reports** | `listReports`, `downloadReport` |
|
|
55
|
+
| **Users** | `listUsers`, `inviteUser`, `updateUser`, `removeUser` |
|
|
56
|
+
| **Testers** | `listTesters`, `addTesters`, `removeTesters`, `importTestersFromCsv` |
|
|
57
|
+
| **Publishing** | `publish` (end-to-end: upload + track + notes + commit) |
|
|
58
|
+
| **Validation** | `validateUploadFile`, `validateImage`, `validatePreSubmission` |
|
|
59
|
+
|
|
60
|
+
## Utilities
|
|
61
|
+
|
|
62
|
+
- **Output formatting** — `formatOutput()`, `detectOutputFormat()`, `redactSensitive()`
|
|
63
|
+
- **Error hierarchy** — `GpcError`, `ConfigError`, `ApiError`, `NetworkError` with exit codes
|
|
64
|
+
- **Audit logging** — `initAudit()`, `writeAuditLog()` for write operation tracking
|
|
65
|
+
- **Path safety** — `safePath()`, `safePathWithin()` for path traversal prevention
|
|
66
|
+
- **Plugin management** — `PluginManager`, `discoverPlugins()`, `scaffoldPlugin()`
|
|
67
|
+
|
|
68
|
+
## Part of the GPC Monorepo
|
|
69
|
+
|
|
70
|
+
This is the core logic layer for [GPC](https://github.com/yasserstudio/gpc). The CLI calls into core; core calls into api, auth, and config.
|
|
71
|
+
|
|
72
|
+
## License
|
|
73
|
+
|
|
74
|
+
MIT
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@gpc-cli/core",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"description": "Business logic and command orchestration for GPC",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|
|
@@ -15,16 +15,19 @@
|
|
|
15
15
|
"dist"
|
|
16
16
|
],
|
|
17
17
|
"dependencies": {
|
|
18
|
-
"@gpc-cli/api": "1.0.
|
|
19
|
-
"@gpc-cli/auth": "0.1.
|
|
20
|
-
"@gpc-cli/config": "0.1.
|
|
21
|
-
"@gpc-cli/plugin-sdk": "0.1.
|
|
18
|
+
"@gpc-cli/api": "1.0.2",
|
|
19
|
+
"@gpc-cli/auth": "0.1.2",
|
|
20
|
+
"@gpc-cli/config": "0.1.2",
|
|
21
|
+
"@gpc-cli/plugin-sdk": "0.1.2"
|
|
22
22
|
},
|
|
23
23
|
"keywords": [
|
|
24
24
|
"google-play",
|
|
25
25
|
"core"
|
|
26
26
|
],
|
|
27
27
|
"license": "MIT",
|
|
28
|
+
"publishConfig": {
|
|
29
|
+
"access": "public"
|
|
30
|
+
},
|
|
28
31
|
"devDependencies": {
|
|
29
32
|
"@types/node": "^25.3.5"
|
|
30
33
|
},
|