Updating the Depot CLI
On MacOS and Linux systems, you can run the depot update command to update Depot CLI to the latest version available. (Windows is not supported due to the inability to replace an executable file in use).
New releases are stored in GitHub release assets, so you'll need to provide a valid github token, either using the --github argument, setting the environment variable GITHUB_TOKEN before running the update command, or by having a valid .npmrc or .yarnrc file containing a token in the current working directory, or path upward from there, to your root '/' path you are executing the CLI from.
Use of the --github argument should be on command lines starting with a space character in order to be omitted from the .history / shell history for security reasons.
By default main releases are searched. If you wish to search for develop branch releases, pass in the --develop argument. If you are running a main release, e.g. 7.3.0 and tried to update to a newer develop version, e.g. 7.3.0-develop.xyz, then the semver checking will not consider this an update. You should therefore add the --forceupdate argument to the command to force the update regardless of semver checking.
E.g.
depot update --develop --forceupdate
The --nosave argument can be used to perform an update 'dry run'. The command will output the paths that would be used for the source update version and the replacement path of the current Depot CLI binary.
The depot update command cannot be used if you are executing it directly from the node project / source. The command will only work when using the packaged, executable Depot CLI binary.
Valid GitHub token scope required
If using a Fine-grained access token, it must have the Contents -> Read-only scope to be able to download the release assets from the stage-depot GitHub repository. The Resource Owner should be set to the correct GitHub organization owning the stage-depot repository.
If using a classic token, it must have the full repo scope to be able to download the release assets from the stage-depot GitHub repository.