Skip to content

Commit cfa27d3

Browse files
fix: flutter apt-get install & update as single command
1 parent 474e2f8 commit cfa27d3

File tree

1 file changed

+18
-2
lines changed

1 file changed

+18
-2
lines changed

earthly/flutter/Earthfile

+18-2
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,24 @@ flutter-base:
4141

4242
ENV DEBIAN_FRONTEND=noninteractive
4343

44-
RUN apt-get update --fix-missing
45-
RUN apt-get install -y apt-utils git curl gzip unzip bzip2 bash jq gpg lcov tar wget xz-utils
44+
# Runing update & install as same command so if either fails, the whole step fails and
45+
# is not cached.
46+
RUN apt-get update --fix-missing && \
47+
apt-get install -y \
48+
apt-utils \
49+
git \
50+
curl \
51+
gzip \
52+
unzip \
53+
bzip2 \
54+
bash \
55+
jq \
56+
gpg \
57+
lcov \
58+
tar \
59+
wget \
60+
xz-utils \
61+
&& rm -rf /var/lib/apt/lists/*
4662

4763
DO +INSTALL_FLUTTER
4864

0 commit comments

Comments
 (0)