From b1707f3e66b823f67f60c315cbed53510fe6ba2b Mon Sep 17 00:00:00 2001 From: Helio Machado <0x2b3bfa0+git@googlemail.com> Date: Sat, 8 Oct 2022 06:28:40 +0200 Subject: [PATCH] Fix release workflows, again (#1214) * Use fallback false value on test-deploy workflow * Replace `softprops/action-gh-release` with `gh` --- .github/workflows/test-deploy.yml | 38 ++++++++----------------------- package-lock.json | 4 ++-- package.json | 2 +- 3 files changed, 13 insertions(+), 31 deletions(-) diff --git a/.github/workflows/test-deploy.yml b/.github/workflows/test-deploy.yml index 05333b1ef..6f4fb3434 100644 --- a/.github/workflows/test-deploy.yml +++ b/.github/workflows/test-deploy.yml @@ -102,42 +102,24 @@ jobs: registry-url: https://registry.npmjs.org - run: npm install - run: - npm ${{ inputs.release && 'publish' || 'publish --dry-run' }} + npm ${{ inputs.release && 'publish' || 'publish --dry-run' }} || ${{ + inputs.release && 'true' || 'false' }} env: NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} - - name: install ldid - run: | + - run: | sudo apt install --yes libplist-dev git clone --branch v2.1.5 git://git.saurik.com/ldid.git sudo g++ -pipe -o /usr/bin/ldid ldid/ldid.cpp -I. -x c ldid/{lookup2.c,sha1.h} -lplist -lcrypto - - id: build - name: build - run: | - echo ::set-output name=tag::${GITHUB_REF#refs/tags/} + - run: | cp node_modules/@npcz/magic/dist/magic.mgc assets/magic.mgc npx --yes pkg --no-bytecode --public-packages "*" --public package.json - rm assets/magic.mgc - for cmd in '' runner publish pr; do - build/cml-linux-x64 $cmd --version - done + for cmd in '' runner publish pr; do build/cml-linux-x64 $cmd --version; done cp build/cml-linux{-x64,} cp build/cml-macos{-x64,} - - uses: softprops/action-gh-release@v1 - if: inputs.release - with: - files: | - build/cml-alpine-arm64 - build/cml-alpine-x64 - build/cml-linux-arm64 - build/cml-linuxstatic-arm64 - build/cml-linuxstatic-x64 - build/cml-linux-x64 - build/cml-linux - build/cml-macos-arm64 - build/cml-macos-x64 - build/cml-macos - build/cml-win-arm64.exe - build/cml-win-x64.exe + - if: inputs.release + run: + find build -type f | xargs gh release upload $(basename ${{ + github.head_ref }}) env: GITHUB_TOKEN: ${{ secrets.TEST_GITHUB_TOKEN }} images: @@ -145,4 +127,4 @@ jobs: secrets: inherit uses: ./.github/workflows/images.yml with: - release: ${{ inputs.release }} + release: ${{ inputs.release || false }} diff --git a/package-lock.json b/package-lock.json index 0068608d3..a0ab015f4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@dvcorg/cml", - "version": "0.18.1", + "version": "0.18.0", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@dvcorg/cml", - "version": "0.18.1", + "version": "0.18.0", "license": "Apache-2.0", "dependencies": { "@actions/core": "^1.9.1", diff --git a/package.json b/package.json index 39853c0c8..1b37f4033 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@dvcorg/cml", - "version": "0.18.1", + "version": "0.18.0", "description": "

", "author": { "name": "Iterative Inc",