Skip to content

Commit

Permalink
Merge branch 'master220' into vox_raiders
Browse files Browse the repository at this point in the history
  • Loading branch information
PhantornRU committed Apr 8, 2024
2 parents 089254a + 55ca66f commit 5c6f7a7
Show file tree
Hide file tree
Showing 596 changed files with 9,076 additions and 3,877 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,4 @@ contact_links:
about: Запросы новых фич следует оставлять на форуме ss13-трекер в дискорде.
- name: Exploit Reports
url: https://github.com/ss220club/Paradise-SS220/security
about: Критические баги, которые могут быть использованы со злыми намерениями следует оставлять по ссылке.
about: Критические баги, которые могут быть использованы со злыми намерениями, следует оставлять по ссылке.
8 changes: 4 additions & 4 deletions .github/ISSUE_TEMPLATE/issue_report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ body:
id: version
attributes:
label: BYOND Version
description: "На какой версии BYOND встретился баг. (Если уверены, что не связано - можно пропустить.)"
description: "На какой версии BYOND встретился баг. (Если уверены, что не связано, можно пропустить)"

- type: textarea
id: description
Expand Down Expand Up @@ -61,7 +61,7 @@ body:
attributes:
label: Шаги для повторения проблемы.
description: Самая важная часть. Опишите ВСЁ, что вы делали, что бы встретиться с проблемой. (Обязательное поле)
placeholder: Find a chair, buckle yourself into it, be eaten by dragon.
placeholder: Нашел стул, сел, взорвался.
validations:
required: true

Expand All @@ -79,11 +79,11 @@ body:
attributes:
label: Дополнительная информация
description: Всё, что вы считаете важным/относящимся к проблеме.
placeholder: "Я думаю, что проблема начала появляться после этого PR https://github.com/ss220club/Paradise-SS220/pull/583"
placeholder: Я думаю, что проблема начала появляться после этого PR https://github.com/ss220club/Paradise-SS220/pull/583

- type: textarea
id: logs
attributes:
label: Связанные логи
description: Пожалуйста, предоставьте связанные логи или рантаймы, если имеете к ним доступ(Лучше цензурить IP адреса).
description: Пожалуйста, предоставьте связанные логи или рантаймы, если имеете к ним доступ. (Лучше цензурить IP-адреса)
render: DM
2 changes: 1 addition & 1 deletion .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ sounddel: Удалил старый звук
imageadd: Добавил новую картинку
imagedel: Удалил старую картинку
spellcheck: Исправил опечатку
experiment: Добавил эксперементальную функцию
experiment: Добавил экспериментальную функцию
/:cl:

<!-- Оба :cl:'а должны быть на месте, что-бы чейнджлог работал! Вы можете написать свой ник справа от первого :cl:, если хотите. Иначе будет использован ваш ник на ГитХабе. -->
Expand Down
54 changes: 27 additions & 27 deletions .github/labeler.yml
Original file line number Diff line number Diff line change
@@ -1,39 +1,39 @@
"TGUI":
- 'tgui/**'
'TGUI':
- 'tgui/**'

"Звук":
- '**/*.ogg'
'Звук':
- '**/*.ogg'

"Изменение Карты":
- '**/*.dmm'
'Изменение Карты':
- '**/*.dmm'

"Инструменты":
- '.gihub/workflows/**'
- 'tools/**'
'Инструменты':
- '.gihub/workflows/**'
- 'tools/**'

"Керберос":
- '_maps/map_files220/delta/delta.dmm'
'Керберос':
- '_maps/map_files220/stations/deltastation.dmm'

"Кибериада":
- '_maps/map_files220/cyberiad/cyberiad.dmm'
'Кибериада':
- '_maps/map_files220/stations/boxstation.dmm'

"Цереброн":
- '_maps/map_files220/MetaStation/MetaStation.dmm'
'Цереброн':
- '_maps/map_files220/stations/metastation.dmm'

"НЕ МОДУЛЬНО":
- all: ['code/**']
'НЕ МОДУЛЬНО':
- all: ['code/**']

"Спрайты":
- '**/*.dmi'
'Спрайты':
- '**/*.dmi'

"Требуется изменение конфига":
- 'config/**'
'Требуется изменение конфига':
- 'config/**'

"Документация":
- '**/*.md'
'Документация':
- '**/*.md'

