Skip to main content
Use --remote NAME to choose storage for one command. Add routes when different paths should use different remotes automatically. A maps a subtree to storage. For a first remote, start with Set up a remote.
Routing is experimental. Routes choose storage; they do not restrict access, move existing objects, or change file ownership.

Remote selection at a glance

Gat uses the first applicable choice:
  1. An explicit --remote NAME.
  2. The route with the most-specific matching path.
  3. The configured default remote.
Route names do not affect precedence. Paths match by segment: models covers models/a.bin, but not models-old/a.bin.

Set up multiple remotes

Initialize Gat first. Replace these buckets and regions with yours, and configure provider credentials.
1

Add storage locations

Adding a remote never selects a default.
2

Route the model paths

The nested models/private route wins over models.
3

Review and share the settings

Project settings are shared through Git. Each user still needs storage credentials. Use --local for machine-specific overrides.

Transfer across several remotes

Normal transfers now follow the routes. Use --path to narrow the operation:
gat sync --fetch follows the same routing. Omit --path to use your default selection, or --path . to include all repository paths.

Override routing for one command

After configuring a remote named backup, choose it without changing routes:
A bare gat status --remote checks each path’s routed remote. gat status --remote backup checks every selected path against backup.

Routes do not copy existing objects

To move repository-owned model objects to another store, populate that store before changing the route:
1

Fetch from the existing storage

This fills the local cache using the current routes.
2

Upload and verify the new store

Confirm the required objects are present before continuing.
3

Change the route and commit

More-specific routes, such as models/private, still win. Change those separately if their storage should move too.
These commands copy the current selected objects. To preserve older revisions, include the required history selections when fetching and pushing. Keep the old store until you have verified every version you need. A selected remote with missing objects does not trigger an automatic search of other stores.

Inspect routing

The * row in the route listing represents the ; it is not a removable route. Changing the default affects only paths without a route. Removing a route keeps the remote and tracked files.

Advanced behavior

Identical bytes share one cached object. A downloads it once, using the first selected path’s remote. Push can publish the same object to each remote required by the selected paths.
Add a complete definition with the same name in local configuration:
Reads use the effective configuration. Updates and removals must target the defining scope. See Config inheritance.
A route can serve repository-owned or mounted files. It changes storage selection, not ownership. Moving or removing a mount does not move or remove its route. See Consuming Gat assets.

Remote commands

Manage named storage locations.

Route commands

Manage path-based storage rules.