Skip to content

Commit

Permalink
feat: 添加输出到release
Browse files Browse the repository at this point in the history
  • Loading branch information
HalfSweet committed Jan 2, 2025
1 parent 506895e commit 41b5ad1
Show file tree
Hide file tree
Showing 3 changed files with 29 additions and 32 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ on:
paths:
- '.github/workflows/HPM-build.yml'
- 'projects/HSLink-Pro/**'
tags:
- 'HSLinkPro*'
pull_request:
paths:
- '.github/workflows/HPM-build.yml'
Expand All @@ -23,11 +25,6 @@ jobs:

- uses: gregdavill/[email protected]

# 创建riscv-none-elf-到riscv32-unknown-elf-的软链接
- name: Create riscv-none-elf- to riscv32-unknown-elf- symlink
run: |
sudo bash ./.github/workflows/create_riscv32_symlink.sh
- name: Install HPM SDK
run: |
cd ~
Expand All @@ -49,7 +46,7 @@ jobs:
export HPM_SDK_TOOLCHAIN_VARIANT=gcc
export PYTHON_EXECUTABLE=~/HPM_PYTHON/bin/python3
cmake -GNinja -DBOARD=hpm5301evklite -DHPM_BUILD_TYPE=flash_xip -DCMAKE_BUILD_TYPE=release -Dpython_exec="~/HPM_PYTHON/bin/python3" -DRV_ARCH="rv32imac_zicsr_zifencei" . -B=./build
cmake -GNinja -DBOARD=hpm5301evklite -DHPM_BUILD_TYPE=flash_xip -DCMAKE_BUILD_TYPE=release -Dpython_exec="~/HPM_PYTHON/bin/python3" -DCUSTOM_TARGET_TRIPLET=riscv-none-elf -DRV_ARCH="rv32imac_zicsr_zifencei" . -B=./build
cmake --build ./build
- name: Build APP
Expand All @@ -60,7 +57,7 @@ jobs:
export HPM_SDK_TOOLCHAIN_VARIANT=gcc
export PYTHON_EXECUTABLE=~/HPM_PYTHON/bin/python3
cmake -GNinja -DBOARD=hpm5301evklite -DHPM_BUILD_TYPE=flash_uf2 -DCMAKE_BUILD_TYPE=release -Dpython_exec="~/HPM_PYTHON/bin/python3" -DRV_ARCH="rv32imac_zicsr_zifencei" . -B=./build
cmake -GNinja -DBOARD=hpm5301evklite -DHPM_BUILD_TYPE=flash_uf2 -DCMAKE_BUILD_TYPE=release -Dpython_exec="~/HPM_PYTHON/bin/python3" -DCUSTOM_TARGET_TRIPLET=riscv-none-elf -DRV_ARCH="rv32imac_zicsr_zifencei" . -B=./build
cmake --build ./build
- name: Merge Bin
Expand All @@ -80,9 +77,31 @@ jobs:
- name: Upload file
uses: actions/upload-artifact@v4
with:
name: release
name: build-artifact
path: |
releases/HSLink-Pro-Bootloader.bin
releases/HSLink-Pro.uf2
releases/HSLink-Pro.bin
releases/Merger.bin
releases/Merger.bin
release:
runs-on: ubuntu-latest
needs: build
if: startsWith(github.ref, 'refs/tags/')
steps:
- uses: actions/checkout@v4
with:
submodules: true

- name: Download release
uses: actions/download-artifact@v4
with:
name: build-artifact
path: releases

- name: Create Release
uses: ncipollo/release-action@v1
with:
artifacts: 'releases/*'
# tag: ${{ github.ref }}
allowUpdates: true
22 changes: 0 additions & 22 deletions .github/workflows/create_riscv32_symlink.sh

This file was deleted.

2 changes: 1 addition & 1 deletion projects/HSLink-Pro/src/.version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.2.4.IO
2.3.0

0 comments on commit 41b5ad1

Please sign in to comment.