fix: pagination bar #263
Workflow file for this run
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
name: Next CI | |
on: | |
push: | |
branches: | |
- "*" | |
pull_request: | |
branches: | |
- "*" | |
workflow_dispatch: | |
env: | |
node_version: "20.10.0" | |
python_version: "3.10" | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: ${{env.node_version}} | |
- run: npm install | |
- run: | | |
npm run lint | |
npm run prettier:lint | |
build: | |
runs-on: ubuntu-latest | |
env: | |
NODE_ENV: "production" | |
CI: true | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: ${{env.node_version}} | |
- uses: actions/cache@v4 | |
with: | |
# See here for caching with `yarn` https://github.com/actions/cache/blob/main/examples.md#node---yarn or you can leverage caching with actions/setup-node https://github.com/actions/setup-node | |
path: | | |
~/.npm | |
${{ github.workspace }}/.next/cache | |
# Generate a new cache whenever packages or source files change. | |
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}-${{ hashFiles('**/*.js', '**/*.jsx', '**/*.ts', '**/*.tsx') }} | |
# If source files changed but packages didn't, rebuild from a prior cache. | |
restore-keys: | | |
${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}- | |
- name: remove files for building production | |
run: | | |
rm cypress.config.ts | |
rm -r cypress/ | |
rm -r scripts | |
- name: create .env.local file | |
run: | | |
touch .env.local | |
echo NEXT_PUBLIC_AWS_REGION=${{ secrets.NEXT_PUBLIC_AWS_REGION }} >> .env.local | |
echo NEXT_PUBLIC_AWS_COGNITO_USERPOOL_ID=${{ secrets.NEXT_PUBLIC_AWS_COGNITO_USERPOOL_ID }} >> .env.local | |
echo NEXT_PUBLIC_AWS_COGNITO_USERPOOL_CLIENT_ID=${{ secrets.NEXT_PUBLIC_AWS_COGNITO_USERPOOL_CLIENT_ID }} >> .env.local | |
echo NEXT_PUBLIC_AWS_ACCESS_KEY_ID=${{ secrets.NEXT_PUBLIC_AWS_ACCESS_KEY_ID }} >> .env.local | |
echo NEXT_PUBLIC_AWS_SECRET_ACCESS_KEY=${{ secrets.NEXT_PUBLIC_AWS_SECRET_ACCESS_KEY }} >> .env.local | |
echo NEXT_PUBLIC_ENV_NAME=${{ secrets.NEXT_PUBLIC_ENV_NAME }} >> .env.local | |
echo NEXT_PUBLIC_COGNITO_OPENID_CONF_URI=${{ secrets.NEXT_PUBLIC_COGNITO_OPENID_CONF_URI }} >> .env.local | |
echo NEXT_PUBLIC_BACKEND_BASE_URL=${{ secrets.NEXT_PUBLIC_BACKEND_BASE_URL }} >> .env.local | |
echo NEXT_PUBLIC_DOMAIN_NAME=${{ secrets.NEXT_PUBLIC_DOMAIN_NAME }} >> .env.local | |
echo NEXT_PUBLIC_ADMIN_EMAIL=${{ secrets.NEXT_PUBLIC_ADMIN_EMAIL }} >> .env.local | |
echo NEXT_PUBLIC_AWS_SAGEMAKER_DOMAIN_ID=${{ secrets.NEXT_PUBLIC_AWS_SAGEMAKER_DOMAIN_ID }} >> .env.local | |
echo NEXT_PUBLIC_AWS_SAGEMAKER_USER_NAME=${{ secrets.NEXT_PUBLIC_AWS_SAGEMAKER_USER_NAME }} >> .env.local | |
# - uses: actions/upload-artifact@master | |
# with: | |
# name: env-file | |
# path: .env.local | |
- run: npm ci | |
- run: npm run build |