-f flag scans the workspace for missing symlinks and recreates any that are absent, pointing them at the correct locations within the specified version’s directory.
Syntax
The Go version to repair in
X.Y.Z format (e.g. 1.23.4). The version must already be installed in your workspace.Examples
What it does
Scan the workspace for symlinks
igo reads the workspace directory and finds all existing symlinks. If no versions are installed, the command exits.
Check for missing symlinks
igo checks whether the
bin, path, and root symlinks are present in the workspace and maps them to their corresponding environment variables:| Workspace symlink | Environment variable | Expected target |
|---|---|---|
~/go/bin | GOBIN | ~/go/versions/<version>/go/bin |
~/go/path | GOPATH | ~/go/versions/<version> |
~/go/root | GOROOT | ~/go/versions/<version>/go |
Recreate missing symlinks
For each missing symlink, igo creates it pointing at the correct path within the version directory. Existing entries that are already present are left unchanged.
When to use it
- After a failed
igo -irun left the workspace in a partial state. - After manually moving or deleting files inside the workspace.
- After a disk-full error interrupted an installation.
- When
igo -eshows❌next to a symlink.