Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/Huz2e/massmeta
Browse files Browse the repository at this point in the history
  • Loading branch information
Huz2e committed Feb 2, 2025
2 parents d62385a + 97c009a commit 5c977db
Show file tree
Hide file tree
Showing 1,350 changed files with 44,165 additions and 25,853 deletions.
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,4 @@

# TGUI MAINTAINERS

/tgui/packages/tgui/interfaces/Modpacks.tsx @Huz2e
/tgui/packages/tgui/interfaces/Modpacks.tsx @Huz2e
51 changes: 51 additions & 0 deletions .github/actions/restore_or_install_byond/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# This is a reusable workflow to restore BYOND from a cache, or to install it otherwise.
name: Restore or Install BYOND
description: Attempts to restore a specified BYOND version from cache; if it can't, it installs it.

inputs:
major:
description: "The major BYOND version to install. Defaults to the BYOND_MAJOR specified in `dependencies.sh`."
required: false
type: string
minor:
description: "The minor BYOND version to install. Defaults to the BYOND_MINOR specified in `dependencies.sh`."
required: false
type: string

runs:
using: composite
steps:
- name: Configure BYOND version from inputs
if: ${{ inputs.major }}
shell: bash
run: |
echo "BYOND_MAJOR=${{ inputs.major }}" >> $GITHUB_ENV
echo "BYOND_MINOR=${{ inputs.minor }}" >> $GITHUB_ENV
- name: Configure BYOND version from dependencies.sh
if: ${{ !inputs.major }}
shell: bash
run: |
source dependencies.sh
echo "BYOND_MAJOR=$BYOND_MAJOR" >> $GITHUB_ENV
echo "BYOND_MINOR=$BYOND_MINOR" >> $GITHUB_ENV
# The use of `actions/cache/restore` and `actions/cache/save` here is deliberate, as we want to
# save the BYOND install to a cache as early as possible. If we used just `actions/cache`, it
# would only attempt to save the cache at the end of a job. This ensures that if a workflow run
# is cancelled, we already have a cache to restore from.
- name: Restore BYOND cache
id: restore_byond_cache
uses: actions/cache/restore@v4
with:
path: ~/BYOND
key: ${{ runner.os }}-byond-${{ env.BYOND_MAJOR }}-${{ env.BYOND_MINOR }}
- name: Install BYOND
if: ${{ !steps.restore_byond_cache.outputs.cache-hit }}
shell: bash
run: bash tools/ci/install_byond.sh
- name: Save BYOND cache
if: ${{ !steps.restore_byond_cache.outputs.cache-hit }}
uses: actions/cache/save@v4
with:
path: ~/BYOND
key: ${{ steps.restore_byond_cache.outputs.cache-primary-key }}
2 changes: 1 addition & 1 deletion .github/alternate_byond_versions.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
# 500.1337: runtimestation
# 516.1638: runtimestation;516
# Lowest supported version
515.1627: runtimestation
515.1642: runtimestation
# Beta version
516.1648: runtimestation;516
8 changes: 2 additions & 6 deletions .github/workflows/autowiki.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,20 +21,16 @@ jobs:
- name: Checkout
if: steps.secrets_set.outputs.SECRETS_ENABLED
uses: actions/checkout@v4
- name: Restore BYOND cache
- name: Install BYOND
if: steps.secrets_set.outputs.SECRETS_ENABLED
uses: actions/cache@v4
with:
path: ~/BYOND
key: ${{ runner.os }}-byond-${{ hashFiles('dependencies.sh') }}
uses: ./.github/actions/restore_or_install_byond
- name: Install rust-g
if: steps.secrets_set.outputs.SECRETS_ENABLED
run: |
bash tools/ci/install_rust_g.sh
- name: Compile and generate Autowiki files
if: steps.secrets_set.outputs.SECRETS_ENABLED
run: |
bash tools/ci/install_byond.sh
source $HOME/BYOND/byond/bin/byondsetup
tools/build/build --ci autowiki
- name: Run Autowiki
Expand Down
37 changes: 14 additions & 23 deletions .github/workflows/ci_suite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,10 @@ jobs:
with:
path: tools/icon_cutter/cache
key: ${{ runner.os }}-cutter-${{ hashFiles('dependencies.sh') }}
- name: Setup .NET SDK
uses: actions/[email protected]
with:
dotnet-version: 9.x
- name: Install OpenDream
uses: robinraju/[email protected]
with:
Expand Down Expand Up @@ -150,14 +154,10 @@ jobs:

