mirror of
https://github.com/RubyMetric/chsrc
synced 2025-10-10 06:03:24 +08:00
Rename workflows and add headers
This commit is contained in:
63
.github/workflows/build-on-Windows.yml
vendored
Normal file
63
.github/workflows/build-on-Windows.yml
vendored
Normal file
@@ -0,0 +1,63 @@
|
||||
# ---------------------------------------------------------------
|
||||
# Workflow File : build-on-Windows.yml
|
||||
# File Authors : Aoran Zeng <ccmywish@qq.com>
|
||||
# Contributors : Nul None <nul@none.org>
|
||||
# |
|
||||
# Created On : <2023-09-14>
|
||||
# Last Modified : <2025-03-06>
|
||||
#
|
||||
# Build chsrc on Windows and upload it to GitHub: the 'pre' release
|
||||
# ---------------------------------------------------------------
|
||||
|
||||
name: Build on Windows
|
||||
on:
|
||||
push:
|
||||
branches: [ "gh-build" ]
|
||||
pull_request:
|
||||
branches: [ "gh-build" ]
|
||||
|
||||
jobs:
|
||||
build-and-upload:
|
||||
runs-on: windows-latest
|
||||
defaults:
|
||||
run:
|
||||
shell: msys2 {0}
|
||||
|
||||
steps:
|
||||
|
||||
- name: Checkout repo
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Install x64 gcc
|
||||
uses: msys2/setup-msys2@v2
|
||||
with:
|
||||
msystem: UCRT64
|
||||
update: true
|
||||
install: |
|
||||
mingw-w64-ucrt-x86_64-gcc
|
||||
mingw-w64-ucrt-x86_64-make
|
||||
mingw-w64-i686-gcc
|
||||
mingw-w64-i686-make
|
||||
|
||||
- name: Build
|
||||
run: |
|
||||
mingw32-make.exe CI CI_ARTIFACT_NAME=chsrc-x64-windows
|
||||
|
||||
- name: Compile chsrc x86
|
||||
env:
|
||||
MSYSTEM: MINGW32
|
||||
run: |
|
||||
mingw32-make.exe CI CI_ARTIFACT_NAME=chsrc-x86-windows
|
||||
|
||||
- name: List files
|
||||
run: ls *.exe
|
||||
|
||||
- name: Upload
|
||||
uses: softprops/action-gh-release@v1
|
||||
# if: startsWith(github.ref, 'refs/tags/')
|
||||
with:
|
||||
tag_name: pre
|
||||
files: |
|
||||
chsrc-x64-windows.exe
|
||||
chsrc-x86-windows.exe
|
||||
token: ${{ secrets.UPLOAD_TO_GITHUB }}
|
Reference in New Issue
Block a user