Package Manager
Nubo includes a package manager for adding, locking, downloading, resolving, and deleting packages.
The package manager uses two project files:
| File | Purpose |
|---|---|
_nubo.yaml | Human-facing package/project metadata and direct dependencies. |
lock.yaml | Exact dependency lockfile with full commit hashes and package checksums. |
Packages are downloaded into a global cache under the user’s home directory.
~/nubo/packages/A package is usually added from a Git URL-like package path.
nubo get github.com/nubolang/colorAfter adding, Nubo stores package metadata in _nubo.yaml and exact locked data in lock.yaml.
| Page | Description |
|---|---|
| Project Files | _nubo.yaml and lock.yaml. |
| Adding Packages | How nubo get resolves, clones, caches, and locks packages. |
| Downloading Packages | How nubo download restores dependencies from lock.yaml. |
| Import Resolution | How Nubo maps imports to cached packages. |
| Deleting Packages | How nubo del removes packages safely. |
| Cache | Global package cache layout and validation. |
| Package Authoring | Creating a package with nubo init. |
| Troubleshooting | Common package manager problems. |
Basic Workflow
Section titled “Basic Workflow”Create package metadata:
nubo initAdd a package:
nubo get github.com/nubolang/colorUse the package:
import color from "@nubolang/color"
println(color.green("success"))Download all locked dependencies later:
nubo downloadDelete a package:
nubo del github.com/nubolang/colorImportant Idea
Section titled “Important Idea”nubo get uses a remote source like:
github.com/nubolang/colorBut the package name stored in the lockfile is:
nubolang/colorSo imports are resolved by package name:
import color from "@nubolang/color"The package cache still remembers the original domain and remote source.