From bea86e15a42cb7f9c1341317293bf6ca4e680bfa Mon Sep 17 00:00:00 2001 From: liufang Date: Sun, 16 Jun 2024 20:49:11 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=AE=8C=E5=96=84=E6=9E=84=E5=BB=BA?= =?UTF-8?q?=E5=AE=89=E8=A3=85=E9=80=BB=E8=BE=91?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/linux_cpp_release.yml | 2 +- .github/workflows/linux_dotnet_release.yml | 19 ++-- .../workflows/linux_python_aarch64_build.yml | 2 +- .../linux_python_aarch64_release.yml | 90 +++++++++---------- .github/workflows/release.yml | 5 +- 5 files changed, 60 insertions(+), 58 deletions(-) diff --git a/.github/workflows/linux_cpp_release.yml b/.github/workflows/linux_cpp_release.yml index eb3a73a..59ae2a6 100644 --- a/.github/workflows/linux_cpp_release.yml +++ b/.github/workflows/linux_cpp_release.yml @@ -48,7 +48,7 @@ jobs: uses: actions/configure-pages@v2 - name: Upload artifact - uses: actions/upload-pages-artifact@v1 + uses: actions/upload-pages-artifact@v4 with: # Upload entire repository path: './build/html' diff --git a/.github/workflows/linux_dotnet_release.yml b/.github/workflows/linux_dotnet_release.yml index fb8eeaf..c8c042d 100644 --- a/.github/workflows/linux_dotnet_release.yml +++ b/.github/workflows/linux_dotnet_release.yml @@ -24,19 +24,18 @@ jobs: - name: Check dotnet run: dotnet --info - - name: configure + - name: Configure run: cmake -S. -Bbuild -DBUILD_DOTNET=ON - - name: build - run: cmake --build build + - name: Build + run: cmake --build build - - name: upload pacakges - run: - cd ./build/dotnet/packages; - dotnet nuget push lebai.runtime.linux-x64.1.*.*.nupkg --api-key ${{ secrets.NUGET_KEY }} --source https://api.nuget.org/v3/index.json; - dotnet nuget push lebai.1.*.*.nupkg --api-key ${{ secrets.NUGET_KEY }} --source https://api.nuget.org/v3/index.json; - - - name: Upload artifact + - name: Upload pacakges + run: | + cd ./build/dotnet/packages + dotnet nuget push lebai.runtime.linux-x64.1.*.*.nupkg --api-key ${{ secrets.NUGET_KEY }} --source https://api.nuget.org/v3/index.json + dotnet nuget push lebai.1.*.*.nupkg --api-key ${{ secrets.NUGET_KEY }} --source https://api.nuget.org/v3/index.json + - name: Upload artifacts uses: actions/upload-artifact@v4 id: artifact with: diff --git a/.github/workflows/linux_python_aarch64_build.yml b/.github/workflows/linux_python_aarch64_build.yml index 8ab92f4..bc4cd0d 100644 --- a/.github/workflows/linux_python_aarch64_build.yml +++ b/.github/workflows/linux_python_aarch64_build.yml @@ -2,7 +2,7 @@ name: Linux python aarch64 build run-name: ${{ github.actor }} Linux python aarch64 build on: workflow_dispatch: - pull_request: + # pull_request: jobs: linux_python_aarch64_build: runs-on: [self-hosted, Linux, ARM64] diff --git a/.github/workflows/linux_python_aarch64_release.yml b/.github/workflows/linux_python_aarch64_release.yml index f4a3be3..b72ffac 100644 --- a/.github/workflows/linux_python_aarch64_release.yml +++ b/.github/workflows/linux_python_aarch64_release.yml @@ -1,45 +1,45 @@ -name: Linux python aarch64 release -run-name: ${{ github.actor }} Linux python aarch64 release -on: - workflow_dispatch: - push: - tags: - - v1.*.* -# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages -permissions: - contents: read - pages: write - id-token: write - pull-requests: read - -jobs: - linux_python_aarch64_build_and_release: - runs-on: [self-hosted, Linux, ARM64] - container: quay.io/pypa/manylinux2014_aarch64 - steps: - - name: Checkout - uses: actions/checkout@v1 - - run: ls /opt/python/ - - run: for PYBIN in /opt/python/*/bin;do "${PYBIN}/pip" install -i https://mirrors.aliyun.com/pypi/simple/ -r requirements.txt; done; - - run: /opt/python/cp310-cp310/bin/pip install -i https://mirrors.aliyun.com/pypi/simple/ twine==2.0 urllib3==1.24. markdown - - name: configure - run: cmake -S. -Bbuild -DBUILD_TESTING=OFF -DBUILD_PYTHON=ON - - name: build - run: cmake --build build - - name: create-whl-dir - run: mkdir -p whl - - name: build with python - run: for PY in /opt/python/*;do - rm -rf build; - cmake -S. -Bbuild -DBUILD_TESTING=OFF -DBUILD_PYTHON=ON -DPYTHONPATH=${PY}; - cmake --build build; - cp build/python/dist/*.whl whl/; - done; - - - name: repair - run: for PYWHL in whl/*.whl;do - auditwheel repair ${PYWHL}; - done; - - - name: upload Pypi - run: /opt/python/cp310-cp310/bin/twine upload --skip-existing -u __token__ -p ${{ secrets.PYLEBAI }} wheelhouse/*.whl +name: Linux python aarch64 release +run-name: ${{ github.actor }} Linux python aarch64 release +on: + workflow_dispatch: + # push: + # tags: + # - v1.*.* +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages +permissions: + contents: read + pages: write + id-token: write + pull-requests: read + +jobs: + linux_python_aarch64_build_and_release: + runs-on: [self-hosted, Linux, ARM64] + container: quay.io/pypa/manylinux2014_aarch64 + steps: + - name: Checkout + uses: actions/checkout@v1 + - run: ls /opt/python/ + - run: for PYBIN in /opt/python/*/bin;do "${PYBIN}/pip" install -i https://mirrors.aliyun.com/pypi/simple/ -r requirements.txt; done; + - run: /opt/python/cp310-cp310/bin/pip install -i https://mirrors.aliyun.com/pypi/simple/ twine==2.0 urllib3==1.24. markdown + - name: configure + run: cmake -S. -Bbuild -DBUILD_TESTING=OFF -DBUILD_PYTHON=ON + - name: build + run: cmake --build build + - name: create-whl-dir + run: mkdir -p whl + - name: build with python + run: for PY in /opt/python/*;do + rm -rf build; + cmake -S. -Bbuild -DBUILD_TESTING=OFF -DBUILD_PYTHON=ON -DPYTHONPATH=${PY}; + cmake --build build; + cp build/python/dist/*.whl whl/; + done; + + - name: repair + run: for PYWHL in whl/*.whl;do + auditwheel repair ${PYWHL}; + done; + + - name: upload Pypi + run: /opt/python/cp310-cp310/bin/twine upload --skip-existing -u __token__ -p ${{ secrets.PYLEBAI }} wheelhouse/*.whl diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3530b37..b6f5dbd 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -49,4 +49,7 @@ jobs: allowUpdates: true artifacts: | *.exe, - *.deb + *.deb, + *.nupkg, + *.whl +