Skip to content

feat: add DECSTR (soft terminal reset) handler#102

Open
frick-goblin wants to merge 1 commit intocharmbracelet:mainfrom
GoblinCorps:feat/decstr-handler
Open

feat: add DECSTR (soft terminal reset) handler#102
frick-goblin wants to merge 1 commit intocharmbracelet:mainfrom
GoblinCorps:feat/decstr-handler

Conversation

@frick-goblin
Copy link
Copy Markdown

Summary

Adds handler for CSI !p (DECSTR) - the soft terminal reset sequence.

This partially addresses #77 - the DECPNM sequence (ESC >) was already implemented in escHandler (Normal Keypad), so only DECSTR was missing.

Changes

  • Added DECSTR handler to csiHandlers map in handlers.go
  • Added test case in main_test.go
  • Added golden file for test output

Test

$ echo -e '\x1b[!p' | go run . 
 CSI !p: Soft terminal reset

🤖 Generated with Claude Code

Add handler for CSI !p (DECSTR) which performs a soft terminal reset.
This partially addresses charmbracelet#77 - DECPNM was already implemented.

🤖 Generated with Claude Code (https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
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