Skip to content

Commit e5c1b1e

Browse files
committed
scripts
1 parent c38ab97 commit e5c1b1e

15 files changed

+99
-49
lines changed

.github/workflows/deploy.yml

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: main
2+
on: push
3+
jobs:
4+
main:
5+
runs-on: windows-latest
6+
steps:
7+
- name: checkout
8+
uses: actions/checkout@v4
9+
- name: setup-msys2
10+
uses: msys2/setup-msys2@v2
11+
with:
12+
msystem: ucrt64
13+
release: false
14+
install: mingw-w64-ucrt-x86_64-gcc mingw-w64-ucrt-x86_64-qt6-base mingw-w64-ucrt-x86_64-qwt-qt6
15+
- name: main
16+
shell: cmd
17+
run: |
18+
set PATH=C:\msys64\ucrt64\bin;%LOCALAPPDATA%\Programs\Python\Python311;%LOCALAPPDATA%\Programs\Python\Python311\Scripts;C:\Python311;C:\Python311\Scripts;C:\Program Files\Microsoft Visual Studio\2022\Enterprise\Common7\IDE\CommonExtensions\Microsoft\CMake\Ninja;C:\Program Files (x86)\Android\android-sdk\cmake\3.22.1\bin;C:\Miniconda;C:\Miniconda\Scripts;%PATH%
19+
where mugideploy > NUL 2>&1 || pip install mugideploy
20+
where ninja > NUL 2>&1 || pip install ninja
21+
call build-msys2
22+
mugideploy collect --bin Release-msys2\mugi-query.exe --plugins sqldrivers --zip
23+
- name: upload
24+
uses: actions/upload-artifact@v4
25+
with:
26+
name: test
27+
path: mugi-query-*-win64.zip

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,4 +23,5 @@ qtactiveqt-everywhere-src-6.7.1/
2323
mugi-query-0.0.1-win64_/
2424
qrc_icons.cpp
2525
CMakeLists.txt.user
26-
build/
26+
build/
27+
Release-msys2/

build-lld.bat

Lines changed: 0 additions & 15 deletions
This file was deleted.

build-lld.pbat

Lines changed: 0 additions & 14 deletions
This file was deleted.

build-msys2.bat

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
@echo off
2+
rem This file is generated from build-msys2.pbat, all edits will be lost
3+
set PATH=C:\msys64\ucrt64\bin;C:\Program Files\CMake\bin;%PATH%
4+
set BUILD_TYPE=Release
5+
if /I "%1"=="debug" set BUILD_TYPE=Debug
6+
echo BUILD_TYPE %BUILD_TYPE%
7+
pushd %~dp0
8+
if not exist "%BUILD_TYPE%-msys2" mkdir "%BUILD_TYPE%-msys2"
9+
pushd %BUILD_TYPE%-msys2
10+
cmake -G Ninja -D CMAKE_BUILD_TYPE=%BUILD_TYPE% -D CMAKE_PREFIX_PATH=C:/msys64/ucrt64;C:/msys64/ucrt64/include/qwt-qt6 ..
11+
cmake --build .
12+
popd
13+
popd

build-msys2.pbat

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
def main
2+
include(env-msys2)
3+
set BUILD_TYPE=Release
4+
if /I "%1"=="debug" set BUILD_TYPE=Debug
5+
echo BUILD_TYPE %BUILD_TYPE%
6+
pushd_cd()
7+
mkdir(%BUILD_TYPE%-msys2)
8+
pushd %BUILD_TYPE%-msys2
9+
cmake -G Ninja -D CMAKE_BUILD_TYPE=%BUILD_TYPE% -D CMAKE_PREFIX_PATH=C:/msys64/ucrt64;C:/msys64/ucrt64/include/qwt-qt6 ..
10+
cmake --build .
11+
popd
12+
popd

build.bat

