mirror of
https://github.com/shiroyashik/sculptor.git
synced 2025-12-06 13:01:12 +03:00
rework the build system
- use rustls for reqwest, so we don't need to compile OpenSSL - use better defaults for build arguments in Dockerfile - add Continuous Integration workflow for master branch and it's pull requests - add Release workflow for tags matching SemVer - add release template for automatic release notes generation with GH CLI - remove old and unused assets under .github
This commit is contained in:
parent
1c38c402b9
commit
e21cbd1f63
13 changed files with 462 additions and 810 deletions
8
.github/scripts/compress-artifact.sh
vendored
Executable file
8
.github/scripts/compress-artifact.sh
vendored
Executable file
|
|
@ -0,0 +1,8 @@
|
|||
#!/bin/bash
|
||||
BINARY_FILE="target/$1/release/sculptor"
|
||||
COMMON_FILES=("Config.example.toml")
|
||||
ARTIFACT_OUTPUT="${OUTPUT_DIR}/sculptor-$2-$3"
|
||||
if [ "$2" = "windows" ]
|
||||
then zip -j "${ARTIFACT_OUTPUT}.zip" "${BINARY_FILE}.exe" "${COMMON_FILES[@]}"
|
||||
else tar --transform 's|^.*/||' -czf "${ARTIFACT_OUTPUT}.tar.gz" "$BINARY_FILE" "${COMMON_FILES[@]}"
|
||||
fi
|
||||
12
.github/scripts/package-artifacts.sh
vendored
Executable file
12
.github/scripts/package-artifacts.sh
vendored
Executable file
|
|
@ -0,0 +1,12 @@
|
|||
#!/bin/bash
|
||||
set -euo pipefail
|
||||
|
||||
export OUTPUT_DIR
|
||||
mkdir -p "$OUTPUT_DIR"
|
||||
|
||||
printenv CARGO_BUILD_TARGETS | awk -F, '{
|
||||
for (i = 1; i <= NF; i++)
|
||||
if (match($i, /^([^-]+)(-[^-]+)*-(linux|windows|darwin)(-[^-]+)*$/, matches))
|
||||
printf "%s\0%s\0%s\0", $i, matches[3], matches[1]
|
||||
else print "DEBUG: awk: No regex match for field index " i ": \047" $i "\047" > /dev/stderr
|
||||
}' | xargs -0 -n 3 "$(dirname -- "$(readlink -f -- "$0")")/compress-artifact.sh"
|
||||
Loading…
Add table
Add a link
Reference in a new issue