mirror of
https://github.com/sp-tarkov/build.git
synced 2025-02-13 09:50:45 -05:00
Add target_tag and build_type outputs to build.yaml
This commit is contained in:
parent
2c73aedbdf
commit
a313bb8698
@ -11,6 +11,7 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
outputs:
|
outputs:
|
||||||
proceed: ${{ steps.check.outputs.proceed }}
|
proceed: ${{ steps.check.outputs.proceed }}
|
||||||
|
target_tag: ${{ steps.output-target-tag.outputs.target_tag }}
|
||||||
steps:
|
steps:
|
||||||
- name: Check Tag Exists in All Repositories
|
- name: Check Tag Exists in All Repositories
|
||||||
id: check
|
id: check
|
||||||
@ -30,22 +31,25 @@ jobs:
|
|||||||
echo "::set-output name=proceed::$PROCEED"
|
echo "::set-output name=proceed::$PROCEED"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
||||||
|
- name: Output Target Tag
|
||||||
|
id: output-target-tag
|
||||||
|
run: |
|
||||||
|
echo "target_tag=${TAG}" >> $GITHUB_ENV
|
||||||
|
|
||||||
- name: Tag Not Found
|
- name: Tag Not Found
|
||||||
if: steps.check.outputs.proceed == 'false'
|
if: steps.check.outputs.proceed == 'false'
|
||||||
run: |
|
run: |
|
||||||
echo "Tag not found in one or more repositories, halting workflow."
|
echo "Tag not found in one or more repositories, halting workflow."
|
||||||
exit 1
|
exit 1
|
||||||
|
|
||||||
- name: Output Target Tag
|
|
||||||
if: steps.check.outputs.proceed == 'true'
|
|
||||||
run: echo "target_tag=${TAG}" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
build-server:
|
build-server:
|
||||||
needs: check-tag-exists
|
needs: check-tag-exists
|
||||||
if: needs.check-tag-exists.outputs.proceed == 'true'
|
if: needs.check-tag-exists.outputs.proceed == 'true'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container:
|
container:
|
||||||
image: refringe/spt-build-server:0.0.6
|
image: refringe/spt-build-server:0.0.6
|
||||||
|
outputs:
|
||||||
|
build_type: ${{ steps.build-type.outputs.build_type }}
|
||||||
steps:
|
steps:
|
||||||
- name: Clone
|
- name: Clone
|
||||||
run: |
|
run: |
|
||||||
@ -94,8 +98,8 @@ jobs:
|
|||||||
elif [[ "$TAGS" =~ ^(v?\d+\.\d+\.\d+)$ ]]; then
|
elif [[ "$TAGS" =~ ^(v?\d+\.\d+\.\d+)$ ]]; then
|
||||||
BUILD_TYPE="release"
|
BUILD_TYPE="release"
|
||||||
fi
|
fi
|
||||||
echo "Build type: $BUILD_TYPE"
|
echo "build_type=${BUILD_TYPE}" >> $GITHUB_ENV
|
||||||
echo "::set-output name=build_type::$BUILD_TYPE"
|
echo "::set-output name=build_type::${BUILD_TYPE}"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
||||||
- name: Build Cache
|
- name: Build Cache
|
||||||
@ -133,15 +137,14 @@ jobs:
|
|||||||
path: /workspace/refringe/Build/server/project/build/
|
path: /workspace/refringe/Build/server/project/build/
|
||||||
overwrite: true
|
overwrite: true
|
||||||
|
|
||||||
- name: Output Build Type
|
|
||||||
run: echo "build_type=${BUILD_TYPE}" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
build-modules:
|
build-modules:
|
||||||
needs: check-tag-exists
|
needs: check-tag-exists
|
||||||
if: needs.check-tag-exists.outputs.proceed == 'true'
|
if: needs.check-tag-exists.outputs.proceed == 'true'
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
container:
|
container:
|
||||||
image: refringe/spt-build-dotnet:0.0.6
|
image: refringe/spt-build-dotnet:0.0.6
|
||||||
|
outputs:
|
||||||
|
build_type: ${{ steps.extract-client-version.outputs.client_version }}
|
||||||
steps:
|
steps:
|
||||||
- name: Clone
|
- name: Clone
|
||||||
run: |
|
run: |
|
||||||
@ -168,6 +171,7 @@ jobs:
|
|||||||
FULL_VERSION=$(jq -r '.compatibleTarkovVersion' core.json)
|
FULL_VERSION=$(jq -r '.compatibleTarkovVersion' core.json)
|
||||||
CLIENT_VERSION=${FULL_VERSION##*.}
|
CLIENT_VERSION=${FULL_VERSION##*.}
|
||||||
echo "Extracted Client Version: $CLIENT_VERSION"
|
echo "Extracted Client Version: $CLIENT_VERSION"
|
||||||
|
echo "client_version=${CLIENT_VERSION}" >> $GITHUB_ENV
|
||||||
echo "::set-output name=client_version::$CLIENT_VERSION"
|
echo "::set-output name=client_version::$CLIENT_VERSION"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
||||||
@ -220,9 +224,6 @@ jobs:
|
|||||||
path: /workspace/refringe/Build/modules/project/Build
|
path: /workspace/refringe/Build/modules/project/Build
|
||||||
overwrite: true
|
overwrite: true
|
||||||
|
|
||||||
- name: Output Client Version
|
|
||||||
run: echo "client_version=${CLIENT_VERSION}" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
build-launcher:
|
build-launcher:
|
||||||
needs: check-tag-exists
|
needs: check-tag-exists
|
||||||
if: needs.check-tag-exists.outputs.proceed == 'true'
|
if: needs.check-tag-exists.outputs.proceed == 'true'
|
||||||
@ -304,7 +305,7 @@ jobs:
|
|||||||
- name: Upload Release
|
- name: Upload Release
|
||||||
uses: Difegue/action-megacmd@master
|
uses: Difegue/action-megacmd@master
|
||||||
with:
|
with:
|
||||||
args: put -c "/workspace/refringe/Build/${RELEASE_FILENAME}" "/spt-release/${RELEASE_FILENAME}"
|
args: put -c /workspace/refringe/Build/"${RELEASE_FILENAME}" /spt-release/"${RELEASE_FILENAME}"
|
||||||
env:
|
env:
|
||||||
USERNAME: ${{ secrets.MEGA_EMAIL }}
|
USERNAME: ${{ secrets.MEGA_EMAIL }}
|
||||||
PASSWORD: ${{ secrets.MEGA_PASSWORD }}
|
PASSWORD: ${{ secrets.MEGA_PASSWORD }}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user