Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,8 @@ yarn-error.log*
*.tsbuildinfo
next-env.d.ts

# coverage
/coverage

# local docs
/docs
1 change: 1 addition & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ This file provides guidance to AI agents when working with code in this reposito
pnpm build # Build CLI with tsup (output: dist/)
pnpm dev # Run CLI from source via tsx (e.g. pnpm dev -- members list)
pnpm test # Run all tests with vitest
pnpm test:coverage # Run tests with v8 coverage reporting
pnpm check # Lint and format check (Biome via ultracite)
pnpm fix # Auto-fix lint and format issues
pnpm type-check # TypeScript type checking without emit
Expand Down
12 changes: 8 additions & 4 deletions ARCHITECTURE.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

> **Project**: Memberstack CLI
> **Repository**: https://github.com/Flash-Brew-Digital/memberstack-cli
> **Last updated**: 2026-02-17
> **Last updated**: 2026-02-22

## Overview

Expand Down Expand Up @@ -57,16 +57,20 @@ memberstack-cli/
│ │
│ └── core/ # Core library tests
│ ├── auth.test.ts
│ ├── csv.test.ts
│ ├── graphql-client.test.ts
│ ├── index.test.ts
│ ├── no-color.test.ts
│ ├── oauth.test.ts
│ ├── program.test.ts
│ ├── program-options.test.ts
│ ├── quiet.test.ts
│ ├── token-storage.test.ts
│ └── utils.test.ts
├── dist/ # Compiled output (ESM)
├── tsup.config.ts # Bundler config (esbuild via tsup)
├── vitest.config.ts # Test config (mockReset, restoreMocks)
├── vitest.config.ts # Test config (mockReset, restoreMocks, v8 coverage)
├── biome.jsonc # Linter/formatter (Biome via Ultracite)
└── package.json # Node >=20, pnpm, type: module
```
Expand Down Expand Up @@ -168,12 +172,12 @@ All user-facing output (tables, spinners, messages) goes to **stderr**. JSON out
| `open` | Opens browser for OAuth login |
| `papaparse` | CSV parsing and generation |

Dev: `tsup` (bundler), `tsx` (dev runner), `typescript`, `vitest` (tests), `biome` via `ultracite` (lint/format).
Dev: `tsup` (bundler), `tsx` (dev runner), `typescript`, `vitest` (tests), `@vitest/coverage-v8` (coverage), `biome` via `ultracite` (lint/format).

## Build & CI

- **Build**: `tsup` compiles `src/index.ts` to ESM in `dist/`
- **Test**: `vitest` with mocked GraphQL client and spinner, covers all commands and core libraries
- **Test**: `vitest` with mocked GraphQL client and spinner, covers all commands and core libraries (`pnpm test:coverage` for v8 coverage report)
- **Lint**: Biome via `ultracite` (`pnpm check` / `pnpm fix`)
- **Type check**: `tsc --noEmit` (`pnpm type-check`)
- **PR checks** (`.github/workflows/pr-checks.yml`): type-check, lint, build, test on Node 24
Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@
"build": "tsup",
"dev": "tsx src/index.ts",
"test": "vitest run",
"test:coverage": "vitest run --coverage",
"type-check": "tsc --noEmit",
"check": "ultracite check",
"fix": "ultracite fix",
Expand All @@ -69,6 +70,7 @@
"@biomejs/biome": "2.4.2",
"@types/node": "^25.2.3",
"@types/papaparse": "^5.5.2",
"@vitest/coverage-v8": "^4.0.18",
"lint-staged": "^16.2.7",
"tsup": "^8.5.1",
"tsx": "^4.21.0",
Expand Down
144 changes: 144 additions & 0 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading