]> git.madduck.net Git - etc/vim.git/commit

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

Fix misdetection of project root with `--stdin-filename` (#3216)
authorShantanu <12621235+hauntsaninja@users.noreply.github.com>
Fri, 26 Aug 2022 21:07:25 +0000 (14:07 -0700)
committerGitHub <noreply@github.com>
Fri, 26 Aug 2022 21:07:25 +0000 (17:07 -0400)
commitc47b91f513052cd39b818ea7c19716423c85c04e
tree94ff69020ae7878b5bb86d5ab46097ad5eb2b533
parenta5fde8ab9be26221d01bdd0a426db07cdb6f0f04
Fix misdetection of project root with `--stdin-filename` (#3216)

There are a number of places this behaviour could be patched, for
instance, it's quite tempting to patch it in `get_sources`. However
I believe we generally have the invariant that project root contains all
files we want to format, in which case it seems prudent to keep that
invariant.

This also improves the accuracy of the "sources to be formatted" log
message with --stdin-filename.

Fixes GH-3207.
CHANGES.md
src/black/__init__.py
src/black/files.py
tests/test_black.py