Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the release tag name to both the title screen and the artifact file names. #1854

Merged
merged 5 commits into from
Jan 6, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 9 additions & 7 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ jobs:
installerCommands1: choco install openssl --version=3.3.2 --force -y --install-arguments="'/DIR=C:/openSsl/'"
installerCommands2: ''
source_asset: 'Commander_Wars.zip'
asset_name: 'Commander_Wars_Win10_x64.zip'
asset_name: 'Commander_Wars-Win10_x64-${{github.ref_name}}.zip'
cmakeOptions: '"-DCMAKE_GENERATOR:STRING=MinGW Makefiles" -DOPENSSL_LIB_PATH="C:/openSsl/bin" -DOPENSSL_INCLUDE_DIR="C:/openSsl/include" -DOPENSSL_USE_STATIC_LIBS="ON" -DPRECOMPILEDOPENSSL="ON" "-DCMAKE_C_COMPILER:FILEPATH=D:/a/Commander_Wars/Commander_Wars/qt/Qt/Tools/mingw1310_64/bin/gcc.exe" "-DCMAKE_CXX_COMPILER:FILEPATH=D:/a/Commander_Wars/Commander_Wars/qt/Qt/Tools/mingw1310_64/bin/g++.exe"'
- buildTarget: windows-server
os: windows-latest
Expand All @@ -56,7 +56,7 @@ jobs:
installerCommands1: choco install openssl --version=3.3.2 --force -y --install-arguments="'/DIR=C:/openSsl/'"
installerCommands2: ''
source_asset: 'Commander_Wars.zip'
asset_name: 'Commander_Wars_Win10_x64_Server.zip'
asset_name: 'Commander_Wars_Dedicated_Server-Win10_x64-${{github.ref_name}}.zip'
cmakeOptions: '"-DCMAKE_GENERATOR:STRING=MinGW Makefiles" -DOPENSSL_LIB_PATH="C:/openSsl/bin" -DOPENSSL_INCLUDE_DIR="C:/openSsl/include" -DOPENSSL_USE_STATIC_LIBS="ON" -DPRECOMPILEDOPENSSL="ON" -DGRAPHICSUPPORT=OFF -DAUDIOSUPPORT=OFF -DUPDATESUPPORT=OFF "-DCMAKE_C_COMPILER:FILEPATH=D:/a/Commander_Wars/Commander_Wars/qt/Qt/Tools/mingw1310_64/bin/gcc.exe" "-DCMAKE_CXX_COMPILER:FILEPATH=D:/a/Commander_Wars/Commander_Wars/qt/Qt/Tools/mingw1310_64/bin/g++.exe"'
- buildTarget: ubuntu-desktop
os: ubuntu-latest
Expand All @@ -67,7 +67,7 @@ jobs:
installerCommands1: 'sudo apt-get update'
installerCommands2: 'sudo apt-get install libxcb-cursor0 libfuse2 gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-libav gstreamer1.0-tools gstreamer1.0-x gstreamer1.0-alsa gstreamer1.0-gl gstreamer1.0-gtk3 gstreamer1.0-qt5 gstreamer1.0-pulseaudio'
source_asset: 'Commander_Wars-x86_64.AppImage'
asset_name: 'Commander_Wars-Linux.AppImage'
asset_name: 'Commander_Wars-Linux_x64-${{github.ref_name}}.AppImage'
cmakeOptions: ' -DOPENSSL_USE_STATIC_LIBS=FALSE'
serverFlag: ''
linuxFlag: 'linux'
Expand All @@ -80,7 +80,7 @@ jobs:
installerCommands1: 'sudo apt-get update'
installerCommands2: 'sudo apt-get install libxcb-cursor0 libfuse2 gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-libav gstreamer1.0-tools gstreamer1.0-x gstreamer1.0-alsa gstreamer1.0-gl gstreamer1.0-gtk3 gstreamer1.0-qt5 gstreamer1.0-pulseaudio'
source_asset: 'Commander_Wars_Dedicated_Server-x86_64.AppImage'
asset_name: 'Commander_Wars-Linux-Server.AppImage'
asset_name: 'Commander_Wars_Dedicated_Server-Linux_x64-${{github.ref_name}}.AppImage'
cmakeOptions: '-DGRAPHICSUPPORT=OFF -DAUDIOSUPPORT=OFF -DUPDATESUPPORT=OFF -DOPENSSL_USE_STATIC_LIBS=FALSE'
serverFlag: '-server'
linuxFlag: 'linux'
Expand All @@ -93,7 +93,7 @@ jobs:
installerCommands1: ''
installerCommands2: ''
source_asset: 'Commander_Wars.zip'
asset_name: 'Commander_Wars_macOS.zip'
asset_name: 'Commander_Wars-macOS-${{github.ref_name}}.zip'
cmakeOptions: '-DOPENSSL_ROOT_DIR=/usr/local/opt/openssl'
- buildTarget: android-armv7
os: windows-latest
Expand All @@ -108,7 +108,7 @@ jobs:
installerCommands1: 'choco install ninja'
installerCommands2: ''
source_asset: 'android-build/build/outputs/apk/release/android-build-release-signed.apk'
asset_name: 'Commander_Wars_armeabi-v7a.apk'
asset_name: 'Commander_Wars-Android_armeabi_v7a-${{github.ref_name}}.apk'
cmakeOptions: ''
openSslabiPath: 'android_openssl/ssl_3/armeabi-v7a'
- buildTarget: android-arm64_v8a
Expand All @@ -124,7 +124,7 @@ jobs:
installerCommands1: 'choco install ninja'
installerCommands2: ''
source_asset: 'android-build/build/outputs/apk/release/android-build-release-signed.apk'
asset_name: 'Commander_Wars_arm64-v8a.apk'
asset_name: 'Commander_Wars-Android_arm64_v8a-${{github.ref_name}}.apk'
cmakeOptions: ''
openSslabiPath: 'android_openssl/ssl_3/arm64-v8a'

