Skip to main content
Skip to main content

b cache

Manage the local git cache used for env file syncing. The cache stores cloned git repositories to avoid re-cloning on every sync.

Subcommands

CommandDescription
b cache cleanRemove all cached git repositories
b cache pathPrint the cache directory path

b cache clean

Remove all cached git repositories and report freed disk space.

Usage

b cache clean

Examples

# Remove cached repos
b cache clean
# Output: Removed /home/user/.cache/b/repos (42.5 MB freed)

# If cache is already empty
b cache clean
# Output: Cache is already clean (nothing to remove)

b cache path

Print the cache directory path. Useful for scripting or inspecting the cache manually.

Usage

b cache path

Examples

# Print cache path
b cache path
# Output: /home/user/.cache/b/repos

# Use in scripts
du -sh $(b cache path)

Cache location

The default cache directory is ~/.cache/b/repos/. Each upstream git repository is stored as a bare clone, keyed by the provider reference.

Flags

FlagDescription
-h, --helphelp for cache

Global Flags

FlagDescription
-c, --config stringPath to configuration file (current: /home/fentas/github/fentas/b/.bin/b.yaml)
--forceForce operations, overwriting existing binaries
-q, --quietQuiet mode
-v, --versionPrint version information and quit
Was this section helpful?