Compare commits

..

No commits in common. "main" and "v2.0.0" have entirely different histories.
main ... v2.0.0

4 changed files with 15 additions and 37 deletions

View file

@ -15,32 +15,17 @@ jobs:
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
- name: Machete
uses: https://git.kemitix.net/kemitix/rust@v2.4.1
with:
args: cargo machete
- name: Format
uses: https://git.kemitix.net/kemitix/rust@v2.4.1
with:
args: ${{ matrix.toolchain.name }} cargo fmt --check
- name: Clippy
uses: https://git.kemitix.net/kemitix/rust@v2.4.1
with:
args: ${{ matrix.toolchain.name }} cargo clippy
- name: Test - name: Test
uses: https://git.kemitix.net/kemitix/rust@v2.4.1 uses: https://git.kemitix.net/kemitix/rust@next
with: with:
args: ${{ matrix.toolchain.name }} cargo test args: ${{ matrix.toolchain.name }} cargo test
- name: Build - name: Build
uses: https://git.kemitix.net/kemitix/rust@v2.4.1 uses: https://git.kemitix.net/kemitix/rust@next
with: with:
args: ${{ matrix.toolchain.name }} cargo build args: ${{ matrix.toolchain.name }} cargo build
- name: Run - name: Run
uses: https://git.kemitix.net/kemitix/rust@v2.4.1 uses: https://git.kemitix.net/kemitix/rust@next
with: with:
args: ${{ matrix.toolchain.name }} cargo run args: ${{ matrix.toolchain.name }} cargo run

View file

@ -1,4 +1,4 @@
FROM docker.io/rust:1.82.0-slim-bookworm FROM docker.io/rust:1.81.0-slim-bookworm
# nodejs - runtime used by forgejo/github actions # nodejs - runtime used by forgejo/github actions
# curl - to download cargo-binstall # curl - to download cargo-binstall
@ -9,21 +9,20 @@ FROM docker.io/rust:1.82.0-slim-bookworm
# git - git # git - git
RUN apt-get update \ RUN apt-get update \
&& \ && \
apt-get satisfy -y "nodejs (>=18.19.0), curl (>=7.88.1), pkg-config (>=1.8.1), libssl-dev (>=3.0.14), git (>=2.39.2), libdbus-1-dev (>= 1.14.10), libtag1-dev (>= 1.13), libtagc0-dev (>= 1.13), xorg-dev (>=7.7), libxcb-shape0-dev (>=0.15), libxcb-xfixes0-dev (>=0.15)" \ apt-get satisfy -y "nodejs (>=18.19.0), curl (>=7.88.1), pkg-config (>=1.8.1), libssl-dev (>=3.0.14), git (>=2.39.2)" \
&& \ && \
rm -r /var/lib/apt/lists/* rm -r /var/lib/apt/lists/*
RUN curl -L https://github.com/cargo-bins/cargo-binstall/releases/download/v1.10.12/cargo-binstall-x86_64-unknown-linux-musl.tgz -o cargo-binstall.tgz && \ RUN curl -L https://github.com/cargo-bins/cargo-binstall/releases/download/v1.9.0/cargo-binstall-x86_64-unknown-linux-musl.tgz -o cargo-binstall.tgz && \
tar -xzf cargo-binstall.tgz && \ tar -xzf cargo-binstall.tgz && \
rm cargo-binstall.tgz && \ rm cargo-binstall.tgz && \
mv cargo-binstall /usr/local/bin/ mv cargo-binstall /usr/local/bin/
RUN cargo binstall -y \ RUN cargo binstall -y \
cargo-chef@0.1 \ cargo-chef@0.1.67 \
cargo-hack@0.6 \ cargo-hack@0.6.31 \
cargo-machete@0.7 \ release-plz@0.3.80 && \
cargo-mutants@24.11 \ rustup component add rustfmt clippy
release-plz@0.3
COPY entrypoint.sh / COPY entrypoint.sh /

View file

@ -12,10 +12,10 @@ jobs:
test: test:
runs-on: docker runs-on: docker
steps: steps:
- uses: https://git.kemitix.net/kemitix/rust@v2.4.0 - uses: https://git.kemitix.net/kemitix/rust@v1.80.0
with: with:
args: nightly cargo test args: nightly cargo test
- uses: https://git.kemitix.net/kemitix/rust@v2.4.0 - uses: https://git.kemitix.net/kemitix/rust@v1.80.0
with: with:
args: v1.79.0 cargo build args: v1.79.0 cargo build
``` ```
@ -27,7 +27,8 @@ The `args` is one of the following:
`COMMAND` is the command you want to run. The optional prefix is the Rust toolchain, or version. Allowed values are `nightly`, `stable` or a Rust version. `COMMAND` is the command you want to run. The optional prefix is the Rust toolchain, or version. Allowed values are `nightly`, `stable` or a Rust version.
Where the optional prefix is not given, the `stable` toolchain will be used. The `stable` version is currently `1.82.0`. Where the optional prefix is not given, the `stable` toolchain will be used.
## Contents ## Contents
@ -36,10 +37,6 @@ Where the optional prefix is not given, the `stable` toolchain will be used. The
- git - git
- cargo - cargo
- cargo-binstall - cargo-binstall
- cargo-mutants
- cargo-chef
- cargo-hack
- release-plz
## Binary size ## Binary size

View file

@ -26,10 +26,7 @@ if [[ "${ARGS[0]}" == v1* ]]; then
fi fi
echo "Selected toolchain: ${TOOLCHAIN}" echo "Selected toolchain: ${TOOLCHAIN}"
echo ">>> Update toolchain"
rustup update "${TOOLCHAIN}" rustup update "${TOOLCHAIN}"
echo ">>> Install rustfmt and clippy"
rustup component add --toolchain "${TOOLCHAIN}" rustfmt clippy
if test "${ARGS[0]}" == "cargo";then if test "${ARGS[0]}" == "cargo";then
PRE_COMMAND="cargo +${TOOLCHAIN} " PRE_COMMAND="cargo +${TOOLCHAIN} "
@ -46,5 +43,5 @@ COMMAND=$(
) )
# execute command # execute command
echo ">>> ${PRE_COMMAND} ${COMMAND}" echo "${PRE_COMMAND} ${COMMAND}"
${PRE_COMMAND} ${COMMAND} ${PRE_COMMAND} ${COMMAND}