From a040881cfa8f70dbddf030da9cd478780e536acb Mon Sep 17 00:00:00 2001 From: Alexandr Bogomyakov Date: Thu, 31 Aug 2023 21:07:02 +0300 Subject: [PATCH] Fix --- .github/workflows/release.yml | 82 +++++++++++++++-------------------- PKGBUILD | 14 +----- 2 files changed, 36 insertions(+), 60 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 0982192..492bba8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,8 +1,8 @@ name: Rust static build and publish -on: - push: - tags: - - '*' +on: ["push"] +# push: +# tags: +# - '*' env: CARGO_TERM_COLOR: always BUILD_TARGET: x86_64-unknown-linux-musl @@ -29,52 +29,38 @@ jobs: name: ${{ env.BINARY_NAME }}_x86_64-linux-musl path: target/x86_64-unknown-linux-musl/release/${{ env.BINARY_NAME }} -# build_arch: -# name: Arch Linux package -# runs-on: ubuntu-latest -# permissions: -# contents: write -# steps: -# - uses: actions/checkout@v3 -# - name: Install latest nightly -# uses: actions-rs/toolchain@v1 -# with: -# toolchain: stable -# override: true -# target: x86_64-unknown-linux-musl -# components: rustfmt -# - name: Install cargo-aur -# run: cargo install cargo-aur -# - name: Build PKGBUILD -# uses: actions-rs/cargo@v1 -# with: -# command: aur -# - uses: actions/upload-artifact@v2 -# name: Upload artifact PKGBUILD -# with: -# path: PKGBUILD -# name: PKGBUILD - - release: - name: Release binary - needs: ["build"] - runs-on: ubuntu-latest - permissions: - contents: write - steps: + build_arch: + name: Arch Linux package + runs-on: ubuntu-latest + container: + image: archlinux + permissions: + contents: write + steps: - uses: actions/download-artifact@master + name: Download built binary id: download_binary with: name: ${{ env.BINARY_NAME }}_x86_64-linux-musl path: ${{ env.BINARY_NAME }}_x86_64-linux-musl -# - uses: actions/download-artifact@master -# id: download_pkgbuild -# with: -# name: PKGBUILD -# path: PKGBUILD - - uses: ncipollo/release-action@v1 - name: Update release page - with: - artifacts: "${{ steps.download_binary.outputs.download-path }}/*" - allowUpdates: true - body: Static build for x86_64-linux using MUSL + - name: List + run: ls -lah + +# release: +# name: Release binary +# needs: ["build", "build_arch"] +# runs-on: ubuntu-latest +# permissions: +# contents: write +# steps: +# - uses: actions/download-artifact@master +# id: download_binary +# with: +# name: ${{ env.BINARY_NAME }}_x86_64-linux-musl +# path: ${{ env.BINARY_NAME }}_x86_64-linux-musl +# - uses: ncipollo/release-action@v1 +# name: Update release page +# with: +# artifacts: "${{ steps.download_binary.outputs.download-path }}/*" +# allowUpdates: true +# body: Static build for x86_64-linux using MUSL diff --git a/PKGBUILD b/PKGBUILD index 5cab9ee..b75f9b4 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -8,18 +8,8 @@ license=("WTFPL") arch=("x86_64") makedepends=("rustup") -pkgver() { - echo "$pkgver" | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' -} - -build() { - return 0 -} - package() { - cd .. - usrdir="$pkgdir/usr" - mkdir -p $usrdir - cargo install --target=x86_64-unknown-linux-musl --no-track --path . --root "$usrdir" + install -Dm755 "$startdir/target/x86_64-unknown-linux-musl/release/rexec" "$pkgdir/usr/bin/rexec" } +