Lines changed: 7 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,13 @@
11
@echo off
22
rem This file is generated from build.pbat, all edits will be lost
3-
set PATH=C:\Program Files\CMake\bin;C:\Program Files\Meson;C:\mingw1120_64\bin;C:\qwt\6.3.0\mingw1120_64\lib;C:\Miniconda3;C:\Miniconda3\Scripts;%USERPROFILE%\Miniconda3;%USERPROFILE%\Miniconda3\Scripts;C:\LLVM-18\bin;%PATH%
3+
set PATH=C:\Program Files\CMake\bin;%LOCALAPPDATA%\Programs\Python\Python311;%LOCALAPPDATA%\Programs\Python\Python311\Scripts;C:\Python311;C:\Python311\Scripts;C:\Program Files\Meson;C:\mingw1120_64\bin;C:\Qt\6.7.1\mingw1120_64\bin;C:\qwt\6.3.0\mingw1120_64\lib;C:\LLVM-18\bin;%PATH%
4+
set BUILD_TYPE=Release
5+
if /I "%1"=="debug" set BUILD_TYPE=Debug
6+
echo BUILD_TYPE %BUILD_TYPE%
47
pushd %~dp0
5-
if not exist debug mkdir debug
6-
if not exist release mkdir release
7-
pushd debug
8-
cmake -G Ninja -D CMAKE_BUILD_TYPE=Debug -D CMAKE_PREFIX_PATH=C:/Qt/6.7.1/mingw1120_64;C:/qwt/6.3.0/mingw1120_64 ..
9-
cmake --build .
10-
popd
11-
pushd release
12-
cmake -G Ninja -D CMAKE_BUILD_TYPE=Release -D CMAKE_PREFIX_PATH=C:/Qt/6.7.1/mingw1120_64;C:/qwt/6.3.0/mingw1120_64 ..
8+
if not exist "%BUILD_TYPE%" mkdir "%BUILD_TYPE%"
9+
pushd %BUILD_TYPE%
10+
cmake -G Ninja -D CMAKE_BUILD_TYPE=%BUILD_TYPE% -D CMAKE_PREFIX_PATH=C:/Qt/6.7.1/mingw1120_64;C:/qwt/6.3.0/mingw1120_64 ..
1311
cmake --build .
1412
popd
1513
popd

build.pbat

Lines changed: 6 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,12 @@
11
def main
22
include(env)
3+
set BUILD_TYPE=Release
4+
if /I "%1"=="debug" set BUILD_TYPE=Debug
5+
echo BUILD_TYPE %BUILD_TYPE%
36
pushd_cd()
4-
mkdir(debug)
5-
mkdir(release)
6-
pushd debug
7-
cmake -G Ninja -D CMAKE_BUILD_TYPE=Debug -D CMAKE_PREFIX_PATH=C:/Qt/6.7.1/mingw1120_64;C:/qwt/6.3.0/mingw1120_64 ..
8-
cmake --build .
9-
popd
10-
pushd release
11-
cmake -G Ninja -D CMAKE_BUILD_TYPE=Release -D CMAKE_PREFIX_PATH=C:/Qt/6.7.1/mingw1120_64;C:/qwt/6.3.0/mingw1120_64 ..
7+
mkdir(%BUILD_TYPE%)
8+
pushd %BUILD_TYPE%
9+
cmake -G Ninja -D CMAKE_BUILD_TYPE=%BUILD_TYPE% -D CMAKE_PREFIX_PATH=C:/Qt/6.7.1/mingw1120_64;C:/qwt/6.3.0/mingw1120_64 ..
1210
cmake --build .
1311
popd
1412
popd

deploy.bat

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
@echo off
2+
rem This file is generated from deploy.pbat, all edits will be lost
3+
set PATH=C:\msys64\ucrt64\bin;C:\Program Files\CMake\bin;%LOCALAPPDATA%\Programs\Python\Python311;%LOCALAPPDATA%\Programs\Python\Python311\Scripts;C:\Python311;C:\Python311\Scripts;C:\Program Files\Meson;C:\Miniconda3;C:\Miniconda3\Scripts;%USERPROFILE%\Miniconda3;%USERPROFILE%\Miniconda3\Scripts;%PATH%
4+
where mugideploy > NUL 2>&1 || pip install mugideploy
5+
where ninja > NUL 2>&1 || pip install ninja
6+
call build-msys2
7+
mugideploy collect --bin Release-msys2\mugi-query.exe --plugins sqldrivers --zip

