diff options
| author | Chris Denton <chris@chrisdenton.dev> | 2025-07-02 08:43:10 +0000 |
|---|---|---|
| committer | Chris Denton <chris@chrisdenton.dev> | 2025-07-02 08:48:20 +0000 |
| commit | 6671d9b92a0bfd70b42e6332c06cd3eeecb52b32 (patch) | |
| tree | f3bc0a746008c54be896aacae23980735b314626 /src/ci/docker/host-x86_64/tidy | |
| parent | 62949cd2d6849cdee2160467365cfa6529b77f16 (diff) | |
| download | rust-6671d9b92a0bfd70b42e6332c06cd3eeecb52b32.tar.gz rust-6671d9b92a0bfd70b42e6332c06cd3eeecb52b32.zip | |
Rename mingw-check-tidy to tidy
Diffstat (limited to 'src/ci/docker/host-x86_64/tidy')
| -rw-r--r-- | src/ci/docker/host-x86_64/tidy/Dockerfile | 48 | ||||
| -rw-r--r-- | src/ci/docker/host-x86_64/tidy/eslint.version | 1 |
2 files changed, 49 insertions, 0 deletions
diff --git a/src/ci/docker/host-x86_64/tidy/Dockerfile b/src/ci/docker/host-x86_64/tidy/Dockerfile new file mode 100644 index 00000000000..dbb950cbe0c --- /dev/null +++ b/src/ci/docker/host-x86_64/tidy/Dockerfile @@ -0,0 +1,48 @@ +# We use the ghcr base image because ghcr doesn't have a rate limit +# and the tidy job doesn't cache docker images in CI. +FROM ghcr.io/rust-lang/ubuntu:22.04 + +ARG DEBIAN_FRONTEND=noninteractive +RUN apt-get update && apt-get install -y --no-install-recommends \ + g++ \ + make \ + ninja-build \ + file \ + curl \ + ca-certificates \ + python2.7 \ + python3 \ + python3-pip \ + python3-pkg-resources \ + git \ + cmake \ + sudo \ + gdb \ + xz-utils \ + libssl-dev \ + pkg-config \ + mingw-w64 \ + && rm -rf /var/lib/apt/lists/* + +COPY scripts/nodejs.sh /scripts/ +RUN sh /scripts/nodejs.sh /node +ENV PATH="/node/bin:${PATH}" + +# Install eslint +COPY host-x86_64/tidy/eslint.version /tmp/ + +COPY scripts/sccache.sh /scripts/ +RUN sh /scripts/sccache.sh + +COPY host-x86_64/pr-check-1/reuse-requirements.txt /tmp/ +RUN pip3 install --no-deps --no-cache-dir --require-hashes -r /tmp/reuse-requirements.txt \ + && pip3 install virtualenv + +COPY host-x86_64/pr-check-1/validate-toolstate.sh /scripts/ + +RUN bash -c 'npm install -g eslint@$(cat /tmp/eslint.version)' + +# NOTE: intentionally uses python2 for x.py so we can test it still works. +# validate-toolstate only runs in our CI, so it's ok for it to only support python3. +ENV SCRIPT TIDY_PRINT_DIFF=1 python2.7 ../x.py test --stage 0 \ + src/tools/tidy tidyselftest --extra-checks=py,cpp diff --git a/src/ci/docker/host-x86_64/tidy/eslint.version b/src/ci/docker/host-x86_64/tidy/eslint.version new file mode 100644 index 00000000000..1acea15afd6 --- /dev/null +++ b/src/ci/docker/host-x86_64/tidy/eslint.version @@ -0,0 +1 @@ +8.6.0 \ No newline at end of file |
