lgsm local mirror
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

57 lines
2.0 KiB

name: Details Check
# This action will check that LinuxGSM is picking up game server config and parameter variables.
on:
workflow_dispatch:
push:
jobs:
create-matrix:
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Generate matrix with generate-matrix.sh
run: chmod +x .github/workflows/detals-check-generate-matrix.sh; .github/workflows/detals-check-generate-matrix.sh
- id: set-matrix
run: |
shortnamearray=$(cat shortnamearray.json)
echo "${shortnamearray}"
echo -n "matrix=${shortnamearray}" >> $GITHUB_OUTPUT
details-check:
needs: create-matrix
runs-on: ubuntu-latest
strategy:
matrix: ${{ fromJSON(needs.create-matrix.outputs.matrix) }}
steps:
# Runs a single command using the runners shell
- name: Download linuxgsm.sh
run: wget https://raw.githubusercontent.com/GameServerManagers/LinuxGSM/feature/info_game-refactor/linuxgsm.sh; chmod +x linuxgsm.sh
- name: Grab server
run: LGSM_GITHUBBRANCH="feature/info_game-refactor" ./linuxgsm.sh ${{ matrix.shortname }}server
- name: Enable developer mode
run: LGSM_GITHUBBRANCH="feature/info_game-refactor" ./${{ matrix.shortname }}server developer
- id: sets-a-secret
name: Generate servercfgname
run: |
servercfg=$(sed -n "/^\<servercfgdefault\>/ { s/.*= *\"\?\([^\"']*\)\"\?/\1/p;q }" lgsm/config-lgsm/${{ matrix.shortname }}server/_default.cfg)
echo "servercfgname=$servercfg" >> "$GITHUB_OUTPUT"
- name: Download config
run: |
curl -f -o config "https://raw.githubusercontent.com/GameServerManagers/Game-Server-Configs/rename/${{ matrix.shortname }}/${{ steps.sets-a-secret.outputs.servercfgname }}"
- name: Display config
run: cat config
- name: Check details
run: LGSM_GITHUBBRANCH="feature/info_game-refactor" ./${{ matrix.shortname }}server detect-details