Skip to content

feat(test): configurable -t fd terminal detection#818

Merged
chaliy merged 1 commit intomainfrom
fix/issue-799-t-fd-test
Mar 26, 2026
Merged

feat(test): configurable -t fd terminal detection#818
chaliy merged 1 commit intomainfrom
fix/issue-799-t-fd-test

Conversation

@chaliy
Copy link
Copy Markdown
Contributor

@chaliy chaliy commented Mar 26, 2026

Summary\n\n- Make -t fd configurable via _TTY_N variables (e.g. _TTY_0=1 for stdin)\n- Defaults to false for all FDs (correct for sandboxed VFS execution)\n- Works in both [ -t ] and [[ -t ]] syntax\n\nCloses #799\n\n## Test plan\n\n- [x] -t 0 defaults to false\n- [x] -t 1 defaults to false\n- [x] _TTY_1=1 makes -t 1 return true\n- [x] [[ -t 0 ]] works\n- [x] [[ -t 1 ]] respects _TTY_1 variable\n- [x] All tests green

@chaliy chaliy force-pushed the fix/issue-799-t-fd-test branch 2 times, most recently from ad832b5 to 3c72a35 Compare March 26, 2026 06:28
Make -t fd (terminal test) configurable via _TTY_N variables. Defaults
to false for all FDs (correct for sandboxed VFS execution). Set
_TTY_0=1, _TTY_1=1, etc. to simulate terminal mode. Works in both
[ -t ] and [[ -t ]] syntax.

Closes #799
@chaliy chaliy force-pushed the fix/issue-799-t-fd-test branch from 3c72a35 to bf6edc6 Compare March 26, 2026 06:38
@chaliy chaliy merged commit e7c39cd into main Mar 26, 2026
23 checks passed
@chaliy chaliy deleted the fix/issue-799-t-fd-test branch March 26, 2026 06:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant