Skip to main content

Module dependent_version_paths

Module dependent_version_paths 

Source
Expand description

Which paths the dependent-version planner reads: manifests, configuration, source. What: Which repository paths the dependent-version planner reads: workspace manifests, the registry configuration, and a package’s non-test source files. Why: The planner selects these from the tracked-path list itself, so the provider needs no pathspec support. The rules are the incumbent’s: isWorkspaceManifestPath (dependent-version-bump-policy.ts:66-73), the manifest pathspec :(glob)package/*/*/package.json, PNPR_CONFIG_PATH (publishable-names.ts:10) and isNonTestSourcePath (source-imports.ts:38-55).

In TS you’d write (pseudocode):

// isWorkspaceManifestPath(path); packageDirectory(manifestPath); isNonTestSourcePath({ directory, path });

Constants§

PNPR_CONFIG_PATH
What: The generated registry configuration whose OIDC package list is the publish set. &[u8] is a borrowed list of bytes baked into the program. Why: Only packages listed there receive a dependent bump.

Functions§

is_non_test_source_path
What: Whether a path is non-test source of the package in directory. Why: The file must sit under the package’s src/, end with a source extension, and its name must not contain .test.. A sibling directory sharing a prefix (package/module/ab for package/module/a) does not count.
is_workspace_manifest_path
What: Whether a path is package/<category>/<name>/package.json. .split(...) yields the /-separated segments; Vec<&[u8]> collects borrowed views of them. Why: Only such a manifest is a workspace package; the incumbent’s candidate test and its tracked-file pathspec both select exactly these paths.
package_directory
What: The package directory of a workspace manifest path. .strip_suffix(...) returns the bytes before the suffix, or nothing when the path does not end with it. Why: Source files are looked up under <directory>/src/.