deploy.pbat

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
github_checkout()
2+
github_setup_msys2(mingw-w64-ucrt-x86_64-gcc mingw-w64-ucrt-x86_64-qt6-base mingw-w64-ucrt-x86_64-qwt-qt6, :m=ucrt64)
3+
include(env-msys2)
4+
use(python, 3.11)
5+
use(conda)
6+
install(mugideploy)
7+
install(ninja)
8+
call build-msys2
9+
mugideploy collect --bin Release-msys2\mugi-query.exe --plugins sqldrivers --zip
10+
github_upload(mugi-query-*-win64.zip, :n=mugi-query)
11+
github-workflow 1

env-msys2.bat

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
@echo off
2+
rem This file is generated from env-msys2.pbat, all edits will be lost
3+
set PATH=C:\msys64\ucrt64\bin;C:\Program Files\CMake\bin;%PATH%

env-msys2.pbat

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# mingw-w64-ucrt-x86_64-qt6-base
2+
# mingw-w64-ucrt-x86_64-qwt-qt6
3+
# gcc qmake
4+
add_path(C:\msys64\ucrt64\bin)
5+
use(cmake)
6+
use(python, 3.11)
7+
use(ninja)

env.bat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
@echo off
22
rem This file is generated from env.pbat, all edits will be lost
3-
set PATH=C:\Program Files\CMake\bin;%LOCALAPPDATA%\Programs\Python\Python38;%LOCALAPPDATA%\Programs\Python\Python38\Scripts;C:\Python38;C:\Python38\Scripts;%LOCALAPPDATA%\Programs\Python\Python39;%LOCALAPPDATA%\Programs\Python\Python39\Scripts;C:\Python39;C:\Python39\Scripts;%LOCALAPPDATA%\Programs\Python\Python310;%LOCALAPPDATA%\Programs\Python\Python310\Scripts;C:\Python310;C:\Python310\Scripts;%LOCALAPPDATA%\Programs\Python\Python311;%LOCALAPPDATA%\Programs\Python\Python311\Scripts;C:\Python311;C:\Python311\Scripts;%LOCALAPPDATA%\Programs\Python\Python312;%LOCALAPPDATA%\Programs\Python\Python312\Scripts;C:\Python312;C:\Python312\Scripts;%LOCALAPPDATA%\Programs\Python\Python313;%LOCALAPPDATA%\Programs\Python\Python313\Scripts;C:\Python313;C:\Python313\Scripts;%LOCALAPPDATA%\Programs\Python\Python314;%LOCALAPPDATA%\Programs\Python\Python314\Scripts;C:\Python314;C:\Python314\Scripts;C:\Program Files\Meson;C:\mingw1120_64\bin;C:\Qt\6.7.1\mingw1120_64\bin;C:\qwt\6.3.0\mingw1120_64\lib;C:\LLVM-18\bin;%PATH%
3+
set PATH=C:\Program Files\CMake\bin;%LOCALAPPDATA%\Programs\Python\Python311;%LOCALAPPDATA%\Programs\Python\Python311\Scripts;C:\Python311;C:\Python311\Scripts;C:\Program Files\Meson;C:\mingw1120_64\bin;C:\Qt\6.7.1\mingw1120_64\bin;C:\qwt\6.3.0\mingw1120_64\lib;C:\LLVM-18\bin;%PATH%

env.pbat

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use(cmake)
2-
use(python)
2+
use(python, 3.11)
33
use(ninja)
44
add_path(C:\mingw1120_64\bin)
55
add_path(C:\Qt\6.7.1\mingw1120_64\bin)

version.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#define VERSION "0.0.1"
2+
#define GIT_COMMIT_HASH "f9abf0fe66f88431f34a0137715b3348d0e7a3e8"

0 commit comments

Comments
 (0)