Some checks reported errors
continuous-integration/drone/push Build encountered an error
153 lines
3.9 KiB
YAML
153 lines
3.9 KiB
YAML
kind: pipeline
|
|
name: amd64 [debug]
|
|
|
|
platform:
|
|
arch: amd64
|
|
|
|
steps:
|
|
- name: build [debug]
|
|
image: rust:1.71.1-slim-bookworm
|
|
commands:
|
|
- rustc --version
|
|
- cargo --version
|
|
- cargo build --verbose --all
|
|
|
|
- name: test [debug]
|
|
image: rust:1.71.1-slim-bookworm
|
|
commands:
|
|
- rustc --version
|
|
- cargo --version
|
|
- cargo test --verbose --all
|
|
|
|
- name: lint-clippy [debug]
|
|
image: rust:1.71.1-slim-bookworm
|
|
commands:
|
|
- rustc --version
|
|
- cargo --version
|
|
- rustup component add clippy
|
|
- cargo clippy --verbose --all
|
|
|
|
---
|
|
kind: pipeline
|
|
name: arm64 [debug]
|
|
|
|
platform:
|
|
arch: arm64
|
|
|
|
steps:
|
|
- name: build [debug]
|
|
image: rust:1.71.1-slim-bookworm
|
|
commands:
|
|
- rustc --version
|
|
- cargo --version
|
|
# Stupid workarounds, for stupid problems
|
|
- echo "nameserver 1.1.1.1" >> /etc/resolv.conf
|
|
- echo "nameserver 1.0.0.1" >> /etc/resolv.conf
|
|
- cargo build --verbose --all
|
|
|
|
- name: test [debug]
|
|
image: rust:1.71.1-slim-bookworm
|
|
commands:
|
|
- rustc --version
|
|
- cargo --version
|
|
# Stupid workarounds, for stupid problems
|
|
- echo "nameserver 1.1.1.1" >> /etc/resolv.conf
|
|
- echo "nameserver 1.0.0.1" >> /etc/resolv.conf
|
|
- cargo test --verbose --all
|
|
|
|
- name: lint-clippy [debug]
|
|
image: rust:1.71.1-slim-bookworm
|
|
commands:
|
|
- rustc --version
|
|
- cargo --version
|
|
# Stupid workarounds, for stupid problems
|
|
- echo "nameserver 1.1.1.1" >> /etc/resolv.conf
|
|
- echo "nameserver 1.0.0.1" >> /etc/resolv.conf
|
|
- rustup component add clippy
|
|
- cargo clippy --verbose --all
|
|
|
|
---
|
|
kind: pipeline
|
|
name: amd64 [release]
|
|
|
|
platform:
|
|
arch: amd64
|
|
|
|
steps:
|
|
- name: build and test [release]
|
|
image: rust:1.71.1-slim-bookworm
|
|
commands:
|
|
- rustc --version
|
|
- cargo --version
|
|
- cargo test --verbose --all --release
|
|
|
|
---
|
|
kind: pipeline
|
|
name: arm64 [release]
|
|
|
|
platform:
|
|
arch: arm64
|
|
|
|
steps:
|
|
- name: build and test [release]
|
|
image: rust:1.71.1-slim-bookworm
|
|
commands:
|
|
- rustc --version
|
|
- cargo --version
|
|
# Stupid workarounds, for stupid problems
|
|
- echo "nameserver 1.1.1.1" >> /etc/resolv.conf
|
|
- echo "nameserver 1.0.0.1" >> /etc/resolv.conf
|
|
- cargo test --verbose --all --release
|
|
|
|
---
|
|
kind: pipeline
|
|
name: rustfmt
|
|
steps:
|
|
- name: Format Project with rustfmt
|
|
image: rust:1.71.1-alpine
|
|
commands:
|
|
- rustc --version
|
|
- cargo --version
|
|
# Stupid workarounds, for stupid problems
|
|
- echo "nameserver 1.1.1.1" >> /etc/resolv.conf
|
|
- echo "nameserver 1.0.0.1" >> /etc/resolv.conf
|
|
- rustup component add rustfmt
|
|
- cargo fmt --all --check && echo "No formatting required, exiting early..." && exit 0
|
|
- cargo fmt --all --verbose
|
|
- apk add git openssh
|
|
- "[ $(git log -1 --pretty=%B | grep -E ".+") = "rustfmt" ] && echo "format loop detected, aborting..." && exit 1"
|
|
- mkdir -p "$${HOME}/.ssh"
|
|
- echo "$SSH_PRIVATE_KEY" > "$${HOME}/.ssh/git"
|
|
- echo "Host git.libre.moe" >> "$${HOME}/.ssh/config"
|
|
- echo " User git" >> "$${HOME}/.ssh/config"
|
|
- echo " IdentityFile $${HOME}/.ssh/git" >> "$${HOME}/.ssh/config"
|
|
- echo "$GITEA_ED25519_SIG" >> "$${HOME}/.ssh/known_hosts"
|
|
- echo "$GITEA_RSA_SIG" >> "$${HOME}/.ssh/known_hosts"
|
|
- echo "$GITEA_ECDSA_SIG" >> "$${HOME}/.ssh/known_hosts"
|
|
- cat "$${HOME}/.ssh/config"
|
|
- chmod 700 -R "$${HOME}/.ssh"
|
|
- git config --local user.name "wanessa"
|
|
- git config --local user.email "$GIT_EMAIL_ADDRESS"
|
|
- git config core.sshCommand '/usr/bin/ssh -v'
|
|
- git remote add ssh "$DRONE_GIT_SSH_URL"
|
|
- git add *
|
|
- git status
|
|
- git commit -m "rustfmt"
|
|
- GIT_TRACE=1 GIT_SSH=1 git push ssh
|
|
environment:
|
|
SSH_PRIVATE_KEY:
|
|
from_secret: WANESSA_SSH_PRIVKEY
|
|
GIT_EMAIL_ADDRESS:
|
|
from_secret: WANESSA_EMAIL_ADDRESS
|
|
GITEA_ED25519_SIG:
|
|
from_secret: GIT_ED25519_SIG
|
|
GITEA_RSA_SIG:
|
|
from_secret: GIT_RSA_SIG
|
|
GITEA_ECDSA_SIG:
|
|
from_secret: GIT_ECDSA_SIG
|
|
|
|
#depends_on:
|
|
#- amd64 [debug]
|
|
#- arm64 [debug]
|
|
#- amd64 [release]
|
|
#- arm64 [release] |