runtimeinv

package
v1.18.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 26, 2026 License: Apache-2.0 Imports: 16 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package runtimeinv inventories language runtime installs (node, python, php, java, go, ruby, deno, bun, dotnet) on disk, independent of how they were installed: version managers, package managers, installers, zips and runtimes bundled inside other apps. Discovered binaries are never executed; versions come from files the install ships, the PE version resource, or the install path.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ScanResult

func ScanResult(ctx context.Context, exec executor.Executor, skipper *tcc.Skipper) *model.RuntimeScanResult

ScanResult runs a scan for the logged-in user and packages it for telemetry.

Types

type Scanner

type Scanner struct {
	// contains filtered or unexported fields
}

Scanner discovers runtime installs for the logged-in user and the machine.

func NewScanner

func NewScanner(exec executor.Executor, home string) *Scanner

NewScanner returns a scanner for the given user home ("" = resolve from the logged-in user).

func (*Scanner) Scan

func (s *Scanner) Scan(ctx context.Context) (runtimes []model.RuntimeInstall, truncated bool, truncatedRoots []string)

Scan walks all roots and returns the inventory, sorted by runtime then path. truncated reports an incomplete walk. truncatedRoots is non-empty only when every truncation was a per-root budget hit, so installs outside those roots are known to be complete; on a deadline or the global cap it is nil.

func (*Scanner) WithSkipper

func (s *Scanner) WithSkipper(sk *tcc.Skipper) *Scanner

WithSkipper applies the run's TCC-protected / network-volume exclusions, so the walk never reads a directory (or resolves into one) the scan settings exclude. A nil skipper skips nothing.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL