Skip to main content
Version: 0.3.0

Module Dependency Lock File

The lock file (invowkmod.lock.cue) records the exact versions of all resolved module dependencies, ensuring reproducible builds across machines and over time.

It is auto-generated by invowk module sync and invowk module update.

Example Lock File

version: "1.0"
generated: "2025-01-10T12:34:56Z"

modules: {
"https://github.com/example/common.invowkmod.git": {
git_url: "https://github.com/example/common.invowkmod.git"
version: "^1.0.0"
resolved_version: "1.2.3"
git_commit: "abc123def4567890"
alias: "common"
namespace: "common"
}
}

Root Fields

FieldDescription
versionLock file format version
generatedTimestamp when the lock file was created
modulesMap of module keys to locked module entries

Module Entry Fields

Each entry in modules contains:

FieldDescription
git_urlGit repository URL
versionOriginal version constraint from invowkmod.cue
resolved_versionExact resolved version
git_commitCommit SHA for the resolved version
aliasNamespace alias (if set)
pathSubdirectory path (if set)
namespaceComputed namespace for commands

Module Keys

The key in the modules map is derived from the Git URL and optional path:

modules: {
"https://github.com/example/monorepo.invowkmod.git#modules/cli": {
git_url: "https://github.com/example/monorepo.invowkmod.git"
path: "modules/cli"
}
}

Usage Notes

  • Commit invowkmod.lock.cue to version control for reproducible builds.
  • invowk module add writes the lock file automatically (no need to run invowk module sync afterward).

Common Workflows

# Resolve and lock
invowk module sync

# Commit the lock file
git add invowkmod.lock.cue
git commit -m "Lock module dependencies"