Delete ci/lint.sh, which is no longer used. (flutter/engine#46049)

Found out while working on
https://github.com/flutter/flutter/issues/134969.

I suspect this stopped being used when we sharded out the Clang Tidy
builders?
This commit is contained in:
Matan Lurey
2023-09-20 11:29:10 -07:00
committed by GitHub
parent c8363b0127
commit 6b09ca7f44
5 changed files with 12 additions and 45 deletions

View File

@@ -1,8 +1,6 @@
# A YAML format of https://clang.llvm.org/extra/clang-tidy/.
# Prefix check with "-" to ignore.
# Note: Some of the checks here are used as errors selectively, see
# //ci/lint.sh
Checks: >-
bugprone-use-after-move,
bugprone-unchecked-optional-access,

View File

@@ -464,7 +464,7 @@ Engine test example:
{
"tests": [
{
"name": "test: lint android_debug_arm64",
"name": "test: clang_tidy android_debug_arm64",
"recipe": "engine_v2/tester_engine",
"drone_dimensions": [
"device_type=none",
@@ -476,7 +476,7 @@ Engine test example:
],
"tasks": [
{
"name": "test: lint android_debug_arm64",
"name": "test: clang_tidy android_debug_arm64",
"parameters": [
"--variant",
"android_debug_arm64",
@@ -485,7 +485,7 @@ Engine test example:
"--shard-variants=host_debug"
],
"max_attempts": 1,
"script": "flutter/ci/lint.sh"
"script": "flutter/ci/clang_tidy.sh"
}
]
}
@@ -513,7 +513,7 @@ Example task configuration:
```json
{
"name": "test: lint android_debug_arm64",
"name": "test: clang_tidy android_debug_arm64",
"parameters": [
"--variant",
"android_debug_arm64",
@@ -522,7 +522,7 @@ Example task configuration:
"--shard-variants=host_debug"
],
"max_attempts": 1,
"script": "flutter/ci/lint.sh"
"script": "flutter/ci/clang_tidy.sh"
}
```

View File

@@ -36,10 +36,14 @@ DART="${DART_BIN}/dart"
# FLUTTER_LINT_PRINT_FIX will make it so that fix is executed and the generated
# diff is printed to stdout if clang-tidy fails. This is helpful for enabling
# new lints.
# To run on CI, just uncomment the following line:
# FLUTTER_LINT_PRINT_FIX=1
if [[ -z "${FLUTTER_LINT_PRINT_FIX}" ]]; then
fix_flag=""
else
fix_flag="--fix"
fix_flag="--fix --lint-all"
fi
COMPILE_COMMANDS="$SRC_DIR/out/host_debug/compile_commands.json"

View File

@@ -1,35 +0,0 @@
#!/bin/bash
#
# Copyright 2013 The Flutter Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
set -e
# Needed because if it is set, cd may print the path it changed to.
unset CDPATH
# On Mac OS, readlink -f doesn't work, so follow_links traverses the path one
# link at a time, and then cds into the link destination and find out where it
# ends up.
#
# The function is enclosed in a subshell to avoid changing the working directory
# of the caller.
function follow_links() (
cd -P "$(dirname -- "$1")"
file="$PWD/$(basename -- "$1")"
while [[ -h "$file" ]]; do
cd -P "$(dirname -- "$file")"
file="$(readlink -- "$file")"
cd -P "$(dirname -- "$file")"
file="$PWD/$(basename -- "$file")"
done
echo "$file"
)
SCRIPT_DIR=$(follow_links "$(dirname -- "${BASH_SOURCE[0]}")")
PYLINT="${SCRIPT_DIR}/pylint.sh"
CLANG_TIDY="${SCRIPT_DIR}/clang_tidy.sh"
"${PYLINT}" "$@"
"${CLANG_TIDY}" "$@"

View File

@@ -21,8 +21,8 @@ scripts have the names that `git` will look for.
This hooks runs when pushing commits to a remote branch, for example to
create or update a pull request: `git push origin my-local-branch`.
The `pre-push` hook runs `ci/lint.sh` and `ci/format.sh`. `ci/analyze.sh` and
`ci/licenses.sh` are more expensive and are not run.
The `pre-push` hook runs `ci/clang_tidy.sh`, `ci/pylint.sh` and `ci/format.sh`.
`ci/analyze.sh` and `ci/licenses.sh` are more expensive and are not run.
### Adding new pre-push checks