---
title: "Logins and sharing"
description: "Log in once inside any environment, and every environment that shares the login is logged in."
---

> Documentation Index
> Fetch the complete documentation index at: https://regent.c4n.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Logins and sharing

Environments can share agent logins and settings, and the GitHub CLI login. Log in inside any
of them and the others pick it up.

```sh
regent create dev --share claude-code,gh
regent share ls
```

```
ITEM         NAME              LOGGED IN                          SHARED BY
claude-code  Claude Code       ✓                                  dev,api
codex        Codex CLI         no · codex login (inside)          –
gh           GitHub CLI login  ✓                                  dev,api
```

Shared items live on this Mac in `~/.local/share/regent/shared`, private to you, and are
mounted only into the environments that share them. Anything running in such an environment
can read them.

| Command | What it does |
| --- | --- |
| `regent config set share claude-code,gh` | The default for new environments |
| `regent reset NAME --share none` | Change what one environment shares |
| `regent share forget ITEM` | Delete the shared login: everyone sharing it is logged out |

## Git identity

The git identity isn't shared per environment: every environment uses the one in
`regent config`:

```sh
regent config set git 'Ada Lovelace <ada@example.com>'
```

Source: https://regent.c4n.dev/docs/guides/sharing/index.mdx
