# Managers

> Every package manager Count Patchula supports, the files each one reads, and the lockfiles it regenerates.

A manager finds dependencies in one kind of file and knows how to edit them. Every manager is on by default; `managers` in your config replaces the list, and `files` replaces one manager’s file patterns.

Edits are surgical. Each dependency is extracted with the exact byte range of its version, and an update rewrites those bytes and nothing else, keeping your quoting, comments and formatting. A YAML value is read as written: a plain `tag: 1.10` is the tag `1.10`, not the number 1.1. A new plain YAML value stays unquoted only when YAML reads it back as the same text; otherwise it is written in double quotes, so `tag: 1.9` becomes `tag: "1.10"` and `version: 2` becomes `version: "3"`.

| Manager | Files | Lockfile the Count regenerates |
| - | - | - |
| `npm` | `package.json`, `pnpm-workspace.yaml` and `.yarnrc.yml` catalogs, `.nvmrc`, `.node-version`, `.npmrc` registries | `package-lock.json`, `npm-shrinkwrap.json`, `aube-lock.yaml`, `pnpm-lock.yaml`, `yarn.lock`, `bun.lock` |
| `bun` | `package.json` when `npm` is off | `bun.lock` |
| `github-actions` | `.github/workflows/*.yml`, `.forgejo/workflows/*.yml`, `.gitea/workflows/*.yml` (each also `.yaml`), `action.yml`, `action.yaml` | |
| `mise` | `mise.toml`, `.mise.toml`, `.tool-versions` | `mise.lock` |
| `cargo` | `Cargo.toml`, `rust-toolchain`, `rust-toolchain.toml` | `Cargo.lock` |
| `go` | `go.mod` | `go.sum` |
| `dockerfile` | `Dockerfile`, `Dockerfile.*`, `*.Dockerfile`, `*.dockerfile` | |
| `compose` | `compose*.yml`, `docker-compose*.yml` (each also `.yaml`) | |
| `kubernetes` | Kubernetes manifests (`*.yaml`, `*.yml`) | |
| `kustomize` | `kustomization.yaml`, `kustomization.yml`, `Kustomization` | |
| `flux` | Flux `HelmRepository`, `HelmRelease`, `OCIRepository`, [generated bundles](#flux-bundles) | generated bundles, with `flux install --export` |
| `helm-values` | `values*.yaml`, `*values.yaml` (each also `.yml`) | |
| `helm` | `Chart.yaml`, `requirements.yaml` | `Chart.lock` or `requirements.lock`, with `helm dependency update` |
| `terraform` | `*.tf`, `.terraform-version` | `.terraform.lock.hcl` |
| `pyproject` | `pyproject.toml`, `.python-version`, `uv.toml` indexes | `uv.lock`, `poetry.lock`, `pdm.lock`, a uv-exported `pylock.toml`; `Pipfile.lock` holds the update |
| `pre-commit` | `.pre-commit-config.yaml` | |
| `devcontainer` | `devcontainer.json`, `.devcontainer.json` | |
| `woodpecker` | `.woodpecker.yml`, `.woodpecker.yaml`, `.woodpecker/*.yml` and `*.yaml` | |
| `copier` | `.copier-answers.yml`, `.copier-answers.yaml`, `.copier-answers.*.yml` and `*.yaml` | none: newer template versions are [reported, not applied](#copier) |
| `maven` | `pom.xml` | |
| `gradle` | `*.gradle`, `*.gradle.kts`, `gradle.properties`, `gradle/*.versions.toml`, the wrapper | the wrapper checksum; `gradle.lockfile` holds the update |
| `nuget` | `*.csproj`, `*.fsproj`, `*.vbproj`, `Directory.Packages.props`, `Directory.Build.props`, `global.json`, `.config/dotnet-tools.json` | `packages.lock.json` |
| `bundler` | `Gemfile`, `.ruby-version` | `Gemfile.lock` |
| `composer` | `composer.json` | `composer.lock` |
| `gitlabci` | `.gitlab-ci.yml`, `*.gitlab-ci.yml` (and `.yaml`) | |
| `gitlabci-include` | `.gitlab-ci.yml`, `*.gitlab-ci.yml` (and `.yaml`) | |
| `nix` | `flake.lock` beside a `flake.nix` | `flake.lock` |
| `apm` | `apm.yml`, `apm.yaml` | `apm.lock.yaml` |
| `pkl` | `*.pkl`, except the root `patchula.pkl` | |
| `regex` | whatever your [extractors](https://count-patchula.sweepy.dev/guide/configuration/#custom-extractors) select | |

Lockfiles provide the current version where they exist. Their transitive entries only become dependencies of their own, of kind `transitive`, when they have a [known vulnerability](https://count-patchula.sweepy.dev/guide/security/#lockfile-only-packages). A file that does not parse at all, such as an ERB-templated YAML file, is skipped with a warning and the rest of the repository carries on.

Declarations a manager cannot read as versions are *skipped*: each is listed with its line and reason in the run summary, in the dashboard’s “Skipped” section and under `skipped` in the [JSON report](https://count-patchula.sweepy.dev/reference/report/). Unlike a warning, a skip doesn’t hold back branch cleanup or auto-merge.

## Declarations kept at a root

Some ecosystems keep a version once, at a workspace root or in a central file, and let members refer to it:

| Ecosystem | Root entry | Member reference |
| - | - | - |
| Cargo | `[workspace.dependencies]` in the nearest workspace root | `foo = { workspace = true }` |
| pnpm, Yarn 4, Bun | `catalog` and `catalogs` in the workspace root’s `pnpm-workspace.yaml`, `.yarnrc.yml` or `package.json` | `"foo": "catalog:"`, `"foo": "catalog:name"` |
| NuGet | `PackageVersion` in the nearest `Directory.Packages.props` | `PackageReference` with no version |

The edit goes to the root entry, and one edit moves every member that refers to it. So the root entry decides: its rules choose the target, the branch and the group, and a member’s own rules never split it onto a branch of its own. The PR’s table names the root and each member in one row, and the root entry’s lockfile is regenerated with it; a lockfile beside a member is not, and a Cargo wait comes from the root entry’s rules. When the root entry gets no update, because its rules turn it off or its target is held back, no member moves either. A member that declares its own version (a plain requirement in Cargo or `package.json`, `VersionOverride` in a project) keeps it and is updated on its own. `patchula apply` edits the same way: a file that holds both the root entry and a member reference changes only at the root entry.

pnpm and Bun read a nested workspace’s catalogs differently depending on where they run. Take a folder that an outer workspace’s globs cover and that defines a workspace and catalog of its own. Run from the outer root, the tool uses the outer catalog, and pnpm warns that the nested `pnpm-workspace.yaml` does not apply. Run from inside the folder, it uses the folder’s own catalog. The Count takes the view from the outer root: a `catalog:` specifier in that folder moves with the outer catalog’s entry, and the folder’s own catalog entries are updated where they are declared.

Gradle version catalogs, and Maven `${property}` versions defined in the same POM, are dependencies where they are declared; a build script’s `libs.` accessor is not read. A Maven property defined in a parent POM is not followed, so a child POM version that names one is left alone. Go workspaces and uv workspaces keep no versions for their members.

## JavaScript

`npm` covers dependencies, devDependencies, peers, optional dependencies, aliases (`npm:pkg@^1`), nested overrides, resolutions and `packageManager`. Only a version, range or dist-tag names a registry version. Everything else is left alone, since the package of that name on the registry may be someone else’s: `workspace:`, `file:`, `link:`, `catalog:`, `portal:`, `patch:` and the other local protocols, `github:`, `gitlab:`, `bitbucket:`, `gist:`, git and tarball URLs, any other `scheme:`, the `owner/repo` GitHub shorthand, paths and `.tgz` files. Catalogs are dependencies where they are declared: `catalog` and named `catalogs` in `pnpm-workspace.yaml`, `.yarnrc.yml` for Yarn 4, and the root `package.json` for Bun. A `catalog:` specifier refers to the catalogs of its workspace root, as each tool finds it, and [moves with it](#declarations-kept-at-a-root). pnpm reads only the `pnpm-workspace.yaml` of the outermost folder whose own `packages` cover the member, and Bun only the `package.json` of the outermost folder whose own `workspaces` cover it: in neither tool does a member’s own definition add its folders to the root’s workspace. Yarn, whose workspaces may list workspaces of their own, reads the `.yarnrc.yml` at the project root they lead up to and any above it, the nearest one listing the package winning. A catalog file inside a member is ignored, and one the Count cannot parse leaves every specifier it could decide unlinked. A specifier that two tools’ catalogs both list refers to neither. `.nvmrc` and `.node-version` pin Node; aliases such as `lts/*` are not versions. `.npmrc`, `.yarnrc.yml` and Bun’s `bunfig.toml` name each package’s [registry](https://count-patchula.sweepy.dev/guide/sources/#package-registries).

When both `npm` and `bun` are enabled, `npm` owns `package.json` so nothing is updated twice. Binary `bun.lockb` is not regenerated: Bun rewrites it in place, but the Count writes text files only, so an update beside one holds as lockfile-pending. Switch to text `bun.lock`.

## GitHub Actions

Workflow steps, reusable workflows, job containers, services and composite action steps, found through the file’s YAML structure. `run:` text, even a line in it that looks like a step, expressions and local `./` actions are ignored. Actions and images are pinned to digests by default, keeping the version in a comment. A SHA pin with a version comment (`@8e5e7e5... # v4.2.2`) upgrades both. One without a comment is named by the version tags pointing at its commit in the action’s tag catalog, the most specific when several do (`v4.2.2` over `v4.2` and `v4`), and upgrades the same way, gaining the comment. When the tags there name it in different forms, such as `v4.2.2` and `2024.06.01`, the form most of the repository’s tags have wins, since that is the scheme it releases under; when no form leads, the pin stays put with a warning. A commit no version tag points at, such as a branch commit, stays put with a warning. Branch refs keep the branch and only refresh the digest. A short tag such as `v4` keeps its precision when it moves to a release (`v5`), but a prerelease target is written whole (`v5.0.0-rc.1`), since no short alias points at it. Hosted runner labels in `runs-on`, such as `ubuntu-24.04`, upgrade within their OS and architecture family; `ubuntu-latest` floats and is left alone. A ref, image or runner label reached through a YAML alias is one dependency, edited at its anchor; an anchor whose aliases use it with different meanings, such as a reusable workflow and a step, is skipped with the reason. One inside a flow collection (`- {uses: actions/checkout@v4}`) is edited in place, and a pin there gains no version comment, which would swallow the closing bracket; the tag at its commit names it on the next run.

### Tool versions in action inputs

The Count reads no action’s inputs: what an input means is up to each action, so a tool version written into the `with:` of a step or a reusable workflow call is never updated. Each one he finds, any `version` input or one ending in `-version` or `_version` with a literal value, is listed as skipped with what to do instead. Keep the version in `.tool-versions` (or the tool’s own file, such as `.nvmrc` or `go.mod`) and point the action’s version-file input at it; the `mise` and other managers keep that file current:

```yaml
- uses: actions/setup-node@v6
  with:
    node-version-file: .tool-versions
```

Most setup actions take such an input, usually named after the version input with `-file` added (`node-version-file`, `go-version-file`, `version-file`). An action with none needs support for `.tool-versions` from its maintainers, or a [custom extractor](https://count-patchula.sweepy.dev/guide/configuration/#custom-extractors) for the input; an input an extractor reads is not listed as skipped. Better still, install the tools with mise, so `mise.lock` pins each one by checksum too.

An input whose value reads the job’s build matrix, such as `node-version: ${{ matrix.node }}` (or `matrix.node || '22'`, or `matrix['node']`), is listed through the matrix: each literal entry of `strategy.matrix.node`, and each `include` entry that sets `node`, is skipped at its own line, once even when jobs share the list through a YAML anchor. A custom extractor can track them; a matrix of one version is better kept in a version file. An expression that reads no matrix key, and a matrix built by one (`${{ fromJSON(...) }}`), is not listed.

### actions.lock

A repository keeping `.github/workflows/actions.lock` (made by `gh actions-lock`) gets it regenerated in the same commit as an update to an action in a workflow the lockfile lists; if it cannot be regenerated, the update is held with the reason rather than opening a PR whose lock would be stale. [Lockfile maintenance](https://count-patchula.sweepy.dev/guide/lockfiles/#lockfile-maintenance) also relocks the refs that moved upstream in the workflows it lists. The Count never adds a workflow or an action to the lockfile, and repositories without the file — and workflows it does not list — are unchanged. In a listed workflow he adds no new step-level SHA pin, since the lockfile is the pin; an existing pin still upgrades, and reusable workflows still pin. See [the lockfile run](https://count-patchula.sweepy.dev/guide/lockfiles/#gh-actions-lock) for how the tool is invoked and [the departure](https://count-patchula.sweepy.dev/renovate/departures/#actions-lock-pinning) for why pinning differs there.

### Forgejo and Gitea Actions

Workflows in `.forgejo/workflows/` and `.gitea/workflows/` at the repository root are read the same way, by the same `github-actions` manager, and pinned and updated the same way. An action can be named by URL there, such as `https://code.forgejo.org/actions/setup-forgejo@v3`. A URL on `github.com` is looked up as GitHub tags; a URL on a Gitea or Forgejo host is looked up as `forge-tags` on that host, and the Count keeps the URL when he rewrites the ref. Hosts are recognised by name: `codeberg.org`, `gitea.com`, and hosts with a `gitea` or `forgejo` label such as `code.forgejo.org` or `git.forgejo.example.com`. Actions on other hosts are skipped.

A bare `owner/repo` ref is resolved by the runner against the instance’s default action host, which only the instance’s `app.ini` knows. The Count uses each project’s documented default:

| File | Bare `owner/repo` looked up on |
| - | - |
| `.github/workflows/`, `.gitea/workflows/`, `action.yml` | GitHub, Gitea’s default (`DEFAULT_ACTIONS_URL = github`) |
| `.forgejo/workflows/`, `.forgejo/**/action.yml` | `data.forgejo.org`, Forgejo’s default |

If your instance changes `DEFAULT_ACTIONS_URL`, write the actions it should not resolve this way as URLs. That is what Forgejo recommends anyway. Forge digests come from the host’s tag list, so only tag refs are pinned there: a branch ref such as `@main` on a forge is left alone. Runner labels in `.forgejo/` and `.gitea/` workflows name the instance’s own runners, so they are not updated.

## mise

Strings, arrays, version tables and `.tool-versions`. A task’s own `tools` are read too: under `[tasks.<name>]` in `mise.toml` and `.mise.toml`, and in a TOML task file that one of those configs includes with `task_config.includes`, by file, glob (`tasks/*.toml`) or directory (its TOML files at any depth). In a task file every top-level table is a task, so a table named `tools` is a task, not the tool section. The Count finds a task file through the config that includes it, but only reads files in the `mise` entry of [`files`](https://count-patchula.sweepy.dev/guide/configuration/#choosing-files-and-managers). That entry replaces the defaults, so keep them when you add the task file:

```pkl
files {
  new FileSet {
    manager = "mise"
    paths {
      "**/mise.toml"
      "**/.mise.toml"
      "**/.tool-versions"
      "tasks.toml"
    }
  }
}
```

The Count asks mise itself for each tool’s versions (`mise ls-remote --json`), so a tool is found wherever mise finds it: a short registry name such as `jq`, or an identifier for any backend that reads release metadata (`aqua`, `github`, `gitlab`, `forgejo`, `packslip`, `npm`, `pypi`, `cargo`, `go`, `gem`, `dotnet`, `conda`, `spm` and `core`). That includes every form of packslip source: `packslip:owner/repo`, `packslip:github.com/owner/repo`, a tool inside a monorepo (`packslip:github.com/owner/repo/tools/name`) and a tool on a publisher’s domain. An existing `mise.lock` is regenerated with the update. mise runs in a [sandbox](https://count-patchula.sweepy.dev/guide/sources/#mise-lookups), with the Count’s own pinned mise and none of your configuration.

A tool’s options, in its table (`rust = { version = "1.100.0", profile = "minimal" }`) or in brackets on its name (`"github:org/tool[bin=tool]"`), go to mise with the lookup, so it lists versions the way it installs them, `api_url` and `version_list_url` included. Some tools are refused for safety (plugin backends, Git-ref installs); see [mise lookups](https://count-patchula.sweepy.dev/guide/sources/#mise-lookups).

The options stay out of the tool’s branch name: `"github:org/tool[bin=tool]"` updates on `patchula/github-org-tool-1.x`. The same tool with options that only change how mise installs it (`os`, `depends`, `postinstall`, `lazy`, `lazy_bins`, and Rust’s `profile`, `components`, `targets` and `mr_boxington`) shares the plain tool’s branch, so `rust = "1.100.0"` in one file and `rust = { version = "1.100.0", profile = "minimal" }` in another move to 1.100.1 in one PR. Any other option can change which versions mise lists, so the same tool with other options gets a branch of its own, whose name keeps its options.

`http:` and `s3:` tools without `version_list_url` (or `version_prefix` for s3, also per platform under `platforms`) are skipped with a reason, not looked up: mise lists their versions only from those options, so there is nothing to ask. They are not counted as lookup failures.

## Cargo, Go and Terraform

Cargo reads workspace, development, build and target tables and renamed crates, and resolves from the nearest `Cargo.lock`. A member’s `workspace = true` refers to the nearest workspace root’s `[workspace.dependencies]` entry and [moves with it](#declarations-kept-at-a-root). `rust-toolchain(.toml)` pins Rust.

A `path` or `git` dependency is not looked up on crates.io. When it also names a `version` (the form a workspace crate uses to be publishable), it is skipped with a reason; the Count does not keep that version in step with the crate it points at. Without a `version` it is ignored. A dependency from an alternate `registry` is skipped with the registry’s name.

Go reads `require` blocks and single directives, plus the `go` directive (kind `go-directive`, the minimum language version) and `toolchain`. Indirect requirements are maintained too. A module a `replace` directive names, in `go.mod`, a `go.work` in its folder or above, or any module that workspace uses, is listed as skipped, and so is a module the workspace itself holds: its requirement is not what the build uses, and moving it past a version-specific replacement would take the build off the replacement. A `replace` directive, `go.work` or used module the Count cannot read fails every lookup of that module. A pseudo-version records the commit it names, in all three of Go’s forms (`v0.0.0-20240101120000-abcdef123456`, `v1.2.4-0.20240101120000-abcdef123456` and `v1.0.0-rc.1.0.20240101120000-abcdef123456`).

Terraform reads providers, registry modules and the provider lock with a real HCL parser; `.terraform-version` pins Terraform itself. A provider source or module address on another host, such as `app.terraform.io/acme/cloud`, is looked up in that host’s registry ([package registries](https://count-patchula.sweepy.dev/guide/sources/#package-registries)); a module’s `//subdirectory` is part of where it is used, not of what is looked up.

## Woodpecker

`woodpecker` reads the images of steps, services and the `clone` step, under `steps:` or the older `pipeline:` key, written as a map or a list. Only the root `.woodpecker.yml` or `.woodpecker.yaml` and files directly inside `.woodpecker/` are workflows. Images, plugins included, are pinned to digests by default like any other container image. An image defined once under a YAML anchor and aliased by several steps is one dependency, edited at the anchor; one merged into a step with `<<: *anchor` is read too.

An image built from a variable, such as `golang:${GO_VERSION}` from the workflow’s `matrix` or `${REGISTRY}/tool:1` from the environment, is only known when the workflow runs, so it is skipped.

## Copier

`copier` reads the template a project was generated from: `_src_path` and the tag in `_commit` of each answers file. Templates on GitHub (`gh:` included) are looked up as `github-tags`, and templates on GitLab (`gl:` included), Gitea and Forgejo as `forge-tags`, compared as `pep440` versions. SSH URLs are looked up over the same host’s API. A template on any other host, a local template, or a `_commit` that is not a release tag (such as `v1.4.0-5-g1a2b3c4`) is skipped.

A newer tag is reported, never proposed: the run summary, the JSON report under `notices`, the [dashboard](https://count-patchula.sweepy.dev/guide/dashboard/) and the [TUI](https://count-patchula.sweepy.dev/guide/tui/) show “template gh:acme/template: v1.4.0 → v1.6.0 available”, with a compare link where the host has one. The release-age wait and rules apply as usual, and the kind is `template`. The Count never opens a PR for it or edits `_commit`; see the [departure](https://count-patchula.sweepy.dev/renovate/departures/#copier-templates).

`patchula apply --copier` and the TUI’s Templates tab can run your own `copier update` on request; see [applying updates](https://count-patchula.sweepy.dev/guide/apply/#copier-templates).

## APM

`apm` reads the Git packages listed under `dependencies.apm` and `devDependencies.apm` in an [APM](https://microsoft.github.io/apm/) manifest, written `[host/]owner/repo[/path]#ref`. Packages without a host are on GitHub and are looked up as GitHub tags; packages on GitLab, Codeberg, Gitea and Forgejo hosts are looked up as forge tags. A virtual package’s path is kept, and the repository is the first two path segments.

These packages are agent instructions, so the Count treats them like actions. By default a tag is pinned to its commit, with the tag kept in a comment (`owner/repo#<sha> # v1.2.0`), and a commit pin with a tag comment is kept current the same way. The release-age wait applies, and nothing merges by default. A new tag is written exactly as upstream tagged it, so `v2.0` stays `v2.0` and never becomes `2.0.0`. Set `defaults { actionDigests = false }`, or a rule with `digest = false` for `managers { "apm" }`, to keep plain tags.

These entries are skipped:

- an entry with no `#ref`, which the lockfile pins;
- a branch, or a tag that is not a version, such as `#main`;
- a short commit, or a full commit with no tag comment;
- an entry in a flow-style list (`apm: [owner/repo#v1]`), where a tag comment would swallow the rest of the list;
- a full URL (`https://`, `ssh://`, `git@`), an object entry (`git:`), a registry or marketplace entry;
- a host with no tag source the Count can read, such as Bitbucket or Azure DevOps, or a host with a port.

Local paths are not dependencies. MCP and LSP servers are not read.

When `apm.lock.yaml` sits beside `apm.yml`, the Count refreshes it with `apm lock`; see [lockfiles](https://count-patchula.sweepy.dev/guide/lockfiles/).

## Pkl

`pkl` reads the `package://` URIs in the `amends`, `extends`, `import` and `import*` clauses and `import(…)` expressions of [Pkl](https://pkl-lang.org/) modules. Comments and imports inside other strings are ignored. The repository’s own `patchula.pkl` is not read: its imports must already be local modules.

`.pkl` is also the extension of Python pickles and of the Git LFS pointers that stand for large ones. A `.pkl` file that is not text or is over 1 MiB is left out unread, and one that never writes `package:` imports nothing and is not parsed. None of these fails the repository’s scan, as an unreadable file other managers select does, or turns off auto-merge and branch cleanup, as a warning does. A `.pkl` file that writes `package:` but is not valid Pkl is skipped with a warning.

A package is named by its URI without `package://` and the version, and looked up in the `pkl` [source](https://count-patchula.sweepy.dev/guide/sources/) under the semver scheme, which Pkl requires of package versions. Pkl reads a package from any host: it fetches the metadata of `package://<host>/<path>@<version>` from `https://<host>/<path>@<version>`. No host lists a package’s versions, so the Count reads them from the GitHub releases that publish the package. Three URI forms name that repository themselves:

| Package URI | Repository | Release tags |
| - | - | - |
| `package://github.com/<owner>/<repo>/releases/download/<tag>/<name>@<version>` | `<owner>/<repo>` | spelled like `<tag>` |
| `package://pkg.pkl-lang.org/github.com/<owner>/<repo>/<name>@<version>` | `<owner>/<repo>` | `<name>@<version>` |
| `package://pkg.pkl-lang.org/<project>/<name>@<version>` | `apple/<project>` | `<name>@<version>` |

`pkg.pkl-lang.org` sends every bare project path to an Apple repository, so the last form is looked up there. Only a package’s own tags count, so the packages of one repository, such as `pkl.toml` and `k8s.contrib` in `apple/pkl-pantry`, are separate packages with branches of their own.

A release URI writes the version twice, in the tag and after the `@`. Its package keeps the tag’s spelling with `%version%` in place of the version: `package://github.com/jdx/hk/releases/download/v2.9.0/hk@2.9.0` is the package `github.com/jdx/hk/releases/download/v%version%/hk` at `2.9.0`, and an update writes both copies, to `v2.11.1/hk@2.11.1`. Any other tag of that spelling counts as a release, so a tag such as `v2.12.0-final` reads as the prerelease `2.12.0-final`, which a stable version is not updated to.

Any other URI, on any host, is the package as written, such as `pkl.example.com/team/lib` for `package://pkl.example.com/team/lib@1.2.0`. The Count reads the metadata of the declared version, and its `packageZipUrl` names the repository: an asset of the GitHub release `https://github.com/<owner>/<repo>/releases/download/<tag>/…` whose tag holds the version once gives `<owner>/<repo>` and tags spelled like `<tag>`. A release counts only once the host serves metadata for it at `https://<host>/<path>@<version>`, describing that very version, so a host that lags behind its releases is never ahead of what Pkl can import. A package whose metadata downloads from anywhere else has no versions the Count can list, and its lookup fails with that reason. Only the version after the `@` is written; a tag elsewhere in the path stays as it is, and a release must be served at the path with only that version changed. Operator [credentials](https://count-patchula.sweepy.dev/guide/sources/#private-registries) go only to a host an operator entry covers.

A URI that pins a checksum, `@1.0.0::sha256:<hex>`, is updated with the new version’s checksum: the SHA-256 of the metadata the host serves for it, which Pkl checks the metadata it downloads against. Its releases are checked on the host the same way, and a release without a checksum is never proposed.

Rules select these dependencies by the source `pkl`, not `github-releases` as in Renovate, by the package above, or by the dependency name, which is the package’s own name: `hk`, so `dependencies { "hk" }` selects it.

These URIs are skipped:

- a host that is not a DNS name with an optional port, such as an IP literal in brackets or one with user information;
- a path with a query, an escape, or characters other than letters, digits and `._+@-`;
- a checksum other than `sha256:` and 64 lowercase hex digits, which Pkl rejects too;
- a version that is not a semantic version;
- a URI written with escapes or as a text block.

### PklProject

A `PklProject` declares a project’s packages in `dependencies`. The project is a Pkl module, and the Count never evaluates a repository’s Pkl, so he reads the dependencies from its text, in this form only:

```pkl
amends "pkl:Project"

dependencies {
  ["toml"] { uri = "package://pkg.pkl-lang.org/pkl-pantry/pkl.toml@1.0.0" }
  ["k8s"] {
    uri = "package://pkg.pkl-lang.org/pkl-k8s/k8s@1.0.1"
    checksums { sha256 = "75c6d66d…" }
  }
}
```

Each entry’s `uri` is a package URI, read and updated as above. A `checksums` block pins the SHA-256 of the package’s metadata, which Pkl checks, and takes the place of a `::sha256:` checksum, which Pkl refuses in a project’s URI. An update writes the new version’s checksum into the block, and is never proposed without one. The rest of the project, such as its `package` section or `evaluatorSettings`, is not read and may hold anything.

A project is skipped whole, with the reason, when its dependencies cannot be read without evaluating it: it amends a module other than `pkl:Project`, which may declare dependencies of its own, or `dependencies` holds anything but entries of the form above with plain strings, such as a computed URI, a spread, a generator or a second definition. These entries are skipped one by one:

- a local dependency, `["lib"] = import("../lib/PklProject")`: its lock entry and its packages come from the other project’s own `package` section and dependencies, which the Count does not read;
- a URI with a `::sha256:` checksum or a fragment, which Pkl refuses there;
- a URI or checksum written with escapes or as a text block;
- what a module’s package URI is skipped for.

When `PklProject.deps.json` sits beside the project, the Count regenerates it with `pkl project resolve`; see [lockfiles](https://count-patchula.sweepy.dev/guide/lockfiles/#pkl).

### Pkl packages move with their repository’s other dependencies

A tool often ships a Pkl package from the same repository: hk’s `hk` mise tool and its `pkg.pkl-lang.org/github.com/jdx/hk/hk` package, or the `github.com/apple/pkl-go` Go module and the `pkl.golang` package. When a repository declares both a Pkl package and another dependency from the same GitHub repository, their updates share the group named after it, `jdx/hk` or `apple/pkl-go`, on the branch `patchula/jdx-hk` (`patchula/major-jdx-hk` for majors).

The GitHub repository is read from the declarations alone, never from a registry:

| Source | Repository |
| - | - |
| `pkl` | the repository in the table above; a package found through its metadata names none |
| `go` | `github.com/<owner>/<repo>` and paths below it; vanity paths name none |
| `mise` | a tool without options that the Count looks up: an explicit `github:<owner>/<repo>` or `ubi:<owner>/<repo>` backend; another GitHub backend such as `aqua:` naming one repository; a registry shorthand such as `hk` whose backends in mise’s registry all name one GitHub repository; or a `go:github.com/<owner>/<repo>/…` tool such as `pkl-gen-go` |
| `github-releases`, `github-tags` | the package, `<owner>/<repo>` |

A package from a registry the repository names counts for no repository. Packages of one repository without another dependency from it, such as `pkl.toml` and `k8s.contrib` from `apple/pkl-pantry`, stay apart, and so do dependencies of one repository without a Pkl package among them.

Any group set for a dependency wins, `defaults.group` included, and `""` keeps it out:

```pkl
rules {
  new Rule {
    note = "Pkl packages get PRs of their own."
    select { sources { "pkl" } }
    apply { group = "" }
  }
}
```

Majors share one branch, and minors, patches and digests another, so each branch is decided on its own. A dependency is a member of a branch’s group when it is active, has no group set and can open pull requests (a Copier template, which is only reported, cannot) for every kind of update on that branch. The group forms only when Pkl packages and other dependencies are both members and every member has the same `commitPrefix` for all those kinds; otherwise each keeps its own branch, so the group never holds a pull request for conflicting prefixes. So `""` on either side, or on every Pkl package as above, separates them all. New pins never group. A group of your own named `jdx/hk` shares the branch, which is how to add something else to it. Security fixes still get a PR of their own, since `security.apply` sets `group = ""`.

## Containers and Kubernetes

Dockerfiles support global `ARG` substitution, continuations, `--platform` and stage aliases; `scratch` and references to earlier stages are skipped. Heredoc bodies are not instructions. As in BuildKit, a heredoc opens only at a whole unquoted word (`<<EOF`, `<<-EOF`, `<<"EOF"`), not at a here-string (`<<<word`) or inside quotes. Compose reads each service’s `image`. Kubernetes reads workload images, Kustomize its `images` and `helmCharts` transforms, Flux its repositories and releases (including `OCIRepository` `spec.ref.digest`, updating an existing digest or adding one beside `spec.ref.tag` when `imageDigests` is enabled), and Helm values files their `repository`/`tag`/`digest` maps. A pinned Kustomize image without a `digest` gains one beside its tag, since `digest` is Kustomize’s own field. A Helm values map’s `digest` key is filled or replaced when it is there, empty or not. One is added only when the chart those values belong to sits beside them in the repository (its `Chart.yaml` in the same directory) and reads the field: its own `values.yaml` or its `values.schema.json` declares it, a template action names it as `.Values.image.digest`, a template passes the image map to a helper as a `dict` key (`include "common.images.image" (dict "imageRoot" .Values.image)`) and the helper reads `.imageRoot.digest`, or a template runs a helper with its own `.` or `$` (`include "app.image" .`) and the helper reads `.Values.image.digest`. A `{{ block "app.image" . }}…{{ end }}` counts as a definition of `app.image` and a call of it in place, so its body reads the values it is given. Helm parses every template in the chart and its subcharts into one set, and when a helper is defined more than once, only the definition Helm parses last runs: the one closest to the top chart, and at one depth the one whose path, by chart name or dependency alias, sorts first. That definition is the one whose reads count, which also decides whether a later `define` replaces a `block`’s body. Comments, text outside `{{ }}`, `NOTES.txt`, and reads under a `with` or `range` that moves `.` do not count; their `{{ else }}` branches see the outer `.` again and do. A map reached only through a function’s result, such as `with (merge …)`, or handed to a helper any way other than as a `dict` key or the whole `.`, does not count either. A map under a subchart’s values key, such as `prometheus-node-exporter.image`, is the subchart’s `image`: it gains the field when the subchart, unpacked under `charts/`, reads it by the same rules in its own templates, `values.yaml` or `values.schema.json`. The key is the dependency’s `alias` in `Chart.yaml` (or `requirements.yaml`), or else the subchart’s own `name`. A field under `global` counts when any subchart reads it there. A vendored subchart’s own values file, such as `app/charts/web/values.yaml`, gains the field when the subchart’s templates read it, using helpers from anywhere in the tree of the outermost chart that vendors it, such as a Bitnami-style `charts/common`. A packaged subchart (`charts/*.tgz`) is not read, and neither is a directory under `charts/` whose name starts with `_` or `.`, which Helm skips. A chart whose schema allows no unlisted keys would refuse `helm install` over a field it does not list, so the field is not added either when the schema reaches it through a keyword the Count does not evaluate, such as `allOf`, `anyOf`, `oneOf`, `if`, `patternProperties` or a `$ref` outside the file (a `#/…` one is followed), and one whose templates never read it would deploy the tag alone. Otherwise, including every `HelmRelease`’s inline values, the image is not pinned: its updates move the tag, and the report lists the pin as skipped with the reason. To pin it, add an empty `digest:` key where the chart reads one. ConfigMaps, Secrets and annotations are not dependencies. Templated images need concrete values; Helm templates are not rendered. A version or image reached through a YAML alias is edited once, at its anchor; one whose aliases serve different packages is skipped with the reason, since no one update suits every use, as is a tag anchor shared by images whose digests sit in separate fields, since moving it would leave a digest behind. A `digest` key reached through an alias is added only when the chart reads it at every alias. Image updates keep the tag’s [variant](https://count-patchula.sweepy.dev/guide/versioning/#docker-tags).

### Generated Flux bundles

A file that starts with `# This manifest was generated by flux. DO NOT EDIT.` is the output of `flux install --export`, which `flux bootstrap` commits as `gotk-components.yaml`. Its CRDs, RBAC and controllers all belong to the Flux release in its `# Flux Version:` header, and a controller from a newer release can need CRDs the old bundle doesn’t have. So the bundle moves as one piece:

- `flux` reports the header as the `fluxcd/flux2` dependency, looked up from its GitHub releases. A new release opens one PR that regenerates the whole file with `flux install --export` at that release, for the components in the `# Components:` header. The PR carries the Flux release notes.
- The controller images inside the bundle, whichever manager reads them (`kubernetes`, `helm-values`), are never updated on their own: no new tags, no digest updates and no security fixes. They still appear among the detected dependencies, and a newer controller is listed under “Newer versions not proposed” as moving with `fluxcd/flux2`. When the `flux` manager doesn’t read the file (it is off, or its `files` patterns leave the file out), or the header names no exact release (a release candidate such as `v2.10.0-rc.1`), nothing regenerates the bundle and the images stay as they are; the reason says what regeneration needs.
- When an image in the bundle has a fix (an [image rebuild advisory](https://count-patchula.sweepy.dev/guide/security/#container-image-rebuilds)), the Count reads which controller releases the newest Flux release ships, from its manifests in `fluxcd/flux2`. If it ships that controller at or past the fixing release, the Flux update is a security update, labelled and under `security.apply` rather than the routine wait. A controller is often released before the Flux release that bundles it; until then the fix stays listed with the controller and the Flux update stays routine.
- When the old bundle pinned its images to digests, the regenerated one is pinned too, to each new image’s multi-arch index digest.

The header doesn’t record other install options, such as `--registry`, `--network-policy`, `--toleration-keys`, `--cluster-domain` or `--watch-all-namespaces`. Before regenerating, the Count runs `flux install --export` at the bundle’s current release and compares the result with the file, ignoring digest pins. If they differ, the bundle was generated with options the header doesn’t record, or edited since, and the update is blocked with that reason on the dashboard instead of dropping them. Regenerate such a bundle by hand. Kustomize patches kept beside the bundle are untouched and apply to the regenerated file.

`patchula apply` doesn’t regenerate bundles: it lists the Flux update as skipped and leaves it to the Count’s pull request. The Flux CLI runs as fluxcd’s official release binary through mise’s `aqua` backend. `flux install --export` prints the manifests built into that release and reads nothing from the repository.

## Python

`pyproject` reads PEP 621 dependencies and optional dependencies, PEP 735 dependency groups, uv’s dev, constraint and override dependencies, and Poetry’s dependencies and groups. Edits touch only the version specifier. URL requirements, unversioned names and Poetry `git`/`path` sources are skipped. Names are PEP 503 normalised and resolved from `uv.lock` or `poetry.lock`; `.python-version` pins CPython. Neither uv nor Poetry may build a package to lock it, so an update whose lock would need a build (a workspace package with `dynamic` metadata, or a dependency with only a source distribution) is skipped with the reason; see [lockfiles](https://count-patchula.sweepy.dev/guide/lockfiles/#uv-poetry-pdm-and-bundler-run-no-repository-or-package-code).

pip requirements files are not maintained: each is listed as skipped, with the reason. pip takes each package from whatever index the file’s options, the files it includes and the environment name, and the Count cannot settle that for certain from the repository; a guess could propose someone else’s package of the same name. Move the project to uv (`uv init --bare`, then `uv add -r requirements.txt`) to have it maintained. See [pip requirements files](https://count-patchula.sweepy.dev/renovate/departures/#pip-requirements).

## GitLab CI

`gitlabci` reads the `image` and `services` of every job, `default` and hidden `.template` jobs, as a string or as a `name:` mapping. Images are pinned to digests by default, like images everywhere else, and GitLab’s own registry, `registry.gitlab.com`, is read with the anonymous tokens gitlab.com issues. It also updates CI/CD component references (`include: - component: gitlab.com/components/sast/sast@3.4.0`) from the component project’s tags. `~latest` and commit SHAs are left alone.

`gitlabci-include` updates the `ref` of `include: project:` entries from that project’s tags. Refs and component versions are written as the tag is named, since GitLab loads them by exact name. Entries without a `ref`, branch names and commit SHAs are left alone, and so are `local`, `remote` and `template` includes. A ref or component reference shared through a YAML anchor is skipped, since one tag may not exist in every project that uses it; an anchored image is edited once, at the anchor.

Project includes resolve on `gitlab.host`, gitlab.com by default, and so does `$CI_SERVER_FQDN` (or `$CI_SERVER_HOST`) at the start of a component reference. A self-hosted instance works when it has a `gitlab` label in its host name, such as `gitlab.example.com`, whether it is named in the component reference or in config:

```pkl
gitlab { host = "gitlab.example.com" }
```

Other GitLab CI variables are not expanded. An image such as `$CI_REGISTRY_IMAGE:latest` or `${CI_DEPENDENCY_PROXY_GROUP_IMAGE_PREFIX}/node:22` is skipped.

## Helm, pre-commit and devcontainers

`helm` reads `Chart.yaml` dependencies from HTTPS and `oci://` repositories, and those in the deprecated `requirements.yaml` beside a `Chart.yaml`, where a chart of `apiVersion: v1` lists them. An `oci://` chart is an image to the Count: its registry digest follows `imageDigests`, like a container image’s, whether it is declared in `Chart.yaml`, Kustomize `helmCharts` or a Flux source. `pre-commit` updates each hook repository’s `rev` on GitHub, GitLab, Codeberg and Gitea/Forgejo hosts, skipping `local` and `meta` hooks and bare commit pins. A `rev` is written as the tag is named (`v1.0` becomes `v1.1`, not `v1.1.0`), since pre-commit checks it out by that name. pre-commit accepts any git ref as a `rev`, so a branch name or another ref that names no version is left alone: there is no version to look up, and no error. `devcontainer` reads the `image` and OCI `features`, whose version lives in the feature key (`ghcr.io/devcontainers/features/node:1`).

## Maven and Gradle

Maven reads `parent`, `dependencies`, `dependencyManagement`, build `plugins`, `pluginManagement` and `extensions`. A `${property}` version is edited where the property is defined.

Both look each artifact up in the repositories the build declares, in the order Maven or Gradle tries them: profiles, parents, settings and mirrors for Maven; project, settings, plugin and buildscript repositories and content filters for Gradle. The rules are in [package registries](https://count-patchula.sweepy.dev/guide/sources/#package-registries).

Gradle reads version catalogs, literal coordinates, `group:/name:/version:` notation and `id "…" version "…"` plugins in every Gradle script. It resolves versions kept in `ext` blocks, `def`/`val` locals, `extra[...]`, map literals such as `versions += [jackson: "2.15.0"]`, and `gradle.properties`.

Gradle skips anything under `src/` except `src/main/`, since test resources hold fixtures; a name defined twice; computed values; the project’s own `version`; and packages reached through several variables, which are deliberate parallel versions such as Kafka’s compatibility pins. A script with a comment, string or template that never ends is skipped with a warning, since Gradle could not compile it either; its comments are found by the same lexer that reads its repositories. The wrapper’s `distributionUrl` upgrades, and a recorded `distributionSha256Sum` is replaced with Gradle’s published checksum. A `distributionUrl` on a mirror, such as an Artifactory or Nexus proxy, gets the checksum Gradle publishes on `services.gradle.org` for the same file name (`gradle-<version>-bin.zip` or `-all.zip`): a mirror serves Gradle’s own bytes, and the wrapper checks them against that checksum when it downloads. The mirror is never contacted. A wrapper without a `distributionSha256Sum` line gets none, as with Renovate.

Versions keep their release variant: Guava’s `33.4.8-android` never becomes `33.7.2-jre`.

## .NET, Ruby and PHP

`nuget` reads `PackageReference`, `PackageVersion` and `GlobalPackageReference` items, local tools and the SDK in `global.json` (feature-band releases only). `$(Property)` and floating `*` versions are skipped. Under central package management a `PackageReference` with no version refers to the nearest `Directory.Packages.props` entry, matched without regard to case, and [moves with it](#declarations-kept-at-a-root); one that file does not list declares nothing. Each package is looked up in every package source `nuget.config` gives a restore, or the ones `packageSourceMapping` maps it to; see [package registries](https://count-patchula.sweepy.dev/guide/sources/#package-registries). A `packages.lock.json` is not regenerated, because `dotnet restore` evaluates MSBuild code from the repository and its packages: an update to a project with one is skipped with that reason (see [what is refused](https://count-patchula.sweepy.dev/guide/lockfiles/#what-is-refused)).

`bundler` reads `gem "name", "requirement"` lines and the `ruby` directive, resolving from `Gemfile.lock`, plus `.ruby-version`. Gems from git, a path or a forge (`git:`, `path:`, `github:` and the like, or a `GIT` or `PATH` section of the lock) are listed as skipped; where each gem comes from is in [package registries](https://count-patchula.sweepy.dev/guide/sources/#package-registries). Gems with two requirement strings are skipped too, and so are gems with no requirement at all: any version satisfies them, so only [lockfile maintenance](https://count-patchula.sweepy.dev/guide/lockfiles/#lockfile-maintenance) moves them. Evaluating a Gemfile runs Ruby, so Bundler never sees the repository’s: `bundle lock` runs on a Gemfile the Count renders from its reading, outside the checkout. An update whose Gemfile needs a form the Count does not render (a `gemspec`, a gem from git, a path or a forge, or any line it does not read), or whose `Gemfile.lock` has a `GIT`, `PATH` or `PLUGIN SOURCE` section, is skipped with the reason; see [lockfiles](https://count-patchula.sweepy.dev/guide/lockfiles/#uv-poetry-pdm-and-bundler-run-no-repository-or-package-code).

`composer` reads `require` and `require-dev`, skipping platform packages (`php`, `ext-*`, `lib-*`), `dev-` branches and `*`. A package is looked up in the Composer repositories `composer.json` configures, in Composer’s order and with their `canonical`, `only` and `exclude` settings, then Packagist, unless `composer.lock` records where it came from. Packages a path or inline repository provides, or the lock records from a VCS or other non-registry repository, are listed as skipped; see [package registries](https://count-patchula.sweepy.dev/guide/sources/#package-registries). `composer update` runs with `--no-install --no-scripts --no-plugins`, so no repository code runs. The PHP version constrains resolution; extension requirements do not, since they describe where the app is deployed, not the runner.

## Nix

`nix` reads the `flake.lock` next to each `flake.nix`. Every direct input of the root flake is a dependency named after the input, such as `nixpkgs`, with its fully qualified root URL as the package (`https://github.com/NixOS/nixpkgs`) and the reference it was written with as the current value (`github:NixOS/nixpkgs/nixos-unstable`). Inputs that only `follows` another one have no lock of their own and are not dependencies. Transitive inputs move with the input that brings them in.

The Count asks nix what each reference points at now, with `nix flake prefetch`, and proposes the new revision as a `digest` update dated by the commit’s `lastModified`, so the release-age wait applies. The branch, `patchula/nix-nixpkgs` (`patchula/nix-dev--nixpkgs` for a flake in `dev/`), runs `nix flake update nixpkgs`, and the lock nix writes is the whole change; `flake.nix` is never edited. An input pinned to a tag or commit in its URL, such as `github:numtide/flake-utils/v1.0.0`, does not move, the same as with nix itself.

Every input type nix fetches without running anything is followed: `github:`, `gitlab:` and `sourcehut:` (on their public hosts or a `host=` of their own), `flake:` registry names, and `git+https`, `tarball+https` and `file+https` URLs, on any host. A tarball or file input moves when what its URL serves changes. Some are skipped, each with its reason:

- `path:` and `git+file:` inputs that leave the repository; a `path:` input inside it changes with the repository, so it is skipped too.
- ssh URLs, which would authenticate with the machine’s own keys.
- plain `http`, which has no transport security: anyone on the network path could swap what nix locks.
- Mercurial (`hg+https`), which nix fetches by running `hg`, a binary the Count’s nix runs do not ship. How nix runs, and how the inputs it fetches are checked, is under [Lockfiles](https://count-patchula.sweepy.dev/guide/lockfiles/#nix).

## Kinds

Every dependency has a kind, which rules can select: `production`, `development`, `peer`, `optional` and `build` for packages; `action`, `reusable-workflow` and `runner` for workflows, with GitLab CI includes and components as `reusable-workflow`; `container-image`; `tool` and `toolchain` for mise tools and pinned toolchains; `go-directive`; `provider` and `module` for Terraform; `chart` for Helm; `template` for Copier; `flake-input` for Nix; and `transitive` for a [vulnerable lockfile-only package](https://count-patchula.sweepy.dev/guide/security/#lockfile-only-packages). [Reference data](https://count-patchula.sweepy.dev/guide/configuration/#reference-data) also has the kind `reference-data`, on top of its own.