Expand Down Expand Up @@ -191,6 +191,7 @@ jobs:
-DQt6_DIR=${{github.workspace}}/qt/Qt/${{env.QT_Version}}/${{matrix.qtPath}}/lib/cmake/Qt6/ \
-DUPDATESUPPORT=ON \
-DCOW_BUILD_TAG="${{github.ref}}" \
-DCOW_BUILD_NAME="${{github.ref_name}}" \
-DCOW_UPDATETARGET="${{matrix.asset_name}}" \
-DCOW_INSTALL_DIR="Commander_Wars_Release" \
${{matrix.cmakeOptions}}
Expand Down Expand Up @@ -262,6 +263,7 @@ jobs:
-DQt6_DIR=${{github.workspace}}/qt/Qt/${{env.QT_Version}}/${{matrix.qtPath}}/lib/cmake/Qt6/ \
-DUPDATESUPPORT=OFF \
-DCOW_BUILD_TAG="${{github.ref}}" \
-DCOW_BUILD_NAME="${{github.ref_name}}" \
-DCOW_UPDATETARGET="${{matrix.asset_name}}" \
-DCOW_INSTALL_DIR="Commander_Wars_Release" \
${{matrix.cmakeOptions}}
Expand Down
3 changes: 2 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,8 @@ add_definitions(
-DVERSION_REVISION=0
-DVERSION_SUFFIX="main"
-DCOW_BUILD_TAG="${COW_BUILD_TAG}"
)
-DCOW_BUILD_NAME="${COW_BUILD_NAME}"
)

set(COW_ANDROID_VERSION_NAME "0.38.0-main")
set(COW_ANDROID_VERSION_CODE "61")
Expand Down
9 changes: 7 additions & 2 deletions menue/mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -94,9 +94,14 @@ Mainwindow::Mainwindow(const QString & initialView)
style.hAlign = oxygine::TextStyle::HALIGN_LEFT;
style.multiline = false;
style.color = Qt::black;
spLabel pTextfield = MemoryManagement::create<Label>(300);
spLabel pTextfield = MemoryManagement::create<Label>(1000);
pTextfield->setStyle(style);
pTextfield->setHtmlText("Version: " + GameVersion().toString());
QString versionString = "Version: " + GameVersion().toString();
QString buildTag = COW_BUILD_NAME;
if (!buildTag.isEmpty()) {
versionString += " (" + buildTag + ")";
}
pTextfield->setHtmlText(versionString);
pTextfield->setPosition(oxygine::Stage::getStage()->getWidth() - 10 - pTextfield->getTextRect().width(), oxygine::Stage::getStage()->getHeight() - 10 - pTextfield->getTextRect().height());
pTextfield->addClickListener([this](oxygine::Event*)
{
Expand Down
Loading