Another micro optimisation which I noticed while working on tests.
Currently we lint old file, new file, generate diff, and finally calculate what messages are new. With #51 we'll skip the old file linting saving some time consuming command in case new file contains no lint.
But, when we know that there are no lint issues in the new version of a file, we even don't need to generate diff, since it's not really needed.
Not that git diff would consume that much time, but can save some precious seconds when running over a huge number of files.
Another micro optimisation which I noticed while working on tests.
Currently we lint old file, new file, generate diff, and finally calculate what messages are new. With #51 we'll skip the old file linting saving some time consuming command in case new file contains no lint.
But, when we know that there are no lint issues in the new version of a file, we even don't need to generate diff, since it's not really needed.
Not that
git diff
would consume that much time, but can save some precious seconds when running over a huge number of files.