diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 4d2d3641ac..2e4297d0a1 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -39,7 +39,7 @@ jobs: echo "needs_build: ${{ steps.filter.outputs.needs_build }}" echo "templates: ${{ steps.filter.outputs.templates }}" - core-build: + build: needs: changes if: ${{ needs.changes.outputs.needs_build == 'true' }} runs-on: ubuntu-latest @@ -65,65 +65,29 @@ jobs: run: | echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV - - uses: actions/cache@v4 - name: Setup pnpm cache + - name: Setup pnpm cache + uses: actions/cache@v4 + timeout-minutes: 720 with: path: ${{ env.STORE_PATH }} - key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + key: pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} restore-keys: | - ${{ runner.os }}-pnpm-store- - ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} + pnpm-store- + pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} - run: pnpm install - - run: pnpm run build:core + - run: pnpm run build:all - name: Cache build uses: actions/cache@v4 + timeout-minutes: 10 with: path: ./* key: ${{ github.sha }}-${{ github.run_number }} - plugins-build: - needs: changes - if: ${{ needs.changes.outputs.needs_build == 'true' }} - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v4 - with: - fetch-depth: 25 - - - name: Use Node.js 18 - uses: actions/setup-node@v4 - with: - node-version: 18 - - - name: Install pnpm - uses: pnpm/action-setup@v3 - with: - version: 8 - run_install: false - - - name: Get pnpm store directory - shell: bash - run: | - echo "STORE_PATH=$(pnpm store path --silent)" >> $GITHUB_ENV - - - uses: actions/cache@v4 - name: Setup pnpm cache - with: - path: ${{ env.STORE_PATH }} - key: ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} - restore-keys: | - ${{ runner.os }}-pnpm-store- - ${{ runner.os }}-pnpm-store-${{ hashFiles('**/pnpm-lock.yaml') }} - - - run: pnpm install - - run: pnpm run build:plugins - tests-unit: runs-on: ubuntu-latest - needs: core-build + needs: build if: false # Disable until tests are updated for 3.0 steps: @@ -140,6 +104,7 @@ jobs: - name: Restore build uses: actions/cache@v4 + timeout-minutes: 10 with: path: ./* key: ${{ github.sha }}-${{ github.run_number }} @@ -151,7 +116,7 @@ jobs: tests-int: runs-on: ubuntu-latest - needs: core-build + needs: build strategy: fail-fast: false matrix: @@ -184,6 +149,7 @@ jobs: - name: Restore build uses: actions/cache@v4 + timeout-minutes: 10 with: path: ./* key: ${{ github.sha }}-${{ github.run_number }} @@ -242,7 +208,7 @@ jobs: tests-e2e: runs-on: ubuntu-latest - needs: core-build + needs: build strategy: fail-fast: false matrix: @@ -279,6 +245,7 @@ jobs: - name: Restore build uses: actions/cache@v4 + timeout-minutes: 10 with: path: ./* key: ${{ github.sha }}-${{ github.run_number }} @@ -299,7 +266,7 @@ jobs: tests-type-generation: if: false # This should be replaced with gen on a real Payload project runs-on: ubuntu-latest - needs: core-build + needs: build steps: - name: Use Node.js 18 @@ -315,6 +282,7 @@ jobs: - name: Restore build uses: actions/cache@v4 + timeout-minutes: 10 with: path: ./* key: ${{ github.sha }}-${{ github.run_number }} diff --git a/packages/next/src/views/NotFound/index.tsx b/packages/next/src/views/NotFound/index.tsx index d70de66b8e..bc3f57b819 100644 --- a/packages/next/src/views/NotFound/index.tsx +++ b/packages/next/src/views/NotFound/index.tsx @@ -2,12 +2,12 @@ import type { I18n } from '@payloadcms/translations' import type { Metadata } from 'next' import type { AdminViewComponent, SanitizedConfig } from 'payload/types' -import { getNextI18n } from '@payloadcms/next/utilities' import { HydrateClientUser } from '@payloadcms/ui/elements/HydrateClientUser' import { DefaultTemplate } from '@payloadcms/ui/templates/Default' import React, { Fragment } from 'react' import { initPage } from '../../utilities/initPage.js' +import { getNextI18n } from '.././../utilities/getNextI18n.js' import { NotFoundClient } from './index.client.js' export const generatePageMetadata = async ({ diff --git a/packages/payload/.gitignore b/packages/payload/.gitignore index bf98465111..ffc0797a2d 100644 --- a/packages/payload/.gitignore +++ b/packages/payload/.gitignore @@ -20,3 +20,7 @@ /versions.js /operations.js /operations.d.ts +/node.js +/node.d.ts +/uploads.js +/uploads.d.ts diff --git a/packages/payload/node.d.ts b/packages/payload/node.d.ts deleted file mode 100644 index 58a3d77ef7..0000000000 --- a/packages/payload/node.d.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { importConfig, importWithoutClientFiles } from './dist/utilities/importWithoutClientFiles.js'; -//# sourceMappingURL=node.d.ts.map \ No newline at end of file diff --git a/packages/payload/node.js b/packages/payload/node.js deleted file mode 100644 index 9973c022ed..0000000000 --- a/packages/payload/node.js +++ /dev/null @@ -1,3 +0,0 @@ -export { importConfig, importWithoutClientFiles } from './dist/utilities/importWithoutClientFiles.js'; - -//# sourceMappingURL=node.js.map \ No newline at end of file diff --git a/packages/payload/uploads.d.ts b/packages/payload/uploads.d.ts deleted file mode 100644 index d741ff4ea0..0000000000 --- a/packages/payload/uploads.d.ts +++ /dev/null @@ -1,2 +0,0 @@ -export { getFileByPath } from './dist/uploads/getFileByPath.js'; -//# sourceMappingURL=uploads.d.ts.map diff --git a/packages/payload/uploads.js b/packages/payload/uploads.js deleted file mode 100644 index bae8119abf..0000000000 --- a/packages/payload/uploads.js +++ /dev/null @@ -1,3 +0,0 @@ -export { getFileByPath } from './dist/uploads/getFileByPath.js'; - -//# sourceMappingURL=uploads.js.map diff --git a/tsconfig.json b/tsconfig.json index 40316db156..f4411fe8cc 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -82,7 +82,7 @@ "./packages/ui/src/scss/app.scss" ], "@payloadcms/next/*": [ - "./packages/next/src/exports/*" + "./packages/next/src/*" ], "@payloadcms/next": [ "./packages/next/src/exports/*" @@ -161,4 +161,4 @@ ".next/types/**/*.ts", "scripts/**/*.ts" ] -} \ No newline at end of file +}