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

Make git believe it is writing to a tty so that it invokes its pager #574

Merged
merged 1 commit into from Apr 24, 2021

Conversation

dandavison
Copy link
Owner

https://stackoverflow.com/a/1402389/583763

cc @Kr1ss-XD this was a new unix command for me! I've only done it for MacOS currently; I think the version of script will have a different command line API on Linux (I use the GNU versions of things on MacOS when possible but it wasn't clear to me that such a thing existed in this case.)

This change makes git and delta believe that they are writing to a tty
so that they invoke their child pager processes, as is required for
the test. However, output is actually redirected to /dev/null.

TODO: implement for the Linux version of script also.

https://stackoverflow.com/a/1402389/583763
@dandavison dandavison merged commit ab77bff into master Apr 24, 2021
@dandavison dandavison deleted the run-less-test-without-sending-output-to-screen branch April 24, 2021 17:37
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.

None yet

1 participant