spacehub

surshar / claude-code

Claude Code is an agentic coding tool that lives in your terminal, understands your codebase, and helps you code faster by executing routine tasks, explaining complex code, and handling git workflows - all through natural language commands.

Built by Anthropic · github.com/anthropics

claude-code / mods / telemetry / hooks / context / environment-fields / environment-fields.ts
41 lines · 1.6 KBRaw
1import type { GithubActionsFields } from './github-actions-fields'
2
3/**
4 * The `env` block every row of the session carries, as the CLI's own rows
5 * carry it, before its keys are spelled for the wire (Entries.wireOf).
6 *
7 * The machine, the terminal and shell, CI and GitHub Actions, the remote
8 * container, the deployment. `isClaudeAiAuth` follows the credential each
9 * batch is sent with and joins these then; an absent field is undefined.
10 */
11export type EnvironmentFields = {
12 readonly platform: string
13 readonly platformRaw: string
14 readonly arch: string
15 readonly terminal: string
16 readonly shell: string
17 readonly packageManagers: string
18 readonly runtimes: string
19 readonly isCi: boolean
20 readonly isClaubbit: boolean
21 readonly isGithubAction: boolean
22 readonly isClaudeCodeAction: boolean
23 readonly isClaudeCodeRemote: boolean
24 readonly isLocalAgentMode: boolean
25 readonly isConductor: boolean
26 readonly deploymentEnvironment: string
27 readonly remoteEnvironmentType: string | undefined
28 readonly claudeCodeContainerId: string | undefined
29 readonly claudeCodeRemoteSessionId: string | undefined
30 readonly tags: readonly string[] | undefined
31 readonly githubEventName: string | undefined
32 readonly githubActionsRunnerEnvironment: string | undefined
33 readonly githubActionsRunnerOs: string | undefined
34 readonly githubActionRef: string | undefined
35 readonly githubActionsMetadata: GithubActionsFields | undefined
36 readonly wslVersion: string | undefined
37 readonly linuxDistroId: string | undefined
38 readonly linuxDistroVersion: string | undefined
39 readonly linuxKernel: string | undefined
40 readonly vcs: string | undefined
41}