~6x faster, stricter, configurable, extensible, and beautiful drop-in replacement for golint
docker pull mgechev/revive:latest
docker run -d --name revive --restart always mgechev/revive:latest
podman run -d --name revive --restart always mgechev/revive:latest
skopeo inspect docker://docker.io/mgechev/revive:latest
oras pull mgechev/revive:latest
FROM --platform=$BUILDPLATFORM golang:1.27.1 AS build
ARG VERSION
ARG REVISION
ARG BUILDTIME
ARG BUILDER
ARG TARGETOS
ARG TARGETARCH
ENV CGO_ENABLED=0
WORKDIR /src
COPY . .
RUN GOOS=${TARGETOS} GOARCH=${TARGETARCH} go build \
-ldflags "-X github.com/mgechev/revive/cli.version=${VERSION} -X github.com/mgechev/revive/cli.commit=${REVISION} -X github.com/mgechev/revive/cli.date=${BUILDTIME} -X github.com/mgechev/revive/cli.builtBy=${BUILDER}"
FROM scratch
COPY --from=build /src/revive /revive
ENTRYPOINT ["/revive"]