Sometimes my pull request looks HUGE because of indentation or whitespace changes. For example, if I work on a file with 2-space indentation and then my editor automatically converts it to 4-space, it will appear that nearly the entire file is changed.
How can I revert only the whitespace in a file before sending someone a pull request?
Note, I did see this answer but it's about ignoring changed whitespace after it's on GitHub. I'm looking for how to revert the whitespace before the commit.