mirror of
https://github.com/YuWanTingbb/unofficial-gpt4.git
synced 2025-10-14 06:08:06 +00:00
Create publish.yml
This commit is contained in:
41
.github/workflows/publish.yml
vendored
Normal file
41
.github/workflows/publish.yml
vendored
Normal file
@@ -0,0 +1,41 @@
|
||||
name: Build and Release
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- 'v*'
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
container:
|
||||
image: devatherock/graalvm:21-ol8
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: actions/checkout@v2
|
||||
|
||||
- name: Build binaries
|
||||
run: |
|
||||
chmod +x ./mvnw
|
||||
./mvnw native:compile -Pnative
|
||||
|
||||
- name: Create Release
|
||||
id: create_release
|
||||
uses: actions/create-release@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
tag_name: ${{ github.ref }}
|
||||
release_name: Release ${{ github.ref }}
|
||||
draft: false
|
||||
prerelease: false
|
||||
|
||||
- name: Upload Release Asset
|
||||
id: upload-release-asset
|
||||
uses: actions/upload-release-asset@v1
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
with:
|
||||
upload_url: ${{ steps.create_release.outputs.upload_url }}
|
||||
asset_path: ./target/gpt4-copilot-java # 更新为你的二进制文件路径
|
||||
asset_name: gpt4-copilot-java # 更新为你的二进制文件名
|
||||
asset_content_type: application/octet-stream
|
Reference in New Issue
Block a user