@omercnet/paseo-omp 0.2.1-next.89.1 → 0.2.1-next.90.1

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 CHANGED
@@ -6,7 +6,7 @@ Community OMP integration for Paseo. The plugin registers the distinct `omp-plug
6
6
 
7
7
  ## Quick start
8
8
 
9
- Requirements: Paseo `^0.8.0`, OMP `18.1.15` or newer, and OMP RPC protocol v2.
9
+ Requirements: Paseo `>=0.8.0 <0.10.0`, OMP `18.1.15` or newer, and OMP RPC protocol v2. Paseo `0.9.0-beta.1` is recommended for npm-managed installation and the complete client integration.
10
10
 
11
11
  ```bash
12
12
  paseo plugin install npm:@omercnet/paseo-omp@<version>
@@ -22,7 +22,7 @@ Open the **OMP** sidebar to review the provider-profile contract, choose which c
22
22
  - [Core-provider issue and parity audit](docs/core-provider-issue-audit.md)
23
23
  - [Alpha release checklist](docs/alpha-release-checklist.md)
24
24
 
25
- The plugin uses only public Paseo 0.8 provider contracts and registers distinct `omp-plugin` and `omp-plugin-<profile>` identities; it does not modify the bundled `omp` provider.
25
+ The plugin uses public Paseo 0.8 and 0.9 beta provider contracts and registers distinct `omp-plugin` and `omp-plugin-<profile>` identities; it does not modify the bundled `omp` provider.
26
26
 
27
27
  ## Named OMP profiles
28
28
 
@@ -36,7 +36,7 @@ Profile selection is request-local: concurrent clients cannot change each other'
36
36
 
37
37
  ## Paseo provider SDK coverage
38
38
 
39
- This matrix inventories the complete capability set exported by the pinned `@getpaseo/plugin` 0.8.0 provider SDK. It measures strict SDK surface coverage, not general product quality.
39
+ This matrix inventories the complete capability set exported by the pinned `@getpaseo/plugin` 0.9.0-beta.1 provider SDK. It measures strict SDK surface coverage, not general product quality.
40
40
 
41
41
  **Current capability completeness: 61.8%.** The provider advertises 11 of 17 capabilities (64.7%); ten are complete and `session.configure` is partial.
42
42
 
@@ -99,6 +99,8 @@ Existing agents whose provider is `omp` remain owned by the bundled provider. Ne
99
99
 
100
100
  OMP `18.1.15` is the oldest version tested end to end. The direct provider's hard compatibility gate is `rpc-ui` protocol v2: metadata-free legacy ready frames and v1-only runtimes are rejected before a provider session opens because they cannot support the advertised persistence and conversation-rewind capabilities. Typed tool approvals remain capability-gated and fall back as described above. For terminal completion, a matching `agent_end.requestId` is authoritative and mismatches are ignored before state changes. Released OMP 18.2.x builds that omit that field use an ordered fallback requiring a fresh correlated native user entry followed by current-turn assistant activity, an idle non-compacting runtime, and no conflicting permission, tool, steer, or child-session work. Ambiguous events while OMP is active are ignored; unresolved ambiguity after confirmed idle fails only the Paseo turn. This trades a bounded residual same-agent stale-event risk for compatibility with released OMP instead of terminating and lazily restarting the runtime after every later prompt. Paseo clients, including mobile clients inside reconnect grace, do not own or terminate the daemon-managed OMP session.
101
101
 
102
+ Paseo 0.9.0-beta.1 is the canary target and provides npm-managed plugin sources, platform-owned external URL opening, and whole-item timeline transforms before Overview grouping. Paseo 0.8.x remains supported for provider operation and Git or directory installation; its clients do not provide the external URL opener and retain their older timeline presentation semantics.
103
+
102
104
  Install, update, disable, or remove `paseo-omp` independently of the bundled provider. Verify the provider snapshot contains `omp-plugin` after installation; a bundled `omp` entry may remain present and is not modified by this plugin.
