Skip to content

Commit

Permalink
Merge branch 'develop' into balance/mercy-cost-buff
Browse files Browse the repository at this point in the history
  • Loading branch information
lL1l1 committed Aug 11, 2024
2 parents 8ac6720 + 4f49952 commit d0744f3
Show file tree
Hide file tree
Showing 218 changed files with 11,037 additions and 264 deletions.
3 changes: 3 additions & 0 deletions .github/DEPLOYMENT.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ The following (manual) steps are relevant to create a valid deployment to the FA
- (2) Update the game executable. This needs to be done by a server administrator. This is only required when there are changes to the executable.
- (3) Update the changelog in [changelog.md](/CHANGELOG.md) and [changelogData.lua](../lua/ui/lobby/changelogData.lua).
- (4) Update the game version in [changelogData.lua](../lua/ui/lobby/changelogData.lua).
- (5) Push all the commits that you want to release to the [master](https://github.com/FAForever/fa/tree/master) branch.
- (6) Trigger the [deployment workflow](https://github.com/FAForever/fa/actions/workflows/deploy-faf.yaml) for the FAF game type.
- (7) Create a [release on GitHub](https://github.com/FAForever/fa/releases) that targets the [master](https://github.com/FAForever/fa/tree/master) branch.

## Automated deployments

Expand Down
69 changes: 0 additions & 69 deletions .github/workflows/changelog.yaml

This file was deleted.

38 changes: 36 additions & 2 deletions .github/workflows/deploy-faf.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,12 @@

name: Deploy to FAF

# Prevent simultaneous deployments across all deployment branches as
# the server is unable to process multiple deployments at the same time.

concurrency:
cancel-in-progress: true
group: deploy/faf
group: deployment

on:
workflow_dispatch:
Expand All @@ -41,7 +44,38 @@ jobs:
uses: actions/checkout@v4
with:
repository: FAForever/fa
ref: develop
ref: master

# Allows us to better understand the game version and the specific commit hash when we receive a log
- name: Update version references
run: |
COMMITHASH=$(git rev-parse HEAD)
sed -i "s/local Commit = 'unknown'/local Commit = \"${COMMITHASH}\"/" "lua/version.lua"
sed -i "s/local GameType = 'unknown'/local GameType = \"FAF\"/" "lua/version.lua"
# debugging
cat lua/version.lua
# Disable debugging statements
- name: Overwrite debug references
run: |
sed -i "s/EnabledSpewing = true,/EnabledSpewing = false,/" "lua/shared/components/DebugComponent.lua"
sed -i "s/EnabledLogging = true,/EnabledLogging = false,/" "lua/shared/components/DebugComponent.lua"
sed -i "s/EnabledWarnings = true,/EnabledWarnings = false,/" "lua/shared/components/DebugComponent.lua"
sed -i "s/EnabledDrawing = true,/EnabledDrawing = false,/" "lua/shared/components/DebugComponent.lua"
# debugging
cat lua/shared/components/DebugComponent.lua
# Create a commit with the changes of the workflow in it
- name: Create a commit
run: |
# Configure git
git config user.email "[email protected]"
git config user.name "FAForever"
git add .
git commit -m "Post-process deployment"
# Update the deploy/faf branch, we force push here because
# we're not interested in fixing conflicts
Expand Down
35 changes: 34 additions & 1 deletion .github/workflows/deploy-fafbeta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,12 @@

name: Deploy to FAF Beta Balance

# Prevent simultaneous deployments across all deployment branches as
# the server is unable to process multiple deployments at the same time.

concurrency:
cancel-in-progress: true
group: deploy/fafbeta
group: deployment

on:
workflow_dispatch:
Expand All @@ -44,6 +47,36 @@ jobs:
repository: FAForever/fa
ref: develop

# Allows us to better understand the game version and the specific commit hash when we receive a log
- name: Update version references
run: |
COMMITHASH=$(git rev-parse HEAD)
sed -i "s/local Commit = 'unknown'/local Commit = \"${COMMITHASH}\"/" "lua/version.lua"
sed -i "s/local GameType = 'unknown'/local GameType = \"FAF Beta Balance\"/" "lua/version.lua"
# debugging
cat lua/version.lua
# Disable debugging statements
#
# You can overwrite these adjustments by setting up a `Debug` folder
- name: Overwrite debug references
run: |
sed -i "s/EnabledDrawing = true,/EnabledDrawing = false,/" "lua/shared/components/DebugComponent.lua"
# debugging
cat lua/shared/components/DebugComponent.lua
# Create a commit with the changes of the workflow in it
- name: Create a commit
run: |
# Configure git
git config user.email "[email protected]"
git config user.name "FAForever"
git add .
git commit -m "Post-process deployment"
# Update the deploy/fafbeta branch, we force push here because
# we're not interested in fixing conflicts
- name: Update deploy/fafbeta
Expand Down
35 changes: 34 additions & 1 deletion .github/workflows/deploy-fafdevelop.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,12 @@

name: Deploy to FAF Develop

# Prevent simultaneous deployments across all deployment branches as
# the server is unable to process multiple deployments at the same time.

concurrency:
cancel-in-progress: true
group: deploy/fafdevelop
group: deployment

on:
workflow_dispatch:
Expand All @@ -44,6 +47,36 @@ jobs:
repository: FAForever/fa
ref: develop

# Allows us to better understand the game version and the specific commit hash when we receive a log
- name: Update version references
run: |
COMMITHASH=$(git rev-parse HEAD)
sed -i "s/local Commit = 'unknown'/local Commit = \"${COMMITHASH}\"/" "lua/version.lua"
sed -i "s/local GameType = 'unknown'/local GameType = \"FAF Develop\"/" "lua/version.lua"
# debugging
cat lua/version.lua
# Disable debugging statements
#
# You can overwrite these adjustments by setting up a `Debug` folder
- name: Overwrite debug references
run: |
sed -i "s/EnabledDrawing = true,/EnabledDrawing = false,/" "lua/shared/components/DebugComponent.lua"
# debugging
cat lua/shared/components/DebugComponent.lua
# Create a commit with the changes of the workflow in it
- name: Create a commit
run: |
# Configure git
git config user.email "[email protected]"
git config user.name "FAForever"
git add .
git commit -m "Post-process deployment"
# Update the deploy/fafdevelop branch, we force push here because
# we're not interested in fixing conflicts
- name: Update deploy/fafdevelop
Expand Down
100 changes: 85 additions & 15 deletions .github/workflows/docs-build.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,29 @@
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# Copyright (c) FAForever
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
# copies of the Software, and to permit persons to whom the Software is
# furnished to do so, subject to the following conditions:
#
# The above copyright notice and this permission notice shall be included in all
# copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
# SOFTWARE.

# Sample workflow for building and deploying a Jekyll site to GitHub Pages
name: Documentation - Build and deploy

on:
push:
branches: ['develop']
paths: ['docs/**']
branches: ["develop", "deploy/fafdevelop", "deploy/fafbeta"]
paths: ["docs/**", "changelog/snippets/*.md"]

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
Expand All @@ -22,41 +36,97 @@ permissions:

# Allow one concurrent deployment
concurrency:
group: 'pages'
group: "pages"
cancel-in-progress: true

jobs:
# Build job
changelog-develop:
name: Create changelog of FAF Develop
uses: ./.github/workflows/docs-changelog.yaml
with:
reference: deploy/fafdevelop

changelog-beta:
name: Create changelog of FAF Beta
uses: ./.github/workflows/docs-changelog.yaml
with:
reference: deploy/fafbeta

build:
name: Build the documentation
needs: [changelog-develop, changelog-beta]
runs-on: ubuntu-latest
defaults:
run:
working-directory: docs
steps:
- name: Checkout
uses: actions/checkout@v4
with:
sparse-checkout: |
docs
.github/workflows/scripts
# Set environment path for scripts so we can access it later
- name: Update environment path
run: |
echo "${{ github.workspace }}/.github/workflows/scripts" >> $GITHUB_PATH
# Retrieve the generated changelogs
- name: Download artifact changelog of FAF Develop
uses: actions/download-artifact@v4
with:
name: changelog-fafdevelop
path: docs/generated

- name: Download artifact changelog of FAF Beta
uses: actions/download-artifact@v4
with:
name: changelog-fafbeta
path: docs/generated

# Append the generated changelogs to the Jekyll-compatible templates
- name: Append the generated changelogs
run: |
cat generated/fafdevelop.md >> patches/fafdevelop.md
# Update the posts directory contents
- name: Update changelog posts directory
shell: bash
run: |
changelog-links.sh _posts FAForever fa github.com
# Update the patches directory contents
- name: Update changelog patches directory
shell: bash
run: |
changelog-links.sh patches FAForever fa github.com
- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.3' # Not needed with a .ruby-version file
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
cache-version: 0 # Increment this number if you need to re-download cached gems
working-directory: '${{ github.workspace }}/docs'
ruby-version: "3.3"
bundler-cache: true
cache-version: 0
working-directory: "${{ github.workspace }}/docs"

- name: Setup Pages
id: pages
uses: actions/configure-pages@v5

- name: Build with Jekyll
# Outputs to the './_site' directory by default
run: bundle exec jekyll build --baseurl "${{ steps.pages.outputs.base_path }}"
env:
JEKYLL_ENV: production

- name: Upload artifact
# Automatically uploads an artifact from the './_site' directory by default
uses: actions/upload-pages-artifact@v3
with:
path: 'docs/_site/'
path: "docs/_site/"

# Deployment job
deploy:
environment:
name: github-pages
Expand Down
Loading

0 comments on commit d0744f3

Please sign in to comment.