Skip to content

Commit

Permalink
Test CI
Browse files Browse the repository at this point in the history
  • Loading branch information
muczc1wek committed Oct 2, 2024
1 parent b694bf1 commit e2b98f2
Show file tree
Hide file tree
Showing 9 changed files with 86 additions and 3 deletions.
8 changes: 7 additions & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,4 +89,10 @@ jobs:
uses: actions/upload-artifact@v4
with:
name: ${{ inputs.upload-artifact-dll }}
path: out/install/${{ inputs.cmake-preset }}/bin/*.dll
path: out/install/${{ inputs.cmake-preset }}/bin/*.dll
- name: Archive VDF
uses: actions/upload-artifact@v4
if: ${{ inputs.upload-artifact-vdf != 'false' }}
with:
name: ${{ inputs.upload-artifact-vdf }}
path: out/install/${{ inputs.cmake-preset }}/*.vdf
3 changes: 2 additions & 1 deletion .github/workflows/on-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,5 @@ jobs:
uses: ./.github/workflows/build.yml
with:
cmake-preset: x86-release
upload-artifact-dll: release-dll
upload-artifact-dll: release-dll
upload-artifact-vdf: release-vdf
9 changes: 8 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,11 @@ jobs:
with:
name: release-dll
path: out/install/x86-release/bin/
- name: Download Release VDF
uses: actions/download-artifact@v4
with:
name: release-vdf
path: out/install/x86-release/
- name: Prepare Release Files
id: prepare-release
shell: powershell
Expand All @@ -35,6 +40,7 @@ jobs:
run: |
$tag = $env:GITHUB_REF -replace '^refs/tags/', ''
Compress-Archive out/install/x86-release/bin/* zMultilogue-${tag}.zip
Copy-Item out/install/x86-release/zMultilogue.vdf zMultilogue-${tag}.vdf
$prerelease = if (-not ($tag -match '^v?(\d+\.\d+\.\d+)$')) { 'true' } else { 'false' }
echo "prerelease=${prerelease}" >> $env:GITHUB_OUTPUT
- name: Release
Expand All @@ -46,4 +52,5 @@ jobs:
draft: true
prerelease: ${{ steps.prepare-release.outputs.prerelease }}
files: |
zMultilogue-*.zip
zMultilogue-*.zip
zMultilogue-*.vdf
15 changes: 15 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -38,3 +38,18 @@ target_compile_options(zMultilogue PRIVATE
/external:I ${CMAKE_BINARY_DIR}/_deps
)


install(FILES $<TARGET_RUNTIME_DLLS:${CMAKE_PROJECT_NAME}> "${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}.dll" TYPE BIN)

configure_file("${CMAKE_SOURCE_DIR}/vdf/script.vs.in" "${CMAKE_BINARY_DIR}/script.vs")

install(FILES $<TARGET_RUNTIME_DLLS:${CMAKE_PROJECT_NAME}> "${CMAKE_BINARY_DIR}/${CMAKE_PROJECT_NAME}.dll" TYPE BIN)
install(FILES "${CMAKE_BINARY_DIR}/script.vs" DESTINATION "${CMAKE_INSTALL_PREFIX}")
install(SCRIPT "${CMAKE_SOURCE_DIR}/vdf/vdf.cmake")
install(CODE "execute_process(COMMAND ${CMAKE_SOURCE_DIR}/vdf/GothicVDFS.exe /B \"${CMAKE_INSTALL_PREFIX}/script.vs\" WORKING_DIRECTORY \"${CMAKE_INSTALL_PREFIX}\")")

string(REPLACE "build" "install" INSTALL_DIR "${CMAKE_BINARY_DIR}")
add_custom_target(${CMAKE_PROJECT_NAME}_vdf ALL
COMMAND ${CMAKE_COMMAND} --install ${CMAKE_BINARY_DIR} --prefix ${INSTALL_DIR}
DEPENDS ${CMAKE_PROJECT_NAME}
COMMENT "Run install to build VDF")
Binary file added vdf/GothicVDFS.exe
Binary file not shown.
43 changes: 43 additions & 0 deletions vdf/License.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@

GothicVDFS 2.6 (mod)
===================

What for...
�����������
This tool is intended to view, extract, and build
Virtual Disk File System (VDFS) volumes for Gothic II.

Usage
�����
This simple program is self-explanatory - just use it.

Legal Stuff
�����������
Copyright (c) 2001-2003, Nico Bendlin
All rights reserved.

Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.
* Neither the name of the copyright holder nor the names of its
contributors may be used to endorse or promote products derived from this
software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.

Note: VDFS is Copyright (c) 1994-2002, Peter Sabath / TRIACOM Software GmbH
Binary file not shown.
9 changes: 9 additions & 0 deletions vdf/script.vs.in
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[BEGINVDF]
Comment=zScriptsExtender_NH v${CMAKE_PROJECT_VERSION}%%Nhttps://github.com/Silver-Ore-Team/zScriptsExtender_NH%%N2023 Silver Ore Team
BaseDir=vdf
VDFName=zScriptsExtender_NH.vdf
[FILES]
_work\Data\Meshes
System\Autorun\*.dll
System\*.dll
[ENDVDF]
2 changes: 2 additions & 0 deletions vdf/vdf.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
file(MAKE_DIRECTORY "${CMAKE_INSTALL_PREFIX}/vdf/System/Autorun")
file(COPY "${CMAKE_INSTALL_PREFIX}/bin/zMultilogue.dll" DESTINATION "${CMAKE_INSTALL_PREFIX}/vdf/System/Autorun")

0 comments on commit e2b98f2

Please sign in to comment.