Open
Conversation
0atman
commented
Aug 21, 2025
| try: | ||
| # Try ydotool first | ||
| subprocess.run(['ydotool', '--socket-path', '/run/ydotoold/socket', 'type', text + ' '], | ||
| subprocess.run(['ydotool', 'type', '-d1', '-H1', text + ' '], |
Author
There was a problem hiding this comment.
I don't know why ydotool has changed its interface to not require a socket path param, but require an env variable. Anyway, this worked for me. I'm on 1.0.4, which I believe is the latest, in NixOS unstable.
0atman
commented
Aug 21, 2025
| # Run enhanced version (with pre-buffer to capture initial words) | ||
| cd /home/jordan/voice-typing-nix | ||
| exec nix-shell shell.nix --run "python enhanced-voice-typing.py $DEFAULT_ARGS $*" No newline at end of file | ||
| cd "$(dirname "$0")" |
Author
There was a problem hiding this comment.
I believe this is the correct way to CD into the folder that the script is running from. It looked like there might be some more comprehensive options, but this works fine for me.
0atman
commented
Aug 21, 2025
| cd /home/jordan/voice-typing-nix | ||
| exec nix-shell shell.nix --run "python enhanced-voice-typing.py $DEFAULT_ARGS $*" No newline at end of file | ||
| cd "$(dirname "$0")" | ||
| YDOTOOL_SOCKET=/run/ydotoold/socket exec nix-shell shell.nix --run "python enhanced-voice-typing.py $DEFAULT_ARGS $*" |
Author
There was a problem hiding this comment.
Here's the other side of the Python code change above. It looks like there was a change in the env or param for ydotool? This environment variable matches up with one that is set in your nix service definition file.
inn0minatus
pushed a commit
to inn0minatus/voice-typing-linux
that referenced
this pull request
Dec 29, 2025
Changes from GitJuhb#3 by 0atman: 1. Update ydotool invocation: - Remove --socket-path flag (now uses YDOTOOL_SOCKET env var) - Add -d1 (1ms delay between keys) and -H1 (1ms hold time) flags - Improves typing reliability and prevents missed characters 2. Set YDOTOOL_SOCKET environment variable: - Modern ydotool versions prefer env var over CLI flag - Ensures compatibility with ydotool 1.0.4+ These changes fix ydotool compatibility issues on newer systems. Ref: GitJuhb#3
inn0minatus
added a commit
to inn0minatus/voice-typing-linux
that referenced
this pull request
Dec 29, 2025
Changes from GitJuhb#3 by 0atman: 1. Update ydotool invocation: - Remove --socket-path flag (now uses YDOTOOL_SOCKET env var) - Add -d1 (1ms delay between keys) and -H1 (1ms hold time) flags - Improves typing reliability and prevents missed characters 2. Set YDOTOOL_SOCKET environment variable: - Modern ydotool versions prefer env var over CLI flag - Ensures compatibility with ydotool 1.0.4+ These changes fix ydotool compatibility issues on newer systems. Ref: GitJuhb#3
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi Jordan! Thanks for making this tool, a genius use of claude to just wire everything up to make a better interface - I'm curious how long it took from start to that first commit?
Anyway, there were two lines I had to fix to get it working on my system, I've commented them inline.
I resisted doing huge refactorings because that's not really what this project is about, But if you would accept another PR with some fixes in (like there's some bare exceptions that are bad practice in Python, that sort of thing) do let me know, and I'd be happy to help out!
Cheers!
(I didn't use ai to make this pr, mistakes are my own!)