From 418b66cadbe9d25fda0ea8b48ea12e3bbf762389 Mon Sep 17 00:00:00 2001 From: Kalle <38327916+Sendouc@users.noreply.github.com> Date: Mon, 5 Apr 2021 19:44:43 +0300 Subject: [PATCH] Revert "Further testing of GitHub Actions (#342)" (#361) This reverts commit 369911277bb6431542d3d7d719a38be2e1305590. --- .github/workflows/ci.yml | 41 ++-------------------------------------- .prettierignore | 3 --- package.json | 1 - utils/i18n.ts | 4 ++-- 4 files changed, 4 insertions(+), 45 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6779fa6c3..61c268cc2 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -5,45 +5,8 @@ jobs: cypress-run: name: Cypress tests runs-on: ubuntu-latest - services: - postgres: - image: postgres - env: - POSTGRES_PASSWORD: password - POSTGRES_USER: sendou_ink - ports: - - 5432:5432 - # Set health checks to wait until postgres has started - options: >- - --health-cmd pg_isready - --health-interval 10s - --health-timeout 5s - --health-retries 5 steps: - - name: Check out code + - name: Checkout uses: actions/checkout@25a956c84d5dd820d28caab9f86b8d183aeeff3d # v2 - - name: Install Node - uses: actions/setup-node@5c355be17065acf11598c7a9bb47112fbcf2bbdc # v2 - with: - node-version: "14" - - name: Install dependencies - run: npm install - - name: Write .env file for Prisma - run: echo "DATABASE_URL=postgresql://sendou_ink:password@localhost:${{ job.services.postgres.ports[5432] }}" > prisma/.env - - name: Prep the database - run: npm run migrate && npm run prebuild - - name: Run prettier - run: npm run prettier:check - - name: Run Cypress + - name: Cypress run uses: cypress-io/github-action@9eab5368cd2520a946489cd3f937583ff5a30443 # v2 - with: - start: npm run dev - - name: Save Cypress artifacts - uses: actions/upload-artifact@ea3d524381d563437a7d64af63f3d75ca55521c4 # v2 - if: failure() - with: - name: cypress-outputs - path: | - cypress/screenshots/* - cypress/videos/* - retention-days: 30 diff --git a/.prettierignore b/.prettierignore index 53a1edcfb..df73e95cc 100644 --- a/.prettierignore +++ b/.prettierignore @@ -2,6 +2,3 @@ prisma/scripts/data prisma/scripts/mongo - -# Ignore JSON files generated via script -utils/data/patrons.json diff --git a/package.json b/package.json index f452000f1..d230447ad 100644 --- a/package.json +++ b/package.json @@ -19,7 +19,6 @@ "compile": "lingui compile", "restore": "pg_restore -d 'postgresql://sendou@localhost:5432/dev' --jobs 4 dumped.sql --clean", "seed": "prisma db seed --preview-feature", - "prettier:check": "prettier --check .", "prettier:format": "prettier --write .", "cy:open": "cypress open", "cy:run": "cypress run", diff --git a/utils/i18n.ts b/utils/i18n.ts index 9e34e0e2f..6b1c2b214 100644 --- a/utils/i18n.ts +++ b/utils/i18n.ts @@ -8,8 +8,8 @@ i18n.loadLocaleData("en", { plurals: en }); */ export async function activateLocale(locale: string) { const [{ messages }, { messages: gameMessages }] = await Promise.all([ - import(`locale/${locale}/messages.json`), - import(`locale/${locale}/game.json`), + import(`locale/${locale}/messages.js`), + import(`locale/${locale}/game.js`), ]); i18n.load(locale, { ...messages, ...gameMessages }); i18n.activate(locale);