Skip to content

Added upgrade command #55

Added upgrade command

Added upgrade command #55

Workflow file for this run

name: Release
permissions:
contents: write
on:
push:
tags:
- v[0-9]+.*
jobs:
create-release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: taiki-e/create-gh-release-action@v1
with:
# (optional) Path to changelog.
# changelog: CHANGELOG.md
# (required) GitHub token for creating GitHub Releases.
token: ${{ secrets.GITHUB_TOKEN }}
build:
strategy:
matrix:
include:
- target: aarch64-apple-darwin
os: macos-latest
- target: aarch64-unknown-linux-gnu
os: ubuntu-latest
- target: x86_64-unknown-linux-gnu
os: ubuntu-latest
runs-on: ${{ matrix.os }}
env:
TARGET: ${{ matrix.TARGET }}
OS: ${{ matrix.OS }}
GH_TOKEN: ${{ github.token }}
steps:
- uses: actions/checkout@v4
- name: Cargo cache
uses: actions/cache@v2
with:
path: |
~/.cargo/registry
./target
key: build-cargo-registry-${{matrix.TARGET}}
- name: Install and configure dependencies
run: |
# dependencies are only needed on ubuntu as that's the only place where
# we make cross-compilation
if [[ $OS =~ ^ubuntu.*$ ]]; then
sudo apt-get install -qq crossbuild-essential-arm64 crossbuild-essential-armhf protobuf-compiler libprotobuf-dev
fi
# some additional configuration for cross-compilation on linux
cat >>~/.cargo/config <<EOF
[target.aarch64-unknown-linux-gnu]
linker = "aarch64-linux-gnu-gcc"
[target.aarch64-unknown-linux-musl]
linker = "aarch64-linux-gnu-gcc"
EOF
- name: Install rust target
run: rustup target add $TARGET
- name: Build Binary
run: cargo build --locked --release --target ${{ matrix.target }}
- name: Archive and upload
run: |
mkdir -p dist
cd dist
cp ../target/$TARGET/release/skate .
cp ../target/$TARGET/release/skatelet .
tar -cvf skate-$TARGET.tar.gz skate
tar -cvf skatelet-$TARGET.tar.gz skatelet
gh release upload ${{github.ref_name}} *.tar.gz