mirror of
https://hubproxy.babadafafafafa.cn/https://github.com/Mapleawaa/PVE-Tools-9.git
synced 2026-09-20 08:03:35 +08:00
fix(release): shc 静态编译解决 glibc 版本不匹配问题
- release.yml: CFLAGS=\ Signed-off-by: Maple <Mapleawa07@outlook.com>
This commit is contained in:
26
.github/workflows/beta-release.yml
vendored
26
.github/workflows/beta-release.yml
vendored
@@ -26,6 +26,20 @@ jobs:
|
||||
echo "TAG=$TAG" >> $GITHUB_OUTPUT
|
||||
echo "VERSION=$VERSION" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: Build single script from modules
|
||||
run: bash build.sh
|
||||
|
||||
- name: Install shc
|
||||
run: |
|
||||
sudo add-apt-repository ppa:neurobin/ppa -y
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y shc
|
||||
|
||||
- name: Compile script to binary (statically linked)
|
||||
run: |
|
||||
CFLAGS="-static" shc -r -f dist/PVE-Tools.sh -o pve-tools
|
||||
chmod +x pve-tools
|
||||
|
||||
- name: Create GitHub Release
|
||||
uses: softprops/action-gh-release@v2
|
||||
with:
|
||||
@@ -38,9 +52,19 @@ jobs:
|
||||
|
||||
## 安装方式
|
||||
|
||||
**方式一:直接运行脚本 (推荐)**
|
||||
```bash
|
||||
bash <(curl -sSL https://github.com/PVE-Tools/PVE-Tools-9/blob/beta/PVE-Tools.sh)
|
||||
bash -c "$(curl -fsSL https://raw.githubusercontent.com/PVE-Tools/PVE-Tools-9/beta/dist/PVE-Tools.sh)"
|
||||
```
|
||||
|
||||
**方式二:下载二进制文件**
|
||||
```bash
|
||||
chmod +x pve-tools
|
||||
./pve-tools
|
||||
```
|
||||
files: |
|
||||
pve-tools
|
||||
dist/PVE-Tools.sh
|
||||
draft: false
|
||||
prerelease: true
|
||||
env:
|
||||
|
||||
6
.github/workflows/release.yml
vendored
6
.github/workflows/release.yml
vendored
@@ -33,11 +33,11 @@ jobs:
|
||||
run: |
|
||||
sudo add-apt-repository ppa:neurobin/ppa -y
|
||||
sudo apt-get update
|
||||
sudo apt-get install shc -y
|
||||
sudo apt-get install -y shc
|
||||
|
||||
- name: Compile script to binary
|
||||
- name: Compile script to binary (statically linked)
|
||||
run: |
|
||||
shc -f dist/PVE-Tools.sh -o pve-tools
|
||||
CFLAGS="-static" shc -r -f dist/PVE-Tools.sh -o pve-tools
|
||||
chmod +x pve-tools
|
||||
|
||||
- name: Generate release notes
|
||||
|
||||
Reference in New Issue
Block a user