# Join a team

A teammate invites you on GitHub and sends you one command. Joining clones the team repository and adds you to the roster. It installs nothing.

## The command

```sh
npx -y terum-skills@latest setup <org>/<repo>
```

You need git. You do not need the GitHub CLI. GitHub emails you its own repository invitation separately.

`setup` with a target joins, then continues with the rest of the wizard: a project, your existing skills, the evals offer, the hooks and the terum-skills skills. On macOS and Windows, setup opens the desktop app and the join continues there. For the join on its own:

```sh
npx -y terum-skills@latest team join <org>/<repo>
```

`team join` ends with one offer of the session-start hook. It does not place the eight skills or offer the edit hook; only `setup` does.

`<org>/<repo>` is the GitHub form, and the only one that can accept an invitation through GitHub's API. Any other git URL is joined with your configured git credentials and no invitation step.

## What joining does

1. Checks `gh`, and offers `gh auth login` if it is installed but logged out.
2. Accepts the invitation, or has you accept it in a browser.
3. Clones the repository to `~/.terum/skills/teams/<team>/` and arms its push guard. The team name defaults to the repository name.
4. Asks for your identity: GitHub login, team handle, name and email.
5. Sets `user.name` and `user.email` inside the clone only. Your global git config is untouched.
6. Pushes your roster entry, `people/<handle>.json`, as one commit to `main`.
7. Records the team in `~/.terum/skills/config.json` and prints the member list.

## Accepting the invitation

With a logged-in `gh`, join lists your pending repository invitations and accepts the matching one. Already having access is not a failure, and neither is finding no invitation: join continues, and if the clone then cannot reach the repository, the person who invited you has not added you on GitHub yet.

Without `gh`, or with it logged out, join sends you to the browser:

```text
Accept the invitation at https://github.com/<org>/<repo>/invitations before continuing.
```

Accept it there first, then answer yes to `Continue after accepting the invitation?`. Answering no cancels the join and writes nothing.

## Your handle

Your handle is how the team repo names you: your people file, the author line on skills you publish, and `install member <handle>`. It is 1 to 39 letters, digits and single internal hyphens, stored lowercase. It defaults to the handle this machine already uses, or to your GitHub login. If an active member already holds it, you are asked again, up to three attempts.

Once this machine is bound to the team, the handle is fixed. Joining the same team from another machine reclaims your existing roster entry when the GitHub login or the email on it matches.

## Joining installs nothing

Join writes your people file, the clone, the git identity inside the clone, and the team binding. It does not place a single skill on your machine, and a team can never place one on your behalf. You choose what to install:

```sh
npx -y terum-skills@latest ls
npx -y terum-skills@latest search <term>
npx -y terum-skills@latest install <skill>
```

`ls` lists the members and the shared skills from your clone, offline. `install` copies the latest version of a skill into Global (`~/.claude/skills`) or into a project you registered. See [Install and manage](https://www.terum.ai/docs/install-and-manage).

## One team per machine

A machine is on one team at a time. Any command that would bind a second team refuses before doing anything and names the `team leave` command to run first.

### Leaving

```sh
npx -y terum-skills@latest team leave <name>
```

Leaving is local only. It lists what will go and asks once, then removes every skill this team placed, the clone, the team's cache and run files, and the config entry. When it was the last team on the machine, it also removes the session hook and your tool approvals. A placed folder you edited, or a clone with unpushed work, is moved to quarantine instead of deleted. Nothing is written to the team repository, so you stay on the roster until an admin runs `team remove`.

### A repository that moved

When the team's repository moves, do not leave and re-join by hand:

```sh
npx -y terum-skills@latest team move <org>/<repo>
```

It asks once, removes the old team locally, joins the new repository with the identity you already proved, and places again every skill the old team had placed here, at the same scope, wherever the new team shares it. Your tool approvals survive the move.

You rarely need to type it. `setup <org>/<repo>` offers the move when the old repository no longer exists on GitHub, and `sync` at a terminal offers it when the old repository answers "not found" and it finds a replacement.
