# \[Bug\]: Integrated terminal does not set TERM_PROGRAM, breaking shell prompt and terminal detection · Issue \#8450 · pingdotgg/t3code

[View on GitCafe](https://git.cafe/pingdotgg/t3code/issues/8450)

Repository: [pingdotgg/t3code](https://git.cafe/pingdotgg/t3code)

Visibility: public

State: backlog

Priority: 0

## Description

[Discussion and activity](https://git.cafe/pingdotgg/t3code/issues/8450)

---

### Before submitting

- [x] I searched existing issues and did not find a duplicate.
- [x] I included enough detail to reproduce or investigate the problem.

### Area

apps/desktop

### Steps to reproduce

1. Open the integrated terminal in T3 Code on macOS.
2. Run: echo "[$TERM_PROGRAM] [$TERM_PROGRAM_VERSION] [$COLORTERM]"
3. Observe all three are empty.

For a practical repro, use any shell config that selects a prompt by terminal.
Minimal case:

    case "$TERM_PROGRAM" in
      "vscode")   echo "vscode config" ;;
      "ghostty")  echo "ghostty config" ;;
      *)          echo "fallback config" ;;
    esac

In every other terminal emulator this selects the correct branch.
In T3 Code it always hits the fallback, because there is nothing to match on.

### Expected behavior

The integrated terminal exports TERM_PROGRAM (and ideally TERM_PROGRAM_VERSION)
into the pty environment, the way every other terminal emulator does:

| Emulator       | TERM_PROGRAM     |
|----------------|------------------|
| VS Code        | vscode           |
| Apple Terminal | Apple_Terminal   |
| iTerm2         | iTerm.app        |
| Ghostty        | ghostty          |
| WezTerm        | WezTerm          |
| Hyper          | Hyper            |
| T3 Code        | (unset)          |

Something like TERM_PROGRAM=t3code plus TERM_PROGRAM_VERSION=0.0.35.

### Actual behavior

TERM_PROGRAM is never set, so the shell cannot tell it is running inside T3 Code.

### Impact

Minor bug or occasional failure

### Version or commit

main

### Environment

 15.7.4

### Logs or stack traces

```shell

```

### Screenshots, recordings, or supporting files

_No response_

### Workaround

_No response_
