mirror of https://github.com/llvm/torch-mlir
[CI] Verify bazel buildifier is run and changes committed (#1700)
Ensures the buildifier (linter for bazel build files) is run and changes are pushed.pull/1691/head snapshot-20221209.682
parent
804f9f1f8f
commit
109c91ae9b
|
@ -68,6 +68,18 @@ jobs:
|
||||||
torch-mlir:ci \
|
torch-mlir:ci \
|
||||||
bazel test @torch-mlir//test/...
|
bazel test @torch-mlir//test/...
|
||||||
|
|
||||||
|
- name: Verify buildifier was run (bazel lint)
|
||||||
|
run: |
|
||||||
|
docker run --rm \
|
||||||
|
-v "$(pwd)":"/opt/src/torch-mlir" \
|
||||||
|
-v "${HOME}/.cache/bazel":"/root/.cache/bazel" \
|
||||||
|
torch-mlir:ci \
|
||||||
|
bazel run @torch-mlir//:buildifier
|
||||||
|
if [ -n "$(git status --porcelain)" ]; then
|
||||||
|
echo "Please 'bazel run @torch-mlir//:buildifier' and commit changes."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
# Switch back bazel cache directory to user ownership
|
# Switch back bazel cache directory to user ownership
|
||||||
# to allow GHA post-cache step to save cache without
|
# to allow GHA post-cache step to save cache without
|
||||||
# permissions issue.
|
# permissions issue.
|
||||||
|
|
|
@ -465,13 +465,13 @@ cc_library(
|
||||||
],
|
],
|
||||||
strip_include_prefix = "include",
|
strip_include_prefix = "include",
|
||||||
deps = [
|
deps = [
|
||||||
|
":TorchMLIRTorchConversionToMLProgram",
|
||||||
":TorchMLIRTorchToArith",
|
":TorchMLIRTorchToArith",
|
||||||
":TorchMLIRTorchToLinalg",
|
":TorchMLIRTorchToLinalg",
|
||||||
":TorchMLIRTorchToMhlo",
|
":TorchMLIRTorchToMhlo",
|
||||||
":TorchMLIRTorchToSCF",
|
":TorchMLIRTorchToSCF",
|
||||||
":TorchMLIRTorchToTMTensor",
|
":TorchMLIRTorchToTMTensor",
|
||||||
":TorchMLIRTorchToTosa",
|
":TorchMLIRTorchToTosa",
|
||||||
":TorchMLIRTorchConversionToMLProgram",
|
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -487,6 +487,7 @@ cc_library(
|
||||||
":TorchMLIRTorchBackendTypeConversion",
|
":TorchMLIRTorchBackendTypeConversion",
|
||||||
":TorchMLIRTorchConversionDialect",
|
":TorchMLIRTorchConversionDialect",
|
||||||
":TorchMLIRTorchConversionPassesIncGen",
|
":TorchMLIRTorchConversionPassesIncGen",
|
||||||
|
":TorchMLIRTorchConversionToMLProgram",
|
||||||
":TorchMLIRTorchDialect",
|
":TorchMLIRTorchDialect",
|
||||||
":TorchMLIRTorchPasses",
|
":TorchMLIRTorchPasses",
|
||||||
":TorchMLIRTorchToArith",
|
":TorchMLIRTorchToArith",
|
||||||
|
@ -495,7 +496,6 @@ cc_library(
|
||||||
":TorchMLIRTorchToSCF",
|
":TorchMLIRTorchToSCF",
|
||||||
":TorchMLIRTorchToTMTensor",
|
":TorchMLIRTorchToTMTensor",
|
||||||
":TorchMLIRTorchToTosa",
|
":TorchMLIRTorchToTosa",
|
||||||
":TorchMLIRTorchConversionToMLProgram",
|
|
||||||
"@llvm-project//mlir:ConversionPasses",
|
"@llvm-project//mlir:ConversionPasses",
|
||||||
"@llvm-project//mlir:FuncDialect",
|
"@llvm-project//mlir:FuncDialect",
|
||||||
"@llvm-project//mlir:LinalgDialect",
|
"@llvm-project//mlir:LinalgDialect",
|
||||||
|
@ -781,8 +781,8 @@ cc_library(
|
||||||
":TorchMLIRTorchConversionDialect",
|
":TorchMLIRTorchConversionDialect",
|
||||||
"@llvm-project//mlir:ArithTransforms",
|
"@llvm-project//mlir:ArithTransforms",
|
||||||
"@llvm-project//mlir:LinalgDialect",
|
"@llvm-project//mlir:LinalgDialect",
|
||||||
"@llvm-project//mlir:MLProgramDialect",
|
|
||||||
"@llvm-project//mlir:LinalgTransforms",
|
"@llvm-project//mlir:LinalgTransforms",
|
||||||
|
"@llvm-project//mlir:MLProgramDialect",
|
||||||
"@llvm-project//mlir:MathTransforms",
|
"@llvm-project//mlir:MathTransforms",
|
||||||
"@llvm-project//mlir:MemRefDialect",
|
"@llvm-project//mlir:MemRefDialect",
|
||||||
"@llvm-project//mlir:Pass",
|
"@llvm-project//mlir:Pass",
|
||||||
|
|
Loading…
Reference in New Issue