mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-06-08 14:14:19 +00:00
ci: disable windows build job to fix invalid workflow file
The build-windows job had an empty matrix platform list (amd64 was commented out), causing GitHub Actions validation to fail with "Unexpected value ''" on line 205. Comment out the entire job.
This commit is contained in:
parent
30b27bf091
commit
2d491e272c
1 changed files with 93 additions and 94 deletions
187
.github/workflows/release.yml
vendored
187
.github/workflows/release.yml
vendored
|
|
@ -193,98 +193,97 @@ jobs:
|
||||||
prerelease: true
|
prerelease: true
|
||||||
|
|
||||||
# =================================
|
# =================================
|
||||||
# Windows Build
|
# Windows Build (disabled)
|
||||||
# =================================
|
# =================================
|
||||||
build-windows:
|
# build-windows:
|
||||||
name: Build for Windows
|
# name: Build for Windows
|
||||||
needs: analyze
|
# needs: analyze
|
||||||
permissions:
|
# permissions:
|
||||||
contents: write
|
# contents: write
|
||||||
strategy:
|
# strategy:
|
||||||
matrix:
|
# matrix:
|
||||||
platform:
|
# platform:
|
||||||
# 手动注释,请勿更改
|
# - amd64
|
||||||
# - amd64
|
# runs-on: windows-latest
|
||||||
runs-on: windows-latest
|
# steps:
|
||||||
steps:
|
# - name: Checkout repository
|
||||||
- name: Checkout repository
|
# uses: actions/checkout@v6
|
||||||
uses: actions/checkout@v6
|
#
|
||||||
|
# - name: Setup Go
|
||||||
- name: Setup Go
|
# uses: actions/setup-go@v6
|
||||||
uses: actions/setup-go@v6
|
# with:
|
||||||
with:
|
# go-version-file: go.mod
|
||||||
go-version-file: go.mod
|
# check-latest: true
|
||||||
check-latest: true
|
#
|
||||||
|
# - name: Install MSYS2
|
||||||
- name: Install MSYS2
|
# uses: msys2/setup-msys2@v2
|
||||||
uses: msys2/setup-msys2@v2
|
# with:
|
||||||
with:
|
# msystem: MINGW64
|
||||||
msystem: MINGW64
|
# update: true
|
||||||
update: true
|
# install: >-
|
||||||
install: >-
|
# mingw-w64-x86_64-gcc
|
||||||
mingw-w64-x86_64-gcc
|
# mingw-w64-x86_64-sqlite3
|
||||||
mingw-w64-x86_64-sqlite3
|
# mingw-w64-x86_64-pkg-config
|
||||||
mingw-w64-x86_64-pkg-config
|
#
|
||||||
|
# - name: Build 3X-UI for Windows (CGO)
|
||||||
- name: Build 3X-UI for Windows (CGO)
|
# shell: msys2 {0}
|
||||||
shell: msys2 {0}
|
# run: |
|
||||||
run: |
|
# export PATH="/c/hostedtoolcache/windows/go/$(ls /c/hostedtoolcache/windows/go | sort -V | tail -n1)/x64/bin:$PATH"
|
||||||
export PATH="/c/hostedtoolcache/windows/go/$(ls /c/hostedtoolcache/windows/go | sort -V | tail -n1)/x64/bin:$PATH"
|
#
|
||||||
|
# export CGO_ENABLED=1
|
||||||
export CGO_ENABLED=1
|
# export GOOS=windows
|
||||||
export GOOS=windows
|
# export GOARCH=amd64
|
||||||
export GOARCH=amd64
|
# export CC=x86_64-w64-mingw32-gcc
|
||||||
export CC=x86_64-w64-mingw32-gcc
|
#
|
||||||
|
# which go
|
||||||
which go
|
# go version
|
||||||
go version
|
# gcc --version
|
||||||
gcc --version
|
#
|
||||||
|
# go build -ldflags "-w -s" -o xui-release.exe -v main.go
|
||||||
go build -ldflags "-w -s" -o xui-release.exe -v main.go
|
#
|
||||||
|
# - name: Copy and download resources
|
||||||
- name: Copy and download resources
|
# shell: pwsh
|
||||||
shell: pwsh
|
# run: |
|
||||||
run: |
|
# mkdir x-ui
|
||||||
mkdir x-ui
|
# Copy-Item xui-release.exe x-ui\x-ui.exe
|
||||||
Copy-Item xui-release.exe x-ui\x-ui.exe
|
# mkdir x-ui\bin
|
||||||
mkdir x-ui\bin
|
# cd x-ui\bin
|
||||||
cd x-ui\bin
|
#
|
||||||
|
# # Download Xray for Windows
|
||||||
# Download Xray for Windows
|
# $Xray_URL = "https://github.com/XTLS/Xray-core/releases/download/v26.2.6/"
|
||||||
$Xray_URL = "https://github.com/XTLS/Xray-core/releases/download/v26.2.6/"
|
# Invoke-WebRequest -Uri "${Xray_URL}Xray-windows-64.zip" -OutFile "Xray-windows-64.zip"
|
||||||
Invoke-WebRequest -Uri "${Xray_URL}Xray-windows-64.zip" -OutFile "Xray-windows-64.zip"
|
# Expand-Archive -Path "Xray-windows-64.zip" -DestinationPath .
|
||||||
Expand-Archive -Path "Xray-windows-64.zip" -DestinationPath .
|
# Remove-Item "Xray-windows-64.zip"
|
||||||
Remove-Item "Xray-windows-64.zip"
|
# Remove-Item geoip.dat, geosite.dat -ErrorAction SilentlyContinue
|
||||||
Remove-Item geoip.dat, geosite.dat -ErrorAction SilentlyContinue
|
# Invoke-WebRequest -Uri "https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geoip.dat" -OutFile "geoip.dat"
|
||||||
Invoke-WebRequest -Uri "https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geoip.dat" -OutFile "geoip.dat"
|
# Invoke-WebRequest -Uri "https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geosite.dat" -OutFile "geosite.dat"
|
||||||
Invoke-WebRequest -Uri "https://github.com/Loyalsoldier/v2ray-rules-dat/releases/latest/download/geosite.dat" -OutFile "geosite.dat"
|
# Invoke-WebRequest -Uri "https://github.com/chocolate4u/Iran-v2ray-rules/releases/latest/download/geoip.dat" -OutFile "geoip_IR.dat"
|
||||||
Invoke-WebRequest -Uri "https://github.com/chocolate4u/Iran-v2ray-rules/releases/latest/download/geoip.dat" -OutFile "geoip_IR.dat"
|
# Invoke-WebRequest -Uri "https://github.com/chocolate4u/Iran-v2ray-rules/releases/latest/download/geosite.dat" -OutFile "geosite_IR.dat"
|
||||||
Invoke-WebRequest -Uri "https://github.com/chocolate4u/Iran-v2ray-rules/releases/latest/download/geosite.dat" -OutFile "geosite_IR.dat"
|
# Invoke-WebRequest -Uri "https://github.com/runetfreedom/russia-v2ray-rules-dat/releases/latest/download/geoip.dat" -OutFile "geoip_RU.dat"
|
||||||
Invoke-WebRequest -Uri "https://github.com/runetfreedom/russia-v2ray-rules-dat/releases/latest/download/geoip.dat" -OutFile "geoip_RU.dat"
|
# Invoke-WebRequest -Uri "https://github.com/runetfreedom/russia-v2ray-rules-dat/releases/latest/download/geosite.dat" -OutFile "geosite_RU.dat"
|
||||||
Invoke-WebRequest -Uri "https://github.com/runetfreedom/russia-v2ray-rules-dat/releases/latest/download/geosite.dat" -OutFile "geosite_RU.dat"
|
# Rename-Item xray.exe xray-windows-amd64.exe
|
||||||
Rename-Item xray.exe xray-windows-amd64.exe
|
# cd ..
|
||||||
cd ..
|
# Copy-Item -Path ..\windows_files\* -Destination . -Recurse
|
||||||
Copy-Item -Path ..\windows_files\* -Destination . -Recurse
|
# cd ..
|
||||||
cd ..
|
#
|
||||||
|
# - name: Package to Zip
|
||||||
- name: Package to Zip
|
# shell: pwsh
|
||||||
shell: pwsh
|
# run: |
|
||||||
run: |
|
# Compress-Archive -Path .\x-ui -DestinationPath "x-ui-windows-amd64.zip"
|
||||||
Compress-Archive -Path .\x-ui -DestinationPath "x-ui-windows-amd64.zip"
|
#
|
||||||
|
# - name: Upload files to Artifacts
|
||||||
- name: Upload files to Artifacts
|
# uses: actions/upload-artifact@v7
|
||||||
uses: actions/upload-artifact@v7
|
# with:
|
||||||
with:
|
# name: x-ui-windows-amd64
|
||||||
name: x-ui-windows-amd64
|
# path: ./x-ui-windows-amd64.zip
|
||||||
path: ./x-ui-windows-amd64.zip
|
#
|
||||||
|
# - name: Upload files to GH release
|
||||||
- name: Upload files to GH release
|
# uses: svenstaro/upload-release-action@v2
|
||||||
uses: svenstaro/upload-release-action@v2
|
# if: github.event_name == 'release'
|
||||||
if: github.event_name == 'release'
|
# with:
|
||||||
with:
|
# repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
# tag: ${{ github.ref_name }}
|
||||||
tag: ${{ github.ref_name }}
|
# file: x-ui-windows-amd64.zip
|
||||||
file: x-ui-windows-amd64.zip
|
# asset_name: x-ui-windows-amd64.zip
|
||||||
asset_name: x-ui-windows-amd64.zip
|
# overwrite: true
|
||||||
overwrite: true
|
# prerelease: true
|
||||||
prerelease: true
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue