Gitpod CLI
Learn about the Gitpod CLI, a CLI tool used inside Gitpod workspaces. Also, learn about how you can use it to manage your workspaces and smooth your developer experience.
gp
CLI that runs in all workspaces? You’re looking for the Gitpod Workspace CLI.
The Gitpod CLI is a command line interface for creating, managing and connecting to Gitpod workspaces either from your own device, or in automation, such as continuous integration.
Installation
To download and install the CLI, run the following commands:
Homebrew (macOS and Linux)
Direct Download (macOS, Linux, Windows)
We also offer direct download links to the binaries, which are portable and can be installed anywhere on your system. Note that this does not impact the auto-update functionality of the CLI.
Login with the Browser
When first starting getting started with the CLI, you’ll need to login. The gitpod login
command will redirect you to your default browser where you can authenticate, before being redirected back to the CLI.
Login with an Access Token
Logging in with a token is particularly useful when you want to use the CLI in automation, such as in a CI pipeline or a remote server (including your Gitpod workspaces). To log in with an access token, proceed like so:
Login to Enterprise
To log in to a host which is not gitpod.io, you can use the --host
flag:
Choose an Organization (optional)
When you run gitpod whoami
and the Organization you see is not the one you want to work with, you can change it as follows:
Create and open a workspace in your editor
Create and connect to a workspace with SSH
--editor
to override your default editor selection. You can list possible editor options with gitpod workspace list-editors
.Auto-update
You can print the current CLI version with gitpod version
. The CLI automatically checks for updates and will notify you if a new one is available. You can disable this behavior by running gitpod config set --autoupdate=false
.
To update, use gitpod version update
.
Telemetry
By default, the CLI sends anonymous telemetry data to Gitpod, for both Dedicated and Cloud customers. We send this data so we can improve the experience of the CLI.
An example telemetry event looks like this:
Data the Gitpod CLI does send
- The CLI command name.
- Exception information.
- An anonymous machine ID.
Data the Gitpod CLI does not send
Any argument, flag or configuration, which includes (but is not limited to):
- Personally identifying information.
- Login information.
- Repository names.
- Branches.
- SSH or connection information.
Disabling telemetry
If you wish to disable telemetry, you can do so by running the following. The CLI also respects the DO_NOT_TRACK environment variable.
Was this page helpful?