[clang] [clang-format] Fix a bug in git-clang-format.bat (PR #75268)

via cfe-commits cfe-commits at lists.llvm.org
Tue Dec 12 17:17:56 PST 2023


llvmbot wrote:


<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-clang-format

Author: Owen Pan (owenca)

<details>
<summary>Changes</summary>

Pass the fully-qualified path name (less the file extension) of
git-clang-format.bat to py so that it can be run from anywhere.

Fixes #<!-- -->75265.

---
Full diff: https://github.com/llvm/llvm-project/pull/75268.diff


1 Files Affected:

- (modified) clang/tools/clang-format/git-clang-format.bat (+1-1) 


``````````diff
diff --git a/clang/tools/clang-format/git-clang-format.bat b/clang/tools/clang-format/git-clang-format.bat
index d4bc5172989cb..9965cd4312fe3 100644
--- a/clang/tools/clang-format/git-clang-format.bat
+++ b/clang/tools/clang-format/git-clang-format.bat
@@ -1 +1 @@
-py -3 git-clang-format %*
+py -3 %~pn0 %*

``````````

</details>


https://github.com/llvm/llvm-project/pull/75268


More information about the cfe-commits mailing list