installupdate

package
v0.12.0 Latest Latest
Warning

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

Go to latest
Published: Aug 12, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package installupdate manages the npm-bootstrap updater lifecycle.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AfterCommand

func AfterCommand(cfg config.Config, errOut io.Writer, noUpdate, noInteractive bool)

AfterCommand shows pending status and schedules a due bootstrap update. Errors are intentionally reported to stderr and never change command status.

func DueAt

func DueAt(now time.Time) int64

DueAt returns the next automatic-check time used by tests and diagnostics.

func RunCheck

func RunCheck(manifest *Manifest, jsonOutput bool, out, errOut io.Writer) error

RunCheck executes an explicit foreground update check.

func StartDetached

func StartDetached(manifest *Manifest, force bool) error

StartDetached runs the copied bootstrap helper after this process exits.

func StatePath

func StatePath() string

StatePath returns the cross-platform npm update state file.

Types

type Manifest

type Manifest struct {
	Distribution string `json:"distribution"`
	Version      string `json:"version"`
	TargetDir    string `json:"targetDir"`
	Node         string `json:"node"`
	NPM          string `json:"npm"`
	Helper       string `json:"helper"`
	// contains filtered or unexported fields
}

Manifest describes an npm-bootstrap installation.

func LoadBootstrapManifest

func LoadBootstrapManifest() (*Manifest, error)

LoadBootstrapManifest returns the manifest adjacent to the running binary.

func (*Manifest) ManifestPath

func (m *Manifest) ManifestPath() string

ManifestPath returns the source path for the loaded manifest.

Source Files

  • lifecycle.go

Jump to

Keyboard shortcuts

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