CGGItemSets/.drone.yml

19 lines
924 B
YAML
Raw Normal View History

2020-06-28 15:50:19 +02:00
kind: pipeline
type: docker
name: default
steps:
- name: build
2020-06-28 16:20:11 +02:00
image: rust:alpine
2020-06-28 15:50:19 +02:00
commands:
2020-06-29 13:26:50 +02:00
- apk add --no-cache mingw-w64-gcc musl-dev curl
2020-06-28 16:20:11 +02:00
- mkdir ~/.cargo
- echo -e '[target.x86_64-pc-windows-gnu]\nlinker = "x86_64-w64-mingw32-gcc"\nar = "x86_64-w64-mingw32-gcc-ar"' > ~/.cargo/config
- rustup toolchain install stable-x86_64-pc-windows-gnu
- rustup target add x86_64-pc-windows-gnu
- cargo build --release --target x86_64-pc-windows-gnu
2020-06-29 13:26:50 +02:00
- curl -u drone:$MVN_PWD -X POST 'https://nexus.nyyu.dev/service/rest/v1/components?repository=maven-releases' -F maven2.groupId=dev.nyyu -F maven2.artifactId=cggitem_sets -F maven2.version=$(awk -F ' = ' '$1 ~ /version/ { gsub(/["]/, "", $2); printf("%s",$2) }' Cargo.toml)-$(date +%Y%m%d%H%M%S) -F maven2.asset1=@target/x86_64-pc-windows-gnu/release/cggitem_sets.exe -F maven2.asset1.extension=exe
environment:
MVN_PWD:
from_secret: maven_password