"Частичная модульность":
- all: ['code/**', modular_ss220/**]
'Частичная модульность':
- all: ['code/**', modular_ss220/**]

"SQL":
- 'SQL/**'
'SQL':
- 'SQL/**'
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ jobs:
strategy:
fail-fast: false # Let all map tests run to completion
matrix:
maptype: ['/datum/map/cyberiad', '/datum/map/delta', '/datum/map/metastation', '/datum/map/cerestation']
maptype: ['/datum/map/boxstation', '/datum/map/deltastation', '/datum/map/metastation', '/datum/map/cerestation']
byondtype: ['STABLE']
services:
mariadb:
Expand Down
24 changes: 24 additions & 0 deletions .github/workflows/label_stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Label and close stale PRs and Issues

on:
schedule:
- cron: '0 0 * * *' # Runs at midnight UTC every day

jobs:
stale-prs:
runs-on: ubuntu-latest
steps:
- name: Seek and destroy stale PRs and Issues
uses: actions/stale@v9
with:
stale-pr-message: 'This pull request seems to be stale as there have been no changes in 14 days, please make changes within 7 days or the PR will be closed. If you believe this is a mistake, please inform a development team member on Discord.'
close-pr-message: 'This pull request has not received any updates since being marked stale, and as such is now being automatically closed. Please feel free to re-open this pull request or open a new one once you have new updates.'
stale-issue-message: 'This issue either requires verification or is unreproducible, but has had no updates for 60 days. Please provide an update within 14 days or this issue will be closed. If you believe this is a mistake, please contact an issue manager on Discord.'
close-issue-message: 'This issue was marked as stale, yet no changes have been observed in the specified time. The issue has been closed.'
days-before-stale: 14
days-before-issue-stale: 60
days-before-close: 7
days-before-issue-close: 14
exempt-issue-labels: '"Stale Exempt"'
exempt-pr-labels: '"Stale Exempt", "-Status: Awaiting approval", "-Status: Awaiting Merge", "-Status: Awaiting type assignment"'
any-of-issue-labels: '"Need Verification", "Cannot Reproduce", "Not A Bug", "(99% Sure) Not A Bug"'
43 changes: 34 additions & 9 deletions .github/workflows/merge_upstream_master.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Merge Upstream Master
on:
issue_comment:
types: [created]
types: created

jobs:
merge-upstream:
Expand All @@ -15,13 +15,30 @@ jobs:
runs-on: ubuntu-latest
steps:
- id: create_token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ secrets.APP_ID }}
private-key: ${{ secrets.PRIVATE_KEY }}

- run: echo "GH_TOKEN=${{ steps.create_token.outputs.token }}" >> "$GITHUB_ENV"
- run: echo "FAIL_NOTIFIED=false" >> "$GITHUB_ENV"

- name: Like the comment
run: |
gh api \
--method POST \
-H "Accept: application/vnd.github+json" \
-H "X-GitHub-Api-Version: 2022-11-28" \
/repos/ParadiseSS13/Paradise/issues/comments/${{ github.event.comment.id }}/reactions \
-f content='+1'
- name: PR Data
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
pr_json=$(curl -L -s --fail-with-body -H "Authorization: token ${{ github.token }}" ${{ github.event.issue.pull_request.url }})
if [ `jq -r '.maintainer_can_modify' <<<$pr_json` == "false" ] ; then
gh pr comment ${{ github.event.issue.html_url }} --body 'GitHub Actions can not push to the repository without "Allow edits and access to secrets by maintainers" checked.'
echo "FAIL_NOTIFIED=true" >> "$GITHUB_ENV"
exit 1
fi
echo "PR_REPO=`jq -r '.head.repo.full_name' <<<$pr_json`" >> $GITHUB_ENV
Expand All @@ -32,6 +49,7 @@ jobs:
with:
repository: ${{ env.PR_REPO }}
ref: ${{ env.PR_BRANCH }}
token: ${{ env.GH_TOKEN }}

- uses: actions/setup-node@v4
with:
Expand Down Expand Up @@ -73,18 +91,25 @@ jobs:
chmod +x tools/hooks/*.merge tgui/bin/tgui
# Actual Merge
git config user.name github-actions
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
git config user.name paradisess13[bot]
git config user.email "165046124+paradisess13[bot]@users.noreply.github.com"
git remote add upstream "https://github.com/$BASE_REPOSITORY.git"
git fetch origin "$PR_BRANCH" --depth=$((ahead_by + 1))
git fetch upstream "$BASE_BRANCH" --depth=$((behind_by + 1))
# Check if a workflow file would be modified by the merge (permissions prevent pushes if so)
latest_workflow_commit=$(git log -n 1 --pretty=format:"%H" upstream/$BASE_BRANCH -- .github/workflows)
if ! git branch --contains $latest_workflow_commit | grep -q "$(git rev-parse --abbrev-ref HEAD)"; then
gh pr comment ${{ github.event.issue.html_url }} --body "GitHub Actions can not push to this branch as workflow files have been changed since your branch was last updated. Please update your branch past https://github.com/ParadiseSS13/Paradise/commit/$latest_workflow_commit before using this command again."#
echo "FAIL_NOTIFIED=true" >> "$GITHUB_ENV"
exit 1
fi
git merge FETCH_HEAD
git push origin
- name: Notify Failure
if: failure()
if: failure() && env.FAIL_NOTIFIED != 'true'
run: |
curl -s -H "Authorization: token ${{ github.token }}" \
-X POST -d '{"body": "Merging upstream failed:\nhttps://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}"}' \
"https://api.github.com/repos/${{ github.repository }}/issues/${{ github.event.issue.number }}/comments"
gh pr comment ${{ github.event.issue.html_url }} -b 'Merging upstream failed, see the action run log for details: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}'
29 changes: 12 additions & 17 deletions .github/workflows/render_nanomaps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,19 +9,23 @@ on:
- cron: "0 0 * * *"
workflow_dispatch:

permissions:
contents: read

jobs:
generate_maps:
permissions:
contents: write # for Git to git push
pull-requests: write # for repo-sync/pull-request to create pull requests
name: 'Generate NanoMaps'
runs-on: ubuntu-22.04
steps:
- id: create_token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ secrets.APP_ID }}
private-key: ${{ secrets.PRIVATE_KEY }}

- run: echo "GH_TOKEN=${{ steps.create_token.outputs.token }}" >> "$GITHUB_ENV"

- name: 'Update Branch'
uses: actions/checkout@v4
with:
token: ${{ steps.create_token.outputs.token }}

- name: Branch
run: |
Expand All @@ -32,20 +36,11 @@ jobs:
- name: 'Generate Maps'
run: './tools/github-actions/nanomap-renderer-invoker.sh'

- name: 'Commit Maps'
- name: 'Commit Maps and open PR'
run: |
git config --local user.email "action@github.com"
git config --local user.name "NanoMap Generation"
git pull origin master
git commit -m "NanoMap Auto-Update (`date`)" -a || true
git push -f -u origin nanomap-render
- name: Create Pull Request
uses: repo-sync/pull-request@v2
with:
source_branch: "nanomap-render"
destination_branch: "master"
pr_title: "Automatic NanoMap Update"
pr_body: "This pull request updates the server NanoMaps. Please review the diff images before merging."
pr_label: "NanoMaps"
pr_allow_empty: false
gh pr create -t "Automatic NanoMap Update" -b "This pull request updates the server NanoMaps. Please review the diff images before merging." -l "NanoMaps" -H "nanomap-render" -B "master"
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ stddef.dm
*.vscode/*
!/.vscode/extensions.json
!/.vscode/tasks.json
!/.vscode/launch.json

# ignore DMI tool build cache
/tools/dmitool/bin/
Expand Down
18 changes: 18 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
{
"version": "0.2.0",
"configurations": [
{
"type": "byond",
"request": "launch",
"name": "Build & DS Debug",
"preLaunchTask": "dm: build - ${command:CurrentDME}",
"dmb": "${workspaceFolder}/${command:CurrentDMB}"
},
{
"type": "byond",
"request": "launch",
"name": "DS Debug",
"dmb": "${workspaceFolder}/${command:CurrentDMB}"
}
]
}
44 changes: 31 additions & 13 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,35 +1,53 @@
{
"gitlens.advanced.blame.customArguments": [
"--ignore-revs-file",
"${workspaceRoot}/.git-blame-ignore-revs"
],
// ESLint settings:
"eslint.workingDirectories": ["tgui/"],
"search.exclude": {
"**/.yarn": true,
"**/.pnp.*": true
},
"eslint.nodePath": "tgui/.yarn/sdks",
"prettier.configPath": "tgui/.prettierrc.yml",
"prettier.prettierPath": "tgui/.yarn/sdks/prettier/index.cjs",
"typescript.tsdk": "tgui/.yarn/sdks/typescript/lib",
"typescript.enablePromptUseWorkspaceTsdk": true,
"search.exclude": {
"**/.yarn": true,
"**/.pnp.*": true
},
"eslint.format.enable": true,
"eslint.rules.customizations": [
// We really want to fail the CI builds on styling errors,
// but it's better to show them as yellow squigglies in IDE
// and thus differentiate from the red typescript ones which
// are actually hard errors.
{ "rule": "*", "severity": "warn" }
],
"eslint.format.enable": true,

"[javascript]": {
"editor.rulers": [80]
"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.rulers": [80],
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
"[typescriptreact]": {
"editor.rulers": [80],
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
"[scss]": {
"editor.rulers": [80]
"editor.rulers": [80],
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true
},
"editor.formatOnSave": true

"editor.formatOnSave": true,
"gitlens.advanced.blame.customArguments": [
"--ignore-revs-file",
"${workspaceRoot}/.git-blame-ignore-revs"
],
}
1 change: 1 addition & 0 deletions SQL/paradise_schema.sql
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,7 @@ CREATE TABLE `characters` (
`hair_gradient_colour` varchar(7) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '#000000',
`hair_gradient_alpha` tinyint(3) UNSIGNED NOT NULL DEFAULT '255',
`custom_emotes` LONGTEXT COLLATE 'utf8mb4_unicode_ci' DEFAULT NULL,
`cyborg_brain_type` ENUM('MMI', 'Robobrain', 'Positronic') NOT NULL DEFAULT 'MMI',
`tts_seed` varchar(32) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `ckey` (`ckey`)
Expand Down
5 changes: 5 additions & 0 deletions SQL/updates/53-54.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#Updating SQL from 53 to 54 -Wilk
#Add a choice for what type of brain borgs want to have

ALTER TABLE `characters`
ADD COLUMN `cyborg_brain_type` VARCHAR(11) NOT NULL DEFAULT 'MMI' AFTER `height`;
Loading

0 comments on commit 5c6f7a7

Please sign in to comment.