103
105
 
104
106
  ## Output and credential boundary
package/SUPPORT.md CHANGED
@@ -16,7 +16,7 @@ Do not put credentials, private repository paths, session transcripts, or unreda
16
16
 
17
17
  ## Supported versions
18
18
 
19
- - Paseo: `^0.8.0` on both the daemon and every app loading the client entry.
19
+ - Paseo: `>=0.8.0 <0.10.0` on both the daemon and every app loading the client entry. The pinned SDK and controlled canary use `0.9.0-beta.1`; 0.8.x remains the compatibility line.
20
20
  - OMP: `18.1.15` is the oldest release in the required real-binary regression job. The hard runtime contract is `rpc-ui` protocol v2, not the version string alone.
21
21
  - Plugin release channel: alpha. Backward compatibility is best effort until stable `0.1.0`; every known migration requirement must be stated in the release notes.
22
22
  - Typed approvals: optional. When both peers negotiate `typedToolApprovals: 1`, the plugin uses typed tool permissions. Otherwise it retains the bounded generic extension-question flow.
@@ -33,6 +33,7 @@ Do not put credentials, private repository paths, session transcripts, or unreda
33
33
  - The deterministic mock does not implement OMP's compaction-summary contract, so `/compact` reports `OMP compaction failed` in the canary; compaction remains covered by protocol fixtures.
34
34
  - `/handoff` reports `OMP command failed` in the controlled canary even with deterministic role models configured; treat handoff as unavailable there until its native prerequisite is isolated.
35
35
  - On official Paseo 0.8.0, requesting a live approval-mode change that the plugin rejects can trigger the daemon's unhandled-rejection restart path. Create a new `full`, `write`, or `ask` session instead of changing mode in place.
36
+ - Paseo 0.8 clients do not expose the platform-owned plugin URL opener and transform timeline items after Overview grouping. Use a 0.9.0-beta.1 app for external documentation/device-authorization actions and for reliable image-card transformation of every source tool call.
36
37
  - Native Fast mode and a first-class plan mode are not exposed. `/handoff` is implemented but is not reproducible in the controlled canary without its native OMP workflow prerequisites.
37
38
  - Terminal-started OMP sessions are discoverable and importable but are not registered automatically through a terminal hook.
38
39
  - Paseo clients do not own OMP sessions. Mobile or desktop disconnects remain subject to Paseo's reconnect grace while the daemon-owned provider and OMP child continue independently; reconnecting can reveal an existing turn but does not transfer or sever runtime ownership.
package/TESTING.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # OMP provider parity audit
2
2
 
3
- Validated against the Paseo plugin SDK versions pinned in `package.json`, official Paseo Docker image `0.8.0@sha256:5518da7cdd35f132e8a944c35e509c677a90a8f3ec8a78df98f7fb5fd5e2c6c3`, and the real OMP compatibility matrix: high-use historical releases 17.2.15, 17.3.4, 18.0.11, and 18.1.10; minimum supported release 18.1.15; latest published 18.1 patch 18.1.22; and current release 18.2.0.
3
+ Validated against the Paseo plugin SDK versions pinned in `package.json` and the real OMP compatibility matrix: high-use historical releases 17.2.15, 17.3.4, 18.0.11, and 18.1.10; minimum supported release 18.1.15; latest published 18.1 patch 18.1.22; and current release 18.2.0. Validation against official Paseo Docker image `0.9.0-beta.1@sha256:f75a0eb3547ad3cc6bbdeaa7277d2d50eb4d06a9dd669d480371d7adf1c911b5` is partial as recorded below.
4
4
 
5
5
  Classifications:
6
6
 
@@ -105,7 +105,7 @@ Set `PASEO_CANARY_OMP_VERSION` to exercise another pinned release. The local run
105
105
 
106
106
  The Linux real-OMP CI matrix downloads checksummed `omp-linux-x64` assets for OMP 17.2.15, 17.3.4, 18.0.11, 18.1.10, 18.1.15, 18.1.22, and 18.2.0, verifies each binary's pinned GitHub release SHA-256, and runs `PASEO_OMP_REAL_E2E=1 PASEO_OMP_VERSION=<version> npm test -- tests/provider.real.e2e.test.ts`. The historical entries are the four pre-floor releases with more than 4,000 downloads shown by npm for the seven days ending 2026-09-15; they are compatibility regression probes, not a support commitment. The remaining entries cover the supported floor, newest patch in that minor line, and current release. The test uses the real OMP binary and a local deterministic OpenAI-compatible model endpoint, including three sequential prompts on one native session, a Bash tool, and oversized-image transport.
107
107
 
108
- The controlled canary in `canary/compose.yml` builds this plugin into that official Paseo image and installs checksummed OMP binaries for `amd64` and `arm64`. `canary/smoke.ts` passed catalog/mode discovery, text and image prompts, Bash, a configured stdio MCP tool, permission allow/deny/cancel, steering, interruption, session listing/import/resume, subagents, conversation rewind followed by another turn, Hub process visibility, usage, and every plugin RPC. Browser verification loaded the global OMP health/configuration surface and the agent-scoped Hub, Memory, and Sessions controls. The default mock returned `CANARY_MOCK_OK`, `CANARY_TOOL_OK`, and `CANARY_MCP_OK`; the optional Ollama profile pulled `qwen2.5:0.5b` and completed turns without paid credentials. The harness records the canary-only `/compact` and `/handoff` failures instead of masking them.
108
+ The controlled canary in `canary/compose.yml` successfully built the plugin into that official Paseo image, started the daemon, loaded `paseo-omp`, and completed runtime health, catalog/mode discovery, initial text, model switching, `autocompact`, `follow-up`, and the documented compact/handoff error collection. It then failed on the first Bash scenario because the later turn ended without request-correlated terminal ownership: `OMP terminal ownership could not be confirmed`. The subsequent image, MCP, permission, steering, interruption, persistence, subagent, Hub, usage, rewind, browser, and optional Ollama scenarios were not reached and remain unverified on Paseo 0.9.0-beta.1.
109
109
 
110
110
  ## OMP RPC compatibility intake
111
111
 
@@ -142,9 +142,9 @@ The go/no-go criteria, manual acceptance boundary, and alpha limitation list are
142
142
  - `npm test -- tests/provider-conformance.test.ts`: host-boundary conformance coverage includes `prompt.command`, `session.configure`, typed and fallback permission allow/deny/cancel paths, registry-driven reload/removal, verified stubborn-descendant cleanup, and sequential turns plus interrupt races with post-turn barriers.
143
143
  - `PASEO_OMP_REAL_E2E=1 PASEO_OMP_VERSION=<version> npm test -- tests/provider.real.e2e.test.ts`: the installed matrix version's catalog and hermetic real-binary text/Bash and oversized-image scenarios run against a local deterministic model.
144
144
  - `npm run test:coverage`: Vitest enforces aggregate 85% function and 89% line coverage over loaded source modules. Generated `dist/**` trees are excluded.
145
- - `npm run test:integration:install`: a packed npm package retains required production dependencies and bundles successfully; a fresh Git-style checkout installs with lifecycle scripts disabled, typechecks, and loads the server contribution.
145
+ - `npm run test:integration:install`: npm package acquisition retains required production dependencies, and a fresh Git-style checkout runs frozen production-only preparation with lifecycle scripts disabled. Both installed trees resolve runtime dependencies, compile the client and server entries with Paseo's host compiler, and load the server contribution.
146
146
  - `npm run test:integration:docker`: verifies the host/container ownership boundary.
147
147
  - `npm run test:integration:wsl`: locally skips when `wsl.exe` is unavailable; Windows CI sets `PASEO_OMP_REQUIRE_WSL=1`, so this boundary remains required there.
