Commit 1e43ef9d authored by nanahira's avatar nanahira

Merge branch 'master' of github.com:IceYGO/windbot

parents 9757fd85 d78f6224
name: Automated Test Build
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
jobs:
build:
runs-on: windows-2019
env:
Solution_Name: WindBot.sln
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup MSBuild.exe
uses: microsoft/setup-msbuild@v1
- name: Build!
run: msbuild $env:Solution_Name /t:Build /p:Configuration=Release
- name: Pack
run: |
mkdir dist
xcopy /e /y bin\Release dist\WindBot\
xcopy /y BotWrapper\bin\Release\bot.conf dist\
xcopy /y BotWrapper\bin\Release\bot.exe dist\
cd dist
7z a WindBot.7z *
cd ..
- name: Upload build artifacts
uses: actions/upload-artifact@v3
with:
path: dist\WindBot.7z
- name: GitHub Release
if: github.event_name == 'push'
uses: marvinpinto/action-automatic-releases@latest
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: "latest"
prerelease: true
title: "Development Build"
files: |
dist/WindBot.7z
...@@ -52,6 +52,9 @@ namespace WindBot ...@@ -52,6 +52,9 @@ namespace WindBot
if (!File.Exists(absolutePath)) if (!File.Exists(absolutePath))
// In case windbot is placed in a folder under ygopro folder // In case windbot is placed in a folder under ygopro folder
absolutePath = Path.GetFullPath("../" + databasePath); absolutePath = Path.GetFullPath("../" + databasePath);
if (!File.Exists(absolutePath))
// In case windbot is placed in a folder under ygopro2 folder
absolutePath = Path.GetFullPath("../cdb/" + databasePath);
if (!File.Exists(absolutePath)) if (!File.Exists(absolutePath))
{ {
Logger.WriteErrorLine("Can't find cards database file."); Logger.WriteErrorLine("Can't find cards database file.");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment