diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e7d6f7959..5bdc01960 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -16,7 +16,7 @@ jobs: RoboHelp: name: "RoboHelp" - runs-on: windows-2019 + runs-on: windows-2022 env: LANGUAGE: ${{ vars.LANGUAGE }} steps: @@ -31,9 +31,11 @@ jobs: uses: actions/checkout@v4 with: path: Manual - token: ${{ secrets.GH_TOKEN }} + token: ${{ secrets.GH_TOKEN }} - name: Beta Builds if: github.event.pull_request.base.ref == 'develop' || github.event_name == 'workflow_dispatch' + env: + BUILDBETA: '1' run: build_robohelp_gh.bat %GITHUB_WORKSPACE%\output shell: cmd working-directory: Manual diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index abce34656..ddb8261ef 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -32,6 +32,8 @@ jobs: token: ${{ secrets.GH_TOKEN }} - name: Monthly Builds if: github.event.pull_request.base.ref == 'main' || github.event_name == 'workflow_dispatch' + env: + BUILDBETA: '0' run: build_robohelp_gh.bat %GITHUB_WORKSPACE%\output shell: cmd working-directory: Manual diff --git a/build_robohelp_gh.bat b/build_robohelp_gh.bat index 768ee9446..4f4716379 100644 --- a/build_robohelp_gh.bat +++ b/build_robohelp_gh.bat @@ -1,4 +1,5 @@ -@echo off +@echo on +setlocal enabledelayedexpansion rem experimental build if "%WORKSPACE%" == "" set WORKSPACE=%GITHUB_WORKSPACE% if "%BUILD_NUMBER%" == "" set BUILD_NUMBER=999 @@ -9,7 +10,7 @@ if "%JOB_NAME%" == "" set JOB_NAME=GMS2_Manual set BUILDTYPE=release set BUILDPLATFORM="Any CPU" set BUILDCLEAN=1 -set BUILDBETA=0 +set BUILDBETA=%BUILDBETA% set S3_BUCKET=%S3_BUCKET% set ZIP_FILE=%ZIP_FILE% @@ -17,7 +18,11 @@ set basedir=%~dp0 :check_options if %LANGUAGE%==EN ( - set robohelpPreset="GMS2 Manual Responsive HTML5 BETA" + if "%BUILDBETA%"=="1" ( + set robohelpPreset="GMS2 Manual Responsive HTML5 BETA" + ) else ( + set robohelpPreset="GMS2 Manual Responsive HTML5" + ) goto finish_options ) else if %LANGUAGE%==ES ( set robohelpPreset="GMS2 Manual Spanish" @@ -87,7 +92,21 @@ rem output help tags files rem append css fix to layout.css type "%basedir%SupportFiles\layout_fix_append.css" >> "%DESTDIR%\RoboHelp\template\Charcoal_Grey\layout.css" -@REM rem ************************************************** ZIP up the output pushd %DESTDIR%\RoboHelp +if /i %robohelpPreset%=="GMS2 Manual Responsive HTML5 BETA" ( + echo Branch is develop - Choose BETA + aws s3 cp helpdocs_keywords.json s3://manual-json-files/Beta/helpdocs_keywords.json + aws s3 cp helpdocs_tags.json s3://manual-json-files/Beta/helpdocs_tags.json +) else if /i %robohelpPreset%=="GMS2 Manual Responsive HTML5" ( + echo Branch is Main - Choose Green + aws s3 cp helpdocs_keywords.json s3://manual-json-files/Green/helpdocs_keywords.json + aws s3 cp helpdocs_tags.json s3://manual-json-files/Green/helpdocs_tags.json +) else ( + echo Branch is not develop or main - Choose LTS + aws s3 cp helpdocs_keywords.json s3://manual-json-files/LTS/helpdocs_keywords.json + aws s3 cp helpdocs_tags.json s3://manual-json-files/LTS/helpdocs_tags.json +) + +@REM rem ************************************************** ZIP up the output 7z a YoYoStudioRoboHelp.zip . -r popd diff --git a/develop b/develop new file mode 100644 index 000000000..b405e31ad --- /dev/null +++ b/develop @@ -0,0 +1,3 @@ +branch_name=develop +branch_name=develop +branch_name=develop