diff --git a/.gitlab/ci/pipelines/before_merging.yml b/.gitlab/ci/pipelines/before_merging.yml index 8974e4a7b6fba26b6402c2879bc67c242a510006..6ae916fbc483449420478581a585d2884e4e84e5 100644 --- a/.gitlab/ci/pipelines/before_merging.yml +++ b/.gitlab/ci/pipelines/before_merging.yml @@ -147,10 +147,9 @@ sanity_ci: - ./scripts/ci/take_ownership.sh - eval $(opam env) script: - - make -C manifest check - - ./scripts/lint.sh --check-gitlab-ci-yml + - make --silent -C manifest check - ./scripts/ci/check_alpine_version.sh - - make -C ci check + - make --silent -C ci check docker:hadolint: image: hadolint/hadolint:2.9.3-debian diff --git a/.gitlab/ci/pipelines/merge_train.yml b/.gitlab/ci/pipelines/merge_train.yml index 6c2379b7c47fb5d1c964c71f40c00a3c29893373..055168f678531fd6aa20bf373ffbe1dbcf030280 100644 --- a/.gitlab/ci/pipelines/merge_train.yml +++ b/.gitlab/ci/pipelines/merge_train.yml @@ -147,10 +147,9 @@ sanity_ci: - ./scripts/ci/take_ownership.sh - eval $(opam env) script: - - make -C manifest check - - ./scripts/lint.sh --check-gitlab-ci-yml + - make --silent -C manifest check - ./scripts/ci/check_alpine_version.sh - - make -C ci check + - make --silent -C ci check docker:hadolint: image: hadolint/hadolint:2.9.3-debian diff --git a/.gitlab/ci/pipelines/schedule_extended_test.yml b/.gitlab/ci/pipelines/schedule_extended_test.yml index f2b75590a2e73dc7e14a3c4f89beb93c5d019c5b..9d4b0c7749e88b82abc70ffed89a09e939cfaaf7 100644 --- a/.gitlab/ci/pipelines/schedule_extended_test.yml +++ b/.gitlab/ci/pipelines/schedule_extended_test.yml @@ -124,10 +124,9 @@ sanity_ci: - ./scripts/ci/take_ownership.sh - eval $(opam env) script: - - make -C manifest check - - ./scripts/lint.sh --check-gitlab-ci-yml + - make --silent -C manifest check - ./scripts/ci/check_alpine_version.sh - - make -C ci check + - make --silent -C ci check docker:hadolint: image: hadolint/hadolint:2.9.3-debian diff --git a/ci/bin/code_verification.ml b/ci/bin/code_verification.ml index 1f8220db541f4cd42ffa0cd85d0c924ab4c9c1a2..bd01af3381411938f8a622472bd03d9719e0e074 100644 --- a/ci/bin/code_verification.ml +++ b/ci/bin/code_verification.ml @@ -322,13 +322,12 @@ let jobs pipeline_type = ~dependencies ~before_script:(before_script ~take_ownership:true ~eval_opam:true []) [ - "make -C manifest check"; - "./scripts/lint.sh --check-gitlab-ci-yml"; + "make --silent -C manifest check"; (* Check that the opam-repo images' Alpine version corresponds to the value in scripts/version.sh. *) "./scripts/ci/check_alpine_version.sh"; (* Check that .gitlab-ci.yml is up to date. *) - "make -C ci check"; + "make --silent -C ci check"; ] in let job_nix : tezos_job = diff --git a/scripts/lint.sh b/scripts/lint.sh index 553fbfb2b19c5c6b6ec6bdcc0b607f20c9de2f54..4e4ef2e0ba677fc0ae2e1437e1f16523bd6d5fc6 100755 --- a/scripts/lint.sh +++ b/scripts/lint.sh @@ -10,7 +10,6 @@ Where can be: git-commit (requires clean repo). * --check-ocamlformat: check that --update-ocamlformat does nothing. * --format-scripts: format shell scripts inplace using shfmt -* --check-gitlab-ci-yml: check .gitlab-ci.yml has been updated. * --check-scripts: shellcheck and check formatting of the .sh files * --check-redirects: check docs/_build/_redirects. * --check-coq-attributes: check the presence of coq attributes. @@ -197,28 +196,6 @@ check_rust_toolchain_files() { done } -check_gitlab_ci_yml() { - # Check that a rule is not defined twice, which would result in the first - # one being ignored. Gitlab linter doesn't warn for it. - find .gitlab-ci.yml .gitlab/ci/ -iname \*.yml | - while read -r filename; do - repeated=$(grep '^[^ #-]' "$filename" | - sort | - grep -v include | - uniq --repeated) - if [ -n "$repeated" ]; then - echo "$filename contains repeated rules:" - echo "$repeated" - touch /tmp/repeated - fi - done - - if [ -f /tmp/repeated ]; then - rm /tmp/repeated - exit 1 - fi -} - check_licenses_git_new() { if [ -z "${CHECK_LICENSES_DIFF_BASE:-}" ]; then echo 'Action --check-licenses-git-new requires that CHECK_LICENSES_DIFF_BASE is set in the environment.' @@ -302,9 +279,6 @@ case "$action" in action=update_all_dot_ocamlformats check_clean=true ;; -"--check-gitlab-ci-yml") - action=check_gitlab_ci_yml - ;; "--check-scripts") action=check_scripts ;;