Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
d772c53
feat(e2e): run e2e tests on DeviceCloud devices with @devicecloud.dev…
finalerock44 Nov 23, 2026
46e0290
chore: merge production into dev after 5.15.0 (#345)
dcd-release-please[bot] Nov 23, 2026
64f0942
deps: bump the minor-and-patch group with 3 updates (#348)
dependabot[bot] Nov 23, 2026
92ce854
chore: bump eslint-plugin-unicorn from 79.0.0 to 80.0.0 (#349)
dependabot[bot] Nov 23, 2026
ca07b49
chore(deps): drop audit ignores that no longer match anything (#350)
finalerock44 Nov 23, 2026
b5706d8
chore: drop unused eslint disables (#351)
finalerock44 Nov 23, 2026
2e2377b
refactor: replace chalk with node:util styleText (#352)
finalerock44 Nov 23, 2026
bb273f0
fix: keep chalk's colour output in nested and multi-line text (#353)
finalerock44 Nov 23, 2026
9d9adc2
fix(artifacts): save into a folder given as the artifacts path, and d…
finalerock44 Nov 23, 2026
ba43df4
feat(e2e): set the device's locale from the e2e provider (#355)
finalerock44 Nov 23, 2026
c3e0fdf
fix(device): drop iOS 17 from the help text (#356)
finalerock44 Nov 24, 2026
03c01df
fix(download): show a manifest 400/403/404 instead of re-requesting t…
finalerock44 Nov 24, 2026
edf10a7
fix(upload): send resumable uploads to the configured Supabase URL (#…
riglar Nov 24, 2026
e03a78e
fix(upload): send Storage uploads with fetch in the standalone binary…
riglar Nov 24, 2026
00b2807
feat(upload): upload straight to the final storage path with a signed…
riglar Nov 24, 2026
161c428
fix(upload): refresh the upload token when Storage reports it expired…
riglar Nov 24, 2026
924181e
feat(e2e): link each test's video to its part of the session recordin…
finalerock44 Nov 25, 2026
b3dcd8f
chore: merge production into the 5.16.0 release
dcd-release-please[bot] Nov 25, 2026
57497a6
chore: release 5.16.0
dcd-release-please[bot] Nov 25, 2026
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
31 changes: 31 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,36 @@
# Changelog

## [5.16.0](https://github.com/devicecloud-dev/dcd-cli/compare/v5.15.0...v5.16.0) (2026-11-25)


### Features

* **e2e:** link each test's video to its part of the session recording ([#362](https://github.com/devicecloud-dev/dcd-cli/issues/362)) ([924181e](https://github.com/devicecloud-dev/dcd-cli/commit/924181effca63f04bb7e16542988f862916560d6))
* **e2e:** run e2e tests on DeviceCloud devices with @devicecloud.dev/dcd/e2e ([#346](https://github.com/devicecloud-dev/dcd-cli/issues/346)) ([d772c53](https://github.com/devicecloud-dev/dcd-cli/commit/d772c533bf56165292e30420a0598f21469af86a))
* **e2e:** set the device's locale from the e2e provider ([#355](https://github.com/devicecloud-dev/dcd-cli/issues/355)) ([ba43df4](https://github.com/devicecloud-dev/dcd-cli/commit/ba43df49e655d54f3e78fab9d6ce853213c7d0e7))
* **upload:** upload straight to the final storage path with a signed token ([#360](https://github.com/devicecloud-dev/dcd-cli/issues/360)) ([00b2807](https://github.com/devicecloud-dev/dcd-cli/commit/00b2807f59138737fb00a112d088d4c96a884fe2))


### Bug Fixes

* keep chalk's colour output in nested and multi-line text ([#353](https://github.com/devicecloud-dev/dcd-cli/issues/353)) ([bb273f0](https://github.com/devicecloud-dev/dcd-cli/commit/bb273f0f88d5cc7bc9d123f5e7eda50103df1993))
* **artifacts:** save into a folder given as the artifacts path, and d… ([#354](https://github.com/devicecloud-dev/dcd-cli/issues/354)) ([9d9adc2](https://github.com/devicecloud-dev/dcd-cli/commit/9d9adc2065c9787399422651e5cfb57740b186b9))
* **device:** drop iOS 17 from the help text ([#356](https://github.com/devicecloud-dev/dcd-cli/issues/356)) ([c3e0fdf](https://github.com/devicecloud-dev/dcd-cli/commit/c3e0fdfc49ffb73a9ee49e041ef6d929968d1f86))
* **download:** show a manifest 400/403/404 instead of re-requesting the inline route ([#357](https://github.com/devicecloud-dev/dcd-cli/issues/357)) ([03c01df](https://github.com/devicecloud-dev/dcd-cli/commit/03c01dfc256081aede92d8250f1f2f398465250a))
* **upload:** refresh the upload token when Storage reports it expired ([#361](https://github.com/devicecloud-dev/dcd-cli/issues/361)) ([161c428](https://github.com/devicecloud-dev/dcd-cli/commit/161c4284af227d119439ffe92420c387f11b2e1d))
* **upload:** send resumable uploads to the configured Supabase URL ([#358](https://github.com/devicecloud-dev/dcd-cli/issues/358)) ([edf10a7](https://github.com/devicecloud-dev/dcd-cli/commit/edf10a7e9d46dcd50660188da8c4c02f00a8bfcf))
* **upload:** send Storage uploads with fetch in the standalone binary ([#359](https://github.com/devicecloud-dev/dcd-cli/issues/359)) ([e03a78e](https://github.com/devicecloud-dev/dcd-cli/commit/e03a78ed4cdf25eeeb074d667b3b418646715019))


### Dependencies

* bump the minor-and-patch group with 3 updates ([#348](https://github.com/devicecloud-dev/dcd-cli/issues/348)) ([64f0942](https://github.com/devicecloud-dev/dcd-cli/commit/64f0942ab1244656aabec30785ca3ef30d04969e))


### Code Refactoring

* replace chalk with node:util styleText ([#352](https://github.com/devicecloud-dev/dcd-cli/issues/352)) ([2e2377b](https://github.com/devicecloud-dev/dcd-cli/commit/2e2377bfd357bdebfd7a69beb7122d65e8af4818))

## [5.15.0](https://github.com/devicecloud-dev/dcd-cli/compare/v5.14.1...v5.15.0) (2026-11-19)


Expand Down
2 changes: 1 addition & 1 deletion CLAUDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
- `pnpm build` — clean, compile TypeScript to `dist/`, and `chmod +x dist/index.js dist/mcp/index.js` so both published binaries are directly executable.
- `pnpm build:binaries` — `scripts/build-binaries.mjs` produces the bun-compiled, self-contained `dcd-<platform>-<arch>` binaries published to GitHub Releases (the install `dcd upgrade` self-updates). The platform/arch keys must stay in sync with `ASSET_BY_PLATFORM` in `src/commands/upgrade.ts`.
- `pnpm lint` — ESLint over `src/` and `test/`.
- `pnpm typecheck` — `tsc --noEmit -p tsconfig.test.json` over `src/` and `test/` (strict mode; `pnpm build` only compiles `src/`). Requires Node `>=22`.
- `pnpm typecheck` — `tsc --noEmit -p tsconfig.test.json` over `src/` and `test/` (strict mode; `pnpm build` only compiles `src/`). Requires Node `>=22.8`.
- `pnpm test` — runs `scripts/test-runner.mjs`: builds the CLI, boots the mock API if one is available, then runs mocha. TypeScript is loaded by **tsx** (`.mocharc.json`'s `node-option: ["import=tsx"]`), *not* ts-node — Mocha 11 imports specs as ESM, which bypasses the `require: ts-node/register` hook. The runner isolates `DCD_CONFIG_DIR` to a temp dir so tests never touch your real `dcd login` session.
- `pnpm test:unit` — the same runner with `--unit`: unit specs only, no mock API. **This is what CI runs.**
- Tests split into `test/unit/*` (pure, no backend) and `test/integration/*` (drive the built CLI against a Prism mock of the dcd API on port 3001).
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ is a one-time step. PRs cannot be merged until the CLA check is green.

## Getting started

You need **Node.js 22+** and **[pnpm](https://pnpm.io)** (`packageManager` pins
You need **Node.js 22.8+** and **[pnpm](https://pnpm.io)** (`packageManager` pins
the exact version; [Corepack](https://nodejs.org/api/corepack.html) will pick it
up automatically).

Expand Down
29 changes: 26 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ On Windows:
irm https://get.devicecloud.dev/install.ps1 | iex
```

Or via npm if you already have Node 22+:
Or via npm if you already have Node 22.8+:

```sh-session
$ npm install -g @devicecloud.dev/dcd
Expand Down Expand Up @@ -105,7 +105,7 @@ $ claude mcp add --scope user devicecloud -- dcd mcp
$ codex mcp add devicecloud -- dcd mcp
```

If you use the npm package instead of the standalone binary, the command is `npx` with `"args": ["-y", "@devicecloud.dev/dcd", "mcp"]`. That needs Node 22 or newer on the app's PATH, and it checks npm each time it starts.
If you use the npm package instead of the standalone binary, the command is `npx` with `"args": ["-y", "@devicecloud.dev/dcd", "mcp"]`. That needs Node 22.8 or newer on the app's PATH, and it checks npm each time it starts.

It signs in the same way as the CLI: with your `dcd login` session, which it renews as it runs, or with `DEVICE_CLOUD_API_KEY`. Point it at a non-prod environment with `DCD_API_URL` (https, or plain http to `localhost` only).

Expand Down Expand Up @@ -144,10 +144,33 @@ The npm package also ships `dcd-mcp`, an older server with the same `dcd_*` tool

`--package` matters: the package's default bin is `dcd`, so `npx @devicecloud.dev/dcd dcd-mcp` would run `dcd dcd-mcp` (an unknown command) instead of the server. It signs in like `dcd mcp`, and takes `--read-only` and `DCD_MCP_READONLY=1` the same way.

## e2e tests on DeviceCloud devices (early access)

`@devicecloud.dev/dcd/e2e` is a device provider for [e2e](https://github.com/e2e-inc/e2e). Each e2e worker gets its own DeviceCloud device session, and e2e drives the device directly. The session shows in the console, is recorded, and is billed like any other. Your organization needs this turned on by DeviceCloud first.

```ts
// e2e.config.ts
import type { E2EConfig } from 'e2e';
import { mobile } from '@e2e-dev/mobile';
import { deviceCloud } from '@devicecloud.dev/dcd/e2e';

const engine = mobile({ platform: 'android', device: deviceCloud() });

export default {
targets: [{ name: 'android', engine, app: { bundleId: 'com.example.app', appPath: './build/app.apk' } }],
// The first screen read after a launch can take a few seconds.
assertionTimeout: 20_000,
} satisfies E2EConfig;
```

Run `npx e2e run` with `DEVICE_CLOUD_API_KEY` set. The provider uploads `appPath` once per run and each session installs it, so e2e installs nothing itself. To use a build you already uploaded, pass `deviceCloud({ appBinaryId })`. It also takes `model`, `os`, `maxDurationMin`, and `locale` (such as `en_US`) for the device's language and region, set before your build is installed. Each session's console link is printed as the run starts, and the session is stopped when e2e is done with it.

With e2e's `video` option on (any setting but `'off'`), each test's video in e2e's report is a console link to that test's part of the session's recording. The session is recorded as one video, so the link plays the part from the test's start to its end; it works once the session has ended and its video has uploaded, for as long as the session's files are kept.


## Development

Requires Node 22+ and [pnpm](https://pnpm.io). `pnpm install` builds the CLI and installs the git hooks automatically.
Requires Node 22.8+ and [pnpm](https://pnpm.io). `pnpm install` builds the CLI and installs the git hooks automatically.

```sh-session
$ pnpm install # install deps, build, set up git hooks
Expand Down
13 changes: 0 additions & 13 deletions eslint.config.cjs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@

const js = require('@eslint/js');
const tseslint = require('typescript-eslint');
// This plugin ships as ESM with a `default` export under CJS interop.
const unicornPlugin =
require('eslint-plugin-unicorn').default ?? require('eslint-plugin-unicorn');

module.exports = tseslint.config(
{
Expand All @@ -21,16 +18,6 @@ module.exports = tseslint.config(
js.configs.recommended,
...tseslint.configs.recommended,
{
// `unicorn` is only registered so legacy
// `// eslint-disable-next-line unicorn/...` comments scattered through
// the source resolve. We don't enable any rules from it.
// `eslint-plugin-import` used to be registered here for the same reason,
// but it was dropped: it dragged in minimatch@3 -> brace-expansion@1.x,
// which has an unpatched DoS advisory (GHSA-mh99-v99m-4gvg, no 1.x
// backport) and failed `pnpm audit`. No rules from it were ever enabled.
plugins: {
unicorn: unicornPlugin,
},
languageOptions: {
ecmaVersion: 2022,
sourceType: 'module',
Expand Down
25 changes: 12 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,7 @@
"dependencies": {
"@clack/prompts": "^1.6.0",
"@modelcontextprotocol/sdk": "^1.31.0",
"@supabase/supabase-js": "^2.108.2",
"bplist-parser": "^0.5.0",
"chalk": "^6.0.0",
"bplist-parser": "^0.6.0",
"citty": "^0.2.2",
"js-yaml": "^5.2.2",
"node-stream-zip": "^1.15.0",
Expand All @@ -29,7 +27,6 @@
"chai": "^6.2.2",
"eslint": "^10.15.0",
"eslint-config-prettier": "^10.1.8",
"eslint-plugin-unicorn": "^79.0.0",
"husky": "^9.1.7",
"mocha": "^12.0.0",
"prettier": "^3.8.4",
Expand All @@ -38,7 +35,7 @@
"typescript-eslint": "^8.73.0"
},
"engines": {
"node": ">=22.0.0"
"node": ">=22.8.0"
},
"files": [
"/dist"
Expand Down Expand Up @@ -66,7 +63,7 @@
"test:unit": "node scripts/test-runner.mjs --unit",
"typecheck": "tsc --noEmit -p tsconfig.test.json"
},
"version": "5.15.0",
"version": "5.16.0",
"bugs": {
"url": "https://discord.gg/gm3mJwcNw8"
},
Expand All @@ -79,18 +76,20 @@
"testing"
],
"types": "dist/index.d.ts",
"exports": {
".": "./dist/index.js",
"./e2e": {
"types": "./dist/e2e/index.d.ts",
"default": "./dist/e2e/index.js"
},
"./package.json": "./package.json",
"./dist/*": "./dist/*"
},
"packageManager": "pnpm@10.17.1",
"pnpm": {
"overrides": {
"minimatch@>=10.0.0 <11.0.1": "11.0.1",
"glob@>=9.0.0 <14.0.2": "14.0.2"
},
"auditConfig": {
"ignoreGhsas": [
"GHSA-frvp-7c67-39w9",
"GHSA-vfj7-8cjw-p6xm",
"GHSA-fc5q-39xc-vjpf"
]
}
}
}
Loading
Loading