diff --git a/.github/release-drafter.yml b/.github/release-drafter.yml deleted file mode 100644 index 609c1d8cb3..0000000000 --- a/.github/release-drafter.yml +++ /dev/null @@ -1,29 +0,0 @@ -version-template: 'v21.$MINOR.$PATCH' -name-template: '$RESOLVED_VERSION' -tag-template: '$RESOLVED_VERSION' -categories: - - title: '🚀 Features' - labels: - - 'feature' - - 'enhancement' - - title: '🐛 Bug Fixes' - labels: - - 'fix' - - 'bugfix' - - 'bug' - - title: '🧰 Maintenance' - label: 'chore' -change-template: '- $TITLE @$AUTHOR (#$NUMBER)' -change-title-escapes: '\<*_&' # You can add # and @ to disable mentions, and add ` to disable code blocks. -version-resolver: - minor: - labels: - - 'release' - patch: - labels: - - 'hotfix' - default: patch -template: | - ## Changes - - $CHANGES diff --git a/.github/workflows/release-drafter.yml b/.github/workflows/release-drafter.yml deleted file mode 100644 index 442f6dc41c..0000000000 --- a/.github/workflows/release-drafter.yml +++ /dev/null @@ -1,29 +0,0 @@ -name: Release Drafter - -on: - push: - # branches to consider in the event; optional, defaults to all - branches: - - master - # pull_request event is required only for autolabeler - pull_request: - # Only following types are handled by the action, but one can default to all as well - types: [opened, reopened, synchronize] - -jobs: - update_release_draft: - runs-on: ubuntu-latest - steps: - # (Optional) GitHub Enterprise requires GHE_HOST variable set - #- name: Set GHE_HOST - # run: | - # echo "GHE_HOST=${GITHUB_SERVER_URL##https:\/\/}" >> $GITHUB_ENV - - # Drafts your next Release notes as Pull Requests are merged into "master" - - uses: release-drafter/release-drafter@v5 - # (Optional) specify config name to use, relative to .github/. Default: release-drafter.yml - # with: - # config-name: my-config.yml - # disable-autolabeler: true - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/version-check.sh b/.github/workflows/version-check.sh new file mode 100644 index 0000000000..44215385d8 --- /dev/null +++ b/.github/workflows/version-check.sh @@ -0,0 +1,14 @@ +version=$(grep "version=" linuxgsm.sh | sed -e 's/version//g'| tr -d '="') +modulesversion=$(grep "modulesversion=" lgsm/functions/core_functions.sh | sed -e 's/modulesversion//g'| tr -d '="') + +if [ "${version}" != "${modulesversion}" ]; then + echo "Error! LinuxGSM version mismatch" + echo "Version: ${version}" + echo "Modules Version: ${modulesversion}" + exit 1 +else + echo "Success! LinuxGSM version match" + echo "Version: ${version}" + echo "Modules Version: ${modulesversion}" + exit +fi diff --git a/.github/workflows/version-check.yml b/.github/workflows/version-check.yml new file mode 100644 index 0000000000..903a79268a --- /dev/null +++ b/.github/workflows/version-check.yml @@ -0,0 +1,23 @@ +# This is a basic workflow to help you get started with Actions + +name: Version Check + +# Controls when the action will run. Triggers the workflow on push or pull request +# events but only for the master branch +on: push + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + # This workflow contains a single job called "build" + Version-Check: + # The type of runner that the job will run on + runs-on: ubuntu-latest + + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + # Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it + - uses: actions/checkout@v2 + + # Runs a single command using the runners shell + - name: compare versions + run: chmod +x .github/workflows/version-check.sh; .github/workflows/version-check.sh diff --git a/lgsm/config-default/config-lgsm/sfserver/_default.cfg b/lgsm/config-default/config-lgsm/sfserver/_default.cfg index e27899793a..229eb1f0b4 100644 --- a/lgsm/config-default/config-lgsm/sfserver/_default.cfg +++ b/lgsm/config-default/config-lgsm/sfserver/_default.cfg @@ -15,7 +15,7 @@ beaconport="15000" port="7777" ## Server Parameters | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters -startparameters="FactoryGame -ServerQueryPort=${queryport} -BeaconPort=${beaconport} -GamePort=${port} -log -unattended" +startparameters="FactoryGame -ServerQueryPort=${queryport} -BeaconPort=${beaconport} -Port=${port} -log -unattended" #### LinuxGSM Settings #### diff --git a/lgsm/functions/core_functions.sh b/lgsm/functions/core_functions.sh index 2ecc472789..725cd297b1 100755 --- a/lgsm/functions/core_functions.sh +++ b/lgsm/functions/core_functions.sh @@ -8,7 +8,7 @@ functionselfname="$(basename "$(readlink -f "${BASH_SOURCE[0]}")")" -modulesversion="v21.4.0" +modulesversion="v21.4.1" # Core diff --git a/lgsm/functions/info_game.sh b/lgsm/functions/info_game.sh index 106b1b4ee8..c767fcb78b 100644 --- a/lgsm/functions/info_game.sh +++ b/lgsm/functions/info_game.sh @@ -790,6 +790,14 @@ fn_info_game_kf2(){ defaultmap=${defaultmap:-"NOT SET"} } +fn_info_game_lo(){ + # Parameters + servername=${servername:-"NOT SET"} + port=${port:-"0"} + queryport=${queryport:-"0"} + maxplayers=${slots:-"0"} +} + fn_info_game_mc(){ # Config if [ ! -f "${servercfgfullpath}" ]; then @@ -803,7 +811,7 @@ fn_info_game_mc(){ gamemode="${unavailable}" gameworld="${unavailable}" else - servername=$(grep "motd" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/motd//g' | tr -d '=\";,:' | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//') + servername=$(grep "motd" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/motd//g' | tr -d '=\";,:' | sed 's/\\u00A70//g;s/\\u00A71//g;s/\\u00A72//g;s/\\u00A73//g;s/\\u00A74//g;s/\\u00A75//g;s/\\u00A76//g;s/\\u00A77//g;s/\\u00A78//g;s/\\u00A79//g;s/\\u00A7a//g;s/\\u00A7b//g;s/\\u00A7c//g;s/\\u00A7d//g;s/\\u00A7e//g;s/\\u00A7f//g;s/\\u00A7l//g;s/\\u00A7o//g;s/\\u00A7n//g;s/\\u00A7m//g;s/\\u00A7k//g' | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//') rconpassword=$(grep "rcon.password" "${servercfgfullpath}" | sed -e 's/^[ \t]*//g' -e '/^#/d' -e 's/rcon.password//g' | tr -d '=\";,:' | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//') rconport=$(grep "rcon.port" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]') maxplayers=$(grep "max-players" "${servercfgfullpath}" | grep -v "#" | tr -cd '[:digit:]') @@ -1550,6 +1558,14 @@ fn_info_game_sdtd(){ fi } +fn_info_game_sf(){ + # Parameters + servername=${selfname:-"NOT SET"} + port=${port:-"0"} + queryport=${queryport:-"0"} + beaconport=${beaconport:-"0"} +} + fn_info_game_sof2(){ # Config if [ ! -f "${servercfgfullpath}" ]; then @@ -1927,7 +1943,8 @@ fn_info_game_unt(){ # Parameters servername=${selfname:-"NOT SET"} port=${port:-"0"} - queryport=$((port+1)) + queryport=${port} + steamport=$((port+1)) } fn_info_game_ut(){ @@ -2230,6 +2247,8 @@ elif [ "${shortname}" == "kf" ]; then fn_info_game_kf elif [ "${shortname}" == "kf2" ]; then fn_info_game_kf2 +elif [ "${shortname}" == "lo" ]; then + fn_info_game_lo elif [ "${shortname}" == "mc" ]||[ "${shortname}" == "pmc" ]; then fn_info_game_mc elif [ "${shortname}" == "mcb" ]; then @@ -2280,6 +2299,8 @@ elif [ "${shortname}" == "scpsl" ]||[ "${shortname}" == "scpslsm" ]; then fn_info_game_scpsl elif [ "${shortname}" == "sdtd" ]; then fn_info_game_sdtd +elif [ "${shortname}" == "sf" ]; then + fn_info_game_sf elif [ "${shortname}" == "sof2" ]; then fn_info_game_sof2 elif [ "${shortname}" == "sol" ]; then diff --git a/lgsm/functions/info_messages.sh b/lgsm/functions/info_messages.sh index 10925c7e9d..0337f2d92e 100755 --- a/lgsm/functions/info_messages.sh +++ b/lgsm/functions/info_messages.sh @@ -800,7 +800,7 @@ fn_info_message_arma3(){ fn_port "header" fn_port "Game" port udp fn_port "Voice" voiceport udp - fn_port "Query Steam" queryport udp + fn_port "Query" queryport udp fn_port "Steam Master" steammasterport udp fn_port "Voice (unused)" voiceunusedport udp fn_port "BattleEye" battleeyeport udp @@ -1517,6 +1517,7 @@ fn_info_message_unt(){ fn_port "header" fn_port "Game" port udp fn_port "Query" queryport udp + fn_port "Steam" steamport udp } | column -s $'\t' -t } diff --git a/lgsm/functions/query_gsquery.py b/lgsm/functions/query_gsquery.py index 6c21b1a896..4d6b018287 100755 --- a/lgsm/functions/query_gsquery.py +++ b/lgsm/functions/query_gsquery.py @@ -59,10 +59,12 @@ def __init__(self, options, arguments): self.response = None self.sanity_checks() + @staticmethod def fatal_error(self, error_message, error_code=1): sys.stderr.write('ERROR: ' + str(error_message) + '\n') sys.exit(error_code) + @staticmethod def exit_success(self, success_message=''): sys.stdout.write('OK: ' + str(success_message) + '\n') sys.exit(0) @@ -140,6 +142,5 @@ def sanity_checks(self): help='Display debugging output.' ) options, arguments = parser.parse_args() - # server = gsquery(options, arguments) server.responding() diff --git a/linuxgsm.sh b/linuxgsm.sh index 4cd9d45325..1eff0d00f3 100755 --- a/linuxgsm.sh +++ b/linuxgsm.sh @@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then set -x fi -version="v21.4.0" +version="v21.4.1" shortname="core" gameservername="core" commandname="CORE" diff --git a/tests/tests_fctrserver.sh b/tests/tests_fctrserver.sh index 5d88e30262..138864098d 100644 --- a/tests/tests_fctrserver.sh +++ b/tests/tests_fctrserver.sh @@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then set -x fi -version="v21.4.0" +version="v21.4.1" shortname="fctr" gameservername="fctrserver" commandname="CORE" diff --git a/tests/tests_jc2server.sh b/tests/tests_jc2server.sh index 5512d608e6..86637f5b25 100644 --- a/tests/tests_jc2server.sh +++ b/tests/tests_jc2server.sh @@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then set -x fi -version="v21.4.0" +version="v21.4.1" shortname="jc2" gameservername="jc2server" commandname="CORE" diff --git a/tests/tests_mcserver.sh b/tests/tests_mcserver.sh index b027e9db33..447b8b9e3a 100644 --- a/tests/tests_mcserver.sh +++ b/tests/tests_mcserver.sh @@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then set -x fi -version="v21.4.0" +version="v21.4.1" shortname="mc" gameservername="mcserver" commandname="CORE" diff --git a/tests/tests_ts3server.sh b/tests/tests_ts3server.sh index 418ce00aef..3c160f009a 100644 --- a/tests/tests_ts3server.sh +++ b/tests/tests_ts3server.sh @@ -20,7 +20,7 @@ if [ -f ".dev-debug" ]; then set -x fi -version="v21.4.0" +version="v21.4.1" shortname="ts3" gameservername="ts3server" commandname="CORE"