Skip to content

Add cancel mechanisms: double-press and mid-transcription hotkey#12

Merged
csheaff merged 1 commit intomainfrom
feat/cancel-mechanisms
Mar 2, 2026
Merged

Add cancel mechanisms: double-press and mid-transcription hotkey#12
csheaff merged 1 commit intomainfrom
feat/cancel-mechanisms

Conversation

@csheaff
Copy link
Owner

@csheaff csheaff commented Mar 2, 2026

Summary

  • Double-press cancel: press hotkey twice within ~1.5s to discard recording without transcribing
  • Mid-transcription cancel: press hotkey while transcribing to kill the process
  • Fix notify_close: use gdbus CloseNotification instead of notify-send -e which showed an empty notification on GNOME
  • Run transcription in background so it can be signal-killed via trans.pid

Test plan

  • shellcheck talktype passes
  • bats test/talktype.bats — all 18 tests pass (15 existing + 3 new)
  • Manual: double-press hotkey cancels, notification disappears cleanly
  • Manual: normal record → transcribe → type flow still works

🤖 Generated with Claude Code

Two ways to cancel:
- Double-press hotkey (<1.5s recording) discards without transcribing
- Press hotkey during transcription to kill the transcription process

Also fixes notify_close to use gdbus CloseNotification (the old
notify-send -e approach showed an empty notification on GNOME), and
runs transcription in background so it can be signal-killed.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@csheaff csheaff merged commit 0d42ba7 into main Mar 2, 2026
6 checks passed
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