Skip to content

prettier.

prettier. #303

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install client modules
run: cd client && yarn install --frozen-lockfile
- name: Run client ESLint & Prettier
run: cd client && yarn run lint
- name: Check client types
run: cd client && yarn run tsc
- name: Install server modules
run: cd server && yarn install --frozen-lockfile
- name: Run server ESLint & Prettier
run: cd server && yarn run lint
- name: Check server types
run: cd server && yarn run build:types
build:
runs-on: ubuntu-latest
needs: [lint]
if: github.ref == 'refs/heads/main'
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ env.node-version }}
uses: actions/setup-node@v2
with:
node-version: ${{ env.node-version }}
- run: |
git config user.name "O.A.F."
git config user.email "<>"
- run: cd server && yarn install --frozen-lockfile
- run: cd server && yarn run build
- run: cd client && yarn install --frozen-lockfile
- run: cd client && yarn run build
- run: |
git fetch --all
mv server server-files
mv client client-files
if ! git switch release; then git switch --orphan release; fi
- run: |
rm -rf relay
mkdir -p relay/yorick
cp server-files/KoLmafia/relay/* relay/
cp client-files/KoLmafia/relay/relay_YORICK.js relay/
cp -R client-files/build/* relay/yorick/
- run: |
git add relay/
{
git commit -m "Build Mafia files for commit $GITHUB_SHA"
git push origin release
} || exit 0