Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: add use_stdin option for just reading from stdin #547

Conversation

mrexox
Copy link
Member

@mrexox mrexox commented Sep 12, 2023

Closes #508

🔧 Summary

interactive options is supposed to be used with interactive CLI commands. With interactive: true lefthook opens a TTY (for Linux/Unix), and scripts that use while read ... hang forever. This PR adds use_stdin option that doesn't touch a TTY device but forwards the stdin.

To do

  • Add use_stdin for commands and scripts
  • Test pushing with git
  • Update docs on how to use lefthook with scripts like pre-push

@mrexox mrexox force-pushed the fix/add-use_stdin-option-for-just-reading-from-stdin branch from 80ae6b6 to 14a1d77 Compare September 12, 2023 14:34
@mrexox mrexox force-pushed the fix/add-use_stdin-option-for-just-reading-from-stdin branch 2 times, most recently from 669f921 to b2118ee Compare September 12, 2023 15:37
@mrexox mrexox force-pushed the fix/add-use_stdin-option-for-just-reading-from-stdin branch from b2118ee to a01bd84 Compare September 13, 2023 06:51
@mrexox mrexox marked this pull request as ready for review September 13, 2023 06:51
@mrexox mrexox merged commit 08a56d3 into evilmartians:master Sep 13, 2023
17 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.

pre-push hooks are broken because lefthook does not forward STDIN
1 participant