148
- - `docker compose -f canary/compose.yml`: official Paseo 0.8.0, deterministic mock, Tailscale-bound web UI, and optional Ollama `qwen2.5:0.5b` passed end-to-end.
148
+ - `docker compose -f canary/compose.yml`: official Paseo 0.9.0-beta.1 image build, daemon startup, plugin load, and early deterministic scenarios passed; the smoke stopped at the first later-turn Bash scenario with `OMP terminal ownership could not be confirmed`, so the remaining scenarios are unverified.
149
149
  - `zizmor .github/workflows`: no findings (offline audit; six repository-wide suppressions remain).
150
150
  - Release Please 17.1.2 `config.json` and `manifest.json` schema validation: passed for `release-please-config.json` and `.release-please-manifest.json`.
@@ -0,0 +1,15 @@
1
+ import * as paseoClient from "@getpaseo/plugin/client";
2
+ import { Linking } from "react-native";
3
+ import { selectExternalUrlOpener, validatedHttpUrl } from "../shared/external-url";
4
+
5
+ const paseoOpenExternalUrl =
6
+ "openExternalUrl" in paseoClient && typeof paseoClient.openExternalUrl === "function"
7
+ ? paseoClient.openExternalUrl
8
+ : undefined;
9
+ const openExternalUrl = selectExternalUrlOpener(paseoOpenExternalUrl, (url) =>
10
+ Linking.openURL(url),
11
+ );
12
+
13
+ export function openOmpExternalUrl(url: string): Promise<void> {
14
+ return openExternalUrl(validatedHttpUrl(url));
15
+ }
@@ -1,11 +1,12 @@
1
1
  import { type PluginTimelineItemProps, useRpc } from "@getpaseo/plugin/client";
2
2
  import { Icon } from "@getpaseo/plugin/client/react-native";
3
3
  import { useMemo, useState } from "react";
4
- import { Linking, Pressable, Text, View } from "react-native";
4
+ import { Pressable, Text, View } from "react-native";
5
5
  import {
6
6
  type OmpMcpAuthorizationTimeline,
7
7
  openOmpMcpAuthorizationInPaseoBrowser,
8
8
  } from "../shared/mcp";
9
+ import { openOmpExternalUrl } from "./external-url";
9
10
 
