Updated server-ui version #337
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is a basic workflow to help you get started with Actions | |
name: Build | |
# Controls when the workflow will run | |
on: | |
# Triggers the workflow on push or pull request events on master branch | |
push: | |
branches: [ master ] | |
pull_request: | |
branches: [ master ] | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
# 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 "lint" | |
lint: | |
# 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@v3 | |
# Install python | |
- uses: actions/setup-python@v3 | |
with: | |
python-version: '3.x' | |
# Install isort and black for linting | |
- name: Install isort and black | |
run: pip install isort black | |
# Run isort | |
- name: Run isort | |
run: isort --check-only --profile black . | |
# Run black | |
- name: Run black | |
run: black --check --color --diff . | |
# This workflow contains a single job called "build" | |
build: | |
# The type of runner that the job will run on | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
target: [debug, release] | |
# 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@v3 | |
- uses: montudor/action-zip@v1 | |
- uses: bahmutov/npm-install@v1 | |
with: | |
node-version: 16 | |
- uses: actions/setup-python@v3 | |
with: | |
python-version: '3.x' | |
- name: Install polib | |
run: pip install polib | |
- name: Test eslint | |
run: npm run lint | |
- name: Run build script (${{ matrix.target }}) | |
run: python build.py --clean --target ${{ matrix.target }} | |
- name: Archive addon artifact (release) | |
uses: actions/upload-artifact@v3 | |
if: ${{ matrix.target == 'release'}} | |
with: | |
name: mcaddon-artifact-release | |
path: builds/WorldEdit.mcaddon | |
- name: Archive addon artifact (debug) | |
uses: actions/upload-artifact@v3 | |
if: ${{ matrix.target == 'debug'}} | |
with: | |
name: mcaddon-artifact-debug | |
path: | | |
builds/WorldEditBP | |
builds/WorldEditRP |