steps:
- uses: actions/checkout@v4
- name: Restore BYOND cache
uses: actions/cache@v4
with:
path: ~/BYOND
key: ${{ runner.os }}-byond-${{ hashFiles('dependencies.sh') }}
- name: Restore BYOND from Cache
uses: ./.github/actions/restore_or_install_byond
- name: Compile All Maps
run: |
bash tools/ci/install_byond.sh
source $HOME/BYOND/byond/bin/byondsetup
tools/build/build --ci dm -DCIBUILDING -DCITESTING -DALL_MAPS
- name: Check client Compatibility
Expand All @@ -167,7 +167,7 @@ jobs:
max-required-client-version: ${{needs.collect_data.outputs.max_required_byond_client}}

collect_data:
name: Collect data for other tasks
name: Collect data and setup caches for other tasks
needs: start_gate
runs-on: ubuntu-22.04
timeout-minutes: 5
Expand Down Expand Up @@ -195,36 +195,27 @@ jobs:
#the regex here does not filter out non-numbers because error messages about no input are less helpful then error messages about bad input (which includes the bad input)
run: |
echo "max_required_byond_client=$(grep -Ev '^[[:blank:]]{0,}#{1,}|^[[:blank:]]{0,}$' .github/max_required_byond_client.txt | tail -n1)" >> $GITHUB_OUTPUT
- name: Set up BYOND cache
uses: ./.github/actions/restore_or_install_byond

run_all_tests:
name: Integration Tests
needs: collect_data

strategy:
fail-fast: false
matrix:
map: ${{ fromJSON(needs.collect_data.outputs.maps).paths }}

uses: ./.github/workflows/run_integration_tests.yml
uses: ./.github/workflows/perform_regular_version_tests.yml
with:
map: ${{ matrix.map }}
maps: ${{ needs.collect_data.outputs.maps }}
max_required_byond_client: ${{needs.collect_data.outputs.max_required_byond_client}}

run_alternate_tests:
if: needs.collect_data.outputs.alternate_tests != '[]'
name: Alternate Tests
needs: collect_data
strategy:
fail-fast: false
matrix:
setup: ${{ fromJSON(needs.collect_data.outputs.alternate_tests) }}

uses: ./.github/workflows/run_integration_tests.yml
uses: ./.github/workflows/perform_alternate_version_tests.yml
with:
map: ${{ matrix.setup.map }}
major: ${{ matrix.setup.major }}
minor: ${{ matrix.setup.minor }}
max_required_byond_client: ${{ matrix.setup.max_client_version || needs.collect_data.outputs.max_required_byond_client }}
alternate_tests: ${{ needs.collect_data.outputs.alternate_tests }}
default_max_required_byond_client: ${{ needs.collect_data.outputs.max_required_byond_client }}

compare_screenshots:
if: needs.collect_data.outputs.alternate_tests == '[]' || needs.run_alternate_tests.result == 'success'
Expand Down
28 changes: 26 additions & 2 deletions .github/workflows/gbp.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,34 @@
name: GBP
name: Label and GBP
on:
pull_request_target:
types: [closed, opened]
types: [closed, opened, synchronize]
jobs:
# labeler must run before gbp because gbp calculates itself based on labels
labeler:
runs-on: ubuntu-latest
if: github.event.action == 'opened' || github.event.action == 'synchronize'
permissions:
pull-requests: write # to apply labels
issues: write # to apply labels
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Run Auto Labeler
uses: actions/github-script@v7
with:
script: |
const { get_updated_label_set } = await import('${{ github.workspace }}/tools/pull_request_hooks/autoLabel.js');
const new_labels = await get_updated_label_set({ github, context });
github.rest.issues.setLabels({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
labels: new_labels,
});
console.log(`Labels updated: ${new_labels}`);
gbp:
runs-on: ubuntu-latest
if: github.event.action == 'opened' || github.event.action == 'closed'
steps:
- name: "Check for ACTION_ENABLER secret and pass true to output if it exists to be checked by later steps"
id: value_holder
Expand Down
25 changes: 25 additions & 0 deletions .github/workflows/perform_alternate_version_tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
name: Run Alternate BYOND Version Tests
on:
workflow_call:
inputs:
alternate_tests:
required: true
type: string
default_max_required_byond_client:
required: true
type: string

jobs:
run:
uses: ./.github/workflows/run_integration_tests.yml

strategy:
fail-fast: false
matrix:
setup: ${{ fromJSON(inputs.alternate_tests) }}