10
11
  function browserAuthorizationError(error: unknown): string {
11
12
  const detail = error instanceof Error ? error.message : String(error);
@@ -98,7 +99,7 @@ export function OmpMcpAuthorizationCard({
98
99
  setError(null);
99
100
  setMessage(null);
100
101
  try {
101
- await Linking.openURL(item.data.url);
102
+ await openOmpExternalUrl(item.data.url);
102
103
  } catch {
103
104
  setError("Could not open the authorization URL. Copy the URL below into a browser.");
104
105
  } finally {
@@ -10,7 +10,7 @@ import { useIsMutating, useMutation, useQuery, useQueryClient } from "@tanstack/
10
10
  import type { ReactNode } from "react";
11
11
  import { useCallback, useMemo, useState } from "react";
12
12
  import type { TextStyle, ViewStyle } from "react-native";
13
- import { Linking, Pressable, ScrollView, Switch, Text, View } from "react-native";
13
+ import { Pressable, ScrollView, Switch, Text, View } from "react-native";
14
14
  import type { ComposerPillSettings } from "../shared/composer-pill-settings";
15
15
  import { listOmpConfig, type OmpConfig } from "../shared/omp-config";
16
16
  import {
@@ -26,6 +26,7 @@ import {
26
26
  import { type OmpStore, storeLabel } from "../shared/omp-store";
27
27
  import { getOmpProviderHealth, type OmpProviderHealth } from "../shared/provider-diagnostics";
28
28
  import { ComposerPillSettingsSection } from "./composer-pill-settings";
29
+ import { openOmpExternalUrl } from "./external-url";
29
30
  import {
30
31
  documentationForSettingCategory,
31
32
  documentationForSettingPath,
@@ -1072,7 +1073,7 @@ function OmpConfigContent({
1072
1073
  const openDocumentation = useCallback(async (link: OmpDocumentationLink) => {
1073
1074
  setDocumentationError(null);
1074
1075
  try {
1075
- await Linking.openURL(link.url);
1076
+ await openOmpExternalUrl(link.url);
1076
1077
  } catch {
1077
1078
  setDocumentationError(`Could not open ${link.label.toLocaleLowerCase()}.`);
1078
1079
  }
@@ -0,0 +1,9 @@
1
+ import type { PluginClientContext } from "@getpaseo/plugin/client";
2
+
3
+ type AsyncResult<Callable> = Callable extends (...args: never[]) => Promise<infer Result>
4
+ ? Result
5
+ : never;
6
+
7
+ export type PaseoApi = PluginClientContext["paseo"];
8
+ export type PaseoAgentListResult = AsyncResult<PaseoApi["agents"]["list"]>;
9
+ export type PaseoProviderSnapshotResult = AsyncResult<PaseoApi["providers"]["snapshot"]>;
@@ -1,4 +1,3 @@
1
- import type { PaseoApi, PaseoProviderSnapshotResult } from "@getpaseo/client";
2
1
  import type {
3
2
  OmpLspDiagnostics,
4
3
  OmpMcpDiagnostics,
@@ -8,8 +7,8 @@ import type {
8
7
  OmpVersionStatus,
9
8
  PathState,
10
9
  } from "../shared/provider-diagnostics";
11
-
12
10
  import { isOmpProvider } from "./omp-store-state";
11
+ import type { PaseoApi, PaseoProviderSnapshotResult } from "./paseo-types";
13
12
 
14
13
  export type ProviderHealthTone = "ok" | "warning" | "danger" | "muted";
15
14
  export const OMP_PROVIDER_IDS = ["omp", "omp-plugin"] as const;
@@ -7,7 +7,7 @@ This checklist prepares `paseo-omp-v0.1.0-alpha.1`. It does not authorize public
7
7
  - [ ] Release Please proposes `0.1.0-alpha.1` from manifest version `0.0.0`.
8
8
  - [ ] Package and tag names are `@omercnet/paseo-omp` and `paseo-omp-v0.1.0-alpha.1`.
9
9
  - [ ] Provider identity remains `omp-plugin`; bundled `omp` remains independent and enabled or disabled by the user.
10
- - [ ] Paseo requirement remains an official released range, currently `^0.8.0`.
10
+ - [ ] Paseo requirement remains the reviewed dual-version range, currently `>=0.8.0 <0.10.0`.
11
11
  - [ ] Minimum tested OMP version, checksum, CI job, README, SUPPORT, and TESTING agree.
12
12
 
13
13
  ## Required gates
@@ -4,29 +4,53 @@ Paseo plugins are trusted, unsandboxed code. Review this plugin and its producti
4
4
 
5
5
  ## Requirements
6
6
 
7
- - Paseo daemon and apps: `^0.8.0`
7
+ - Paseo daemon and apps: `>=0.8.0 <0.10.0`; `0.9.0-beta.1` is recommended
8
8
  - OMP: `18.1.15` or newer is the supported floor
9
9
  - OMP RPC: protocol v2 must negotiate successfully
10
10
 
11
11
  The first public build is an alpha. Alpha releases are compatibility previews and may require deleting and re-importing agents created by an earlier preview.
12
12
 
13
- ## Install a release
13
+ ## Install or update from npm on Paseo 0.9
14
14
 
15
- Install an exact published version from npm:
15
+ Paseo 0.9.0-beta.1 can acquire the published package and its production dependencies directly from npm on the daemon host:
16
16
 
17
17
  ```bash
18
18
  paseo plugin install npm:@omercnet/paseo-omp@<version>
19
19
  paseo plugin ls paseo-omp
20
20
  ```
21
21
 
22
- Alternatively, install the matching reviewed Git tag:
22
+ Check for the registry's current `latest` version and approve the proposed update, or select an exact version explicitly:
23
+
24
+ ```bash
25
+ paseo plugin update paseo-omp
26
+ paseo plugin update paseo-omp --version <new-version>
27
+ ```
28
+
29
+ The daemon uses its own npm registry and authentication configuration. npm acquisition installs the artifact's production dependencies before preparation; because npm artifacts omit `package-lock.json`, the preparation helper leaves that tree unchanged. A Git checkout with the committed lockfile runs frozen `npm ci --omit=dev --ignore-scripts`. A failed download, preparation, compatibility check, or activation keeps the installed revision active. Paseo 0.8 does not support npm plugin sources; use a Git tag or local directory instead.
30
+
31
+ ## Install a Git release on Paseo 0.8 or 0.9
32
+
33
+ Install the matching reviewed Git tag:
23
34
 
24
35
  ```bash
25
36
  paseo plugin add omercnet/paseo-plugins:paseo-omp --ref paseo-omp-v<version>
26
37
  paseo plugin ls paseo-omp
27
38
  ```
28
39
 
29
- A Git tag-pinned installation does not advance through `paseo plugin update`. To upgrade, record the current installation, then replace it with the new tag in one maintenance window:
40
+ ### Update a Git installation on Paseo 0.9
41
+
42
+ An ordinary update reviews the remote repository's current default HEAD. To move directly to another reviewed tag or commit, select it explicitly:
43
+
44
+ ```bash
45
+ paseo plugin update paseo-omp
46
+ paseo plugin update paseo-omp --ref paseo-omp-v<new-version>
47
+ ```
48
+
49
+ The install-time `--ref` does not constrain later updates. Paseo 0.9 stages and validates the selected revision before replacing the active installation, so plugin settings remain intact and a failed update leaves the previous revision running.
50
+
51
+ ### Update a tag-pinned Git installation on Paseo 0.8
52
+
53
+ Paseo 0.8 does not provide the 0.9 non-destructive explicit-ref update flow. Record the current installation, then replace it with the new tag in one maintenance window:
30
54
 
31
55
  ```bash
32
56
  paseo plugin ls paseo-omp --json > paseo-omp-before-update.json
@@ -56,12 +80,10 @@ paseo plugin ls paseo-omp
56
80
 
57
81
  ## Track a branch
58
82
 
59
- Tracking `main` executes future dependency and plugin updates with the daemon user's privileges. Record the installed commit before each update:
83
+ Tracking `main` executes future dependency and plugin updates with the daemon user's privileges:
60
84
 
61
85
  ```bash
62
86
  paseo plugin add omercnet/paseo-plugins:paseo-omp --ref main
63
- paseo plugin ls paseo-omp --json > paseo-omp-before-update.json
64
- paseo plugin update paseo-omp
65
87
  ```
66
88
 
67
- A failed Git build or incompatible update leaves the previous revision active. Remove and re-add the recorded commit to roll back.
89
+ On Paseo 0.9, preview and approve the remote default HEAD with `paseo plugin update paseo-omp`, or select `main` explicitly with `paseo plugin update paseo-omp --ref main`. On Paseo 0.8, record the installed commit before its existing branch-update workflow. A failed build or compatibility check leaves the previous revision active.
package/index.client.tsx CHANGED
@@ -1,4 +1,3 @@
1
- import type { PaseoAgentListResult, PaseoApi } from "@getpaseo/client";
2
1
  import { settingsRpc } from "@getpaseo/plugin";
3
2
  import type {
4
3
  PluginButtonRegistration,
@@ -19,6 +18,7 @@ import {
19
18
  isOmpProvider,
20
19
  ompStoreKey,
21
20
  } from "./client/omp-store-state";
21
+ import type { PaseoAgentListResult, PaseoApi } from "./client/paseo-types";
22
22
  import { quotaProviderIcon } from "./client/provider-icon";
23
23
  import { OmpImageTimeline } from "./client/provider-image";
24
24
  import { QuotaPopover } from "./client/quota-popover";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@omercnet/paseo-omp",
3
- "version": "0.2.1-next.89.1",
3
+ "version": "0.2.1-next.90.1",
4
4
  "type": "module",
5
5
  "description": "Paseo integration for OMP, including its direct provider and workspace tooling.",
6
6
  "license": "MIT",
@@ -57,20 +57,19 @@
57
57
  "typecheck": "tsc --noEmit"
58
58
  },
59
59
  "dependencies": {
60
+ "@getpaseo/protocol": "0.9.0-beta.1",
60
61
  "@modelcontextprotocol/sdk": "1.29.0",
61
62
  "yaml": "^2.9.0"
62
63
  },
63
64
  "devDependencies": {
64
65
  "@biomejs/biome": "^2.5.10",
65
- "@getpaseo/cli": "0.8.0",
66
- "@getpaseo/client": "0.8.0",
67
- "@getpaseo/plugin": "0.8.0",
68
- "@getpaseo/protocol": "0.8.0",
66
+ "@getpaseo/cli": "0.9.0-beta.1",
67
+ "@getpaseo/client": "0.9.0-beta.1",
68
+ "@getpaseo/plugin": "0.9.0-beta.1",
69
69
  "@tanstack/react-query": "^5.102.3",
70
70
  "@types/node": "^24.10.1",
71
71
  "@types/react": "^19.2.18",
72
72
  "@vitest/coverage-v8": "^5.0.0",
73
- "esbuild": "^0.28.0",
74
73
  "react": "19.1.0",
75
74
  "react-native": "0.81.5",
76
75
  "tsx": "^4.20.6",
package/paseo-plugin.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "id": "paseo-omp",
3
- "requirements": { "paseo": "^0.8.0" },
3
+ "requirements": { "paseo": ">=0.8.0 <0.10.0" },
4
4
  "build": [["node", "scripts/prepare-dependencies.mjs"]]
5
5
  }
@@ -8,10 +8,14 @@ const projectRoot = dirname(dirname(fileURLToPath(import.meta.url)));
8
8
  export function prepareDependencies(root = projectRoot, execute = execFileSync) {
9
9
  if (!existsSync(join(root, "package-lock.json"))) return false;
10
10
 
11
- execute(process.platform === "win32" ? "npm.cmd" : "npm", ["ci", "--ignore-scripts"], {
12
- cwd: root,
13
- stdio: "inherit",
14
- });
11
+ execute(
12
+ process.platform === "win32" ? "npm.cmd" : "npm",
13
+ ["ci", "--omit=dev", "--ignore-scripts"],
14
+ {
15
+ cwd: root,
16
+ stdio: "inherit",
17
+ },
18
+ );
15
19
  return true;
16
20
  }
17
21
 
@@ -0,0 +1,21 @@
1
+ export type ExternalUrlOpener = (url: string) => Promise<void>;
2
+
3
+ export function selectExternalUrlOpener(
4
+ paseoOpener: ExternalUrlOpener | undefined,
5
+ fallback: ExternalUrlOpener,
6
+ ): ExternalUrlOpener {
7
+ return paseoOpener ?? fallback;
8
+ }
9
+
10
+ export function validatedHttpUrl(value: string): string {
11
+ let url: URL;
12
+ try {
13
+ url = new URL(value);
14
+ } catch {
15
+ throw new Error("Only absolute HTTP(S) URLs are supported.");
16
+ }
17
+ if (url.protocol !== "http:" && url.protocol !== "https:") {
18
+ throw new Error("Only absolute HTTP(S) URLs are supported.");
19
+ }
20
+ return url.href;
21
+ }