ci: comment logic of set-vars.sh
This commit is contained in:
parent
fe1796cfa7
commit
af33f7eb12
2 changed files with 7 additions and 1 deletions
6
.github/workflows/set-vars.sh
vendored
6
.github/workflows/set-vars.sh
vendored
|
|
@ -1,5 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
|
# Find the line specifying the version number for the Rust toolchain, then
|
||||||
|
# extract that version number. Failure to do so aborts the CI run.
|
||||||
msrv=$(
|
msrv=$(
|
||||||
awk '/^rust-version = "[[:digit:]]+\.[[:digit:]]+\.[[:digit:]]+"$/ {
|
awk '/^rust-version = "[[:digit:]]+\.[[:digit:]]+\.[[:digit:]]+"$/ {
|
||||||
print substr($NF, 2, length($NF) - 2)
|
print substr($NF, 2, length($NF) - 2)
|
||||||
|
|
@ -10,6 +12,10 @@ if [ -z $msrv ]; then
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Check for one of two conditions to regenerate the Docker image:
|
||||||
|
# (These conditions must be met on `main` and not a PR branch, see ci.yml)
|
||||||
|
# 1. An annotated tag was found when fetching the tags at depth 1 (tags on HEAD)
|
||||||
|
# 2. "$UBUNTU_DOCKERFILE" was changed between HEAD and the prior commit (HEAD~1)
|
||||||
git fetch --depth=1 origin +refs/tags/*:refs/tags/*
|
git fetch --depth=1 origin +refs/tags/*:refs/tags/*
|
||||||
if ! git diff HEAD~1 --quiet -- "$UBUNTU_DOCKERFILE" ||
|
if ! git diff HEAD~1 --quiet -- "$UBUNTU_DOCKERFILE" ||
|
||||||
git describe --candidates=0; then
|
git describe --candidates=0; then
|
||||||
|
|
|
||||||
2
.github/workflows/ubuntu.dockerfile
vendored
2
.github/workflows/ubuntu.dockerfile
vendored
|
|
@ -1,4 +1,4 @@
|
||||||
FROM ubuntu:latest
|
FROM ubuntu:24.04
|
||||||
|
|
||||||
ARG DEBIAN_FRONTEND=noninteractive
|
ARG DEBIAN_FRONTEND=noninteractive
|
||||||
ENV TZ=Etc/UTC
|
ENV TZ=Etc/UTC
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue