Skip to content

Commit

Permalink
format
Browse files Browse the repository at this point in the history
  • Loading branch information
maflcko committed May 28, 2024
1 parent c16e1d8 commit 92b5e69
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions infra/presubmit.py
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,9 @@ def _check_one_apt_update(path):
with open(path, 'r') as file:
dockerfile = file.read()
if 'RUN apt install' in dockerfile or 'RUN apt-get install' in dockerfile:
print('Please add an "apt-get update" before "apt-get install". Otherwise, a cached and outdated RUN layer may lead to install failures.')
print('Please add an "apt-get update" before "apt-get install". '
'Otherwise, a cached and outdated RUN layer may lead to install '
'failures.')
return False

return True
Expand All @@ -274,8 +276,12 @@ def check_apt_update(paths):
def do_checks(changed_files):
"""Runs all presubmit checks. Returns False if any fails."""
checks = [
check_license, yapf, check_project_yaml, check_lib_fuzzing_engine,
check_seed_corpus, check_apt_update,
check_license,
yapf,
check_project_yaml,
check_lib_fuzzing_engine,
check_seed_corpus,
check_apt_update,
]
# Use a list comprehension here and in other cases where we use all() so that
# we don't quit early on failure. This is more user-friendly since the more
Expand Down

0 comments on commit 92b5e69

Please sign in to comment.