with:
map: ${{ matrix.setup.map }}
major: ${{ matrix.setup.major }}
minor: ${{ matrix.setup.minor }}
max_required_byond_client: ${{ matrix.setup.max_client_version || inputs.default_max_required_byond_client }}
23 changes: 23 additions & 0 deletions .github/workflows/perform_regular_version_tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Run Regular BYOND Version Tests
on:
workflow_call:
inputs:
maps:
required: true
type: string
max_required_byond_client:
required: true
type: string

jobs:
run:
uses: ./.github/workflows/run_integration_tests.yml

strategy:
fail-fast: false
matrix:
map: ${{ fromJSON(inputs.maps).paths }}

with:
map: ${{ matrix.map }}
max_required_byond_client: ${{ inputs.max_required_byond_client }}
22 changes: 11 additions & 11 deletions .github/workflows/run_integration_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@ on:

jobs:
run_integration_tests:
# If `inputs.major` is specified, this will output `Run Tests (major.minor; map; max)`.
# For example, `Run Tests (515.1627; runtimestation; 515)`.
#
# Otherwise, it will output `Run Tests (map; max)`.
# For example, `Run Tests (runtimestation; 515)`.
name: Run Tests (${{ inputs.major && format('{0}.{1}; ', inputs.major, inputs.minor) || '' }}${{ inputs.map }}; ${{ inputs.max_required_byond_client }})
runs-on: ubuntu-latest
timeout-minutes: 15
services:
Expand All @@ -31,11 +37,6 @@ jobs:
options: --health-cmd="mysqladmin ping" --health-interval=10s --health-timeout=5s --health-retries=3
steps:
- uses: actions/checkout@v4
- name: Restore BYOND cache
uses: actions/cache@v4
with:
path: ~/BYOND
key: ${{ runner.os }}-byond-${{ hashFiles('dependencies.sh') }}
- name: Setup database
run: |
sudo systemctl start mysql
Expand All @@ -49,15 +50,14 @@ jobs:
- name: Install dreamluau
run: |
bash tools/ci/install_dreamluau.sh
- name: Configure version
run: |
echo "BYOND_MAJOR=${{ inputs.major }}" >> $GITHUB_ENV
echo "BYOND_MINOR=${{ inputs.minor }}" >> $GITHUB_ENV
if: ${{ inputs.major }}
- name: Restore BYOND from Cache
uses: ./.github/actions/restore_or_install_byond
with:
major: ${{ inputs.major }}
minor: ${{ inputs.minor }}
- name: Compile Tests
id: compile_tests
run: |
bash tools/ci/install_byond.sh
source $HOME/BYOND/byond/bin/byondsetup
tools/build/build --ci dm -DCIBUILDING -DANSICOLORS -Werror -ITG0001 -I"loop_checks"
- name: Run Tests
Expand Down
2 changes: 1 addition & 1 deletion .tgs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
version: 1
# The BYOND version to use (kept in sync with dependencies.sh by the "TGS Test Suite" CI job)
# Must be interpreted as a string, keep quoted
byond: "515.1637"
byond: "515.1647"
# Folders to create in "<instance_path>/Configuration/GameStaticFiles/"
static_files:
# Config directory should be static
Expand Down
22 changes: 1 addition & 21 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,27 +18,7 @@
"git.branchProtection": ["master"],
"gitlens.advanced.blame.customArguments": ["-w"],
"tgstationTestExplorer.project.resultsType": "json",
"[javascript]": {
"editor.rulers": [80],
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
"[javascriptreact]": {
"editor.rulers": [80],
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
"[typescript]": {
"editor.rulers": [80],
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
"[typescriptreact]": {
"editor.rulers": [80],
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
"[scss]": {
"[javascript][typescript][typescriptreact][javascriptreact][html][scss][css][json][jsonc][markdown][yaml]": {
"editor.rulers": [80],
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@
/obj/structure/railing/corner{
dir = 4
},
/mob/living/simple_animal/hostile/mimic/crate,
/mob/living/basic/mimic/crate,
/turf/open/floor/plating/snowed/icemoon,
/area/icemoon/underground/explored)
"fO" = (
Expand Down Expand Up @@ -2073,7 +2073,7 @@
/turf/open/floor/plating/snowed/smoothed/icemoon,
/area/icemoon/underground/explored)
"KV" = (
/mob/living/simple_animal/hostile/mimic/crate,
/mob/living/basic/mimic/crate,
/turf/open/floor/plating/snowed/icemoon,
/area/icemoon/underground/explored)
"KY" = (
Expand Down
Loading

0 comments on commit 5c977db

Please sign in to comment.