Skip to content

Commit

Permalink
Merge remote-tracking branch 'upstream/canary' into canary
Browse files Browse the repository at this point in the history
  • Loading branch information
areai51 committed Feb 8, 2020
2 parents e5468ab + cbb9c2c commit eef5ece
Show file tree
Hide file tree
Showing 1,122 changed files with 22,940 additions and 13,510 deletions.
217 changes: 0 additions & 217 deletions .circleci/config.yml

This file was deleted.

10 changes: 10 additions & 0 deletions .eslintrc.json
Expand Up @@ -21,6 +21,7 @@
}
},
"overrides": [
{ "files": ["**/__tests__/**"], "env": { "jest": true } },
{
"files": ["**/*.ts", "**/*.tsx"],
"parser": "@typescript-eslint/parser",
Expand Down Expand Up @@ -61,6 +62,15 @@
"ignoreRestSiblings": true
}
],
"no-unused-expressions": "off",
"@typescript-eslint/no-unused-expressions": [
"error",
{
"allowShortCircuit": true,
"allowTernary": true,
"allowTaggedTemplates": true
}
],
"no-useless-constructor": "off",
"@typescript-eslint/no-useless-constructor": "warn"
}
Expand Down
111 changes: 111 additions & 0 deletions .github/workflows/build_test_deploy.yml
@@ -0,0 +1,111 @@
on:
push:
branches: [canary]
pull_request:
types: [opened, synchronize]

name: Build, test, and deploy

jobs:
build:
runs-on: ubuntu-latest
env:
NEXT_TELEMETRY_DISABLED: 1
steps:
- uses: actions/checkout@v2
- run: git fetch --depth=1 origin +refs/tags/*:refs/tags/*
- run: yarn install --frozen-lockfile --check-files
- uses: actions/cache@v1
id: cache-build
with:
path: '.'
key: ${{ github.sha }}

lint:
runs-on: ubuntu-latest
needs: build
steps:
- uses: actions/cache@v1
id: restore-build
with:
path: '.'
key: ${{ github.sha }}
- run: yarn lint

testAll:
name: Test All
runs-on: ubuntu-latest
needs: build
env:
NEXT_TELEMETRY_DISABLED: 1
HEADLESS: true
strategy:
fail-fast: false
matrix:
group: [1, 2, 3, 4, 5, 6]
steps:
- uses: actions/cache@v1
id: restore-build
with:
path: '.'
key: ${{ github.sha }}

# TODO: remove after we fix watchpack watching too much
- run: echo fs.inotify.max_user_watches=524288 | sudo tee -a /etc/sysctl.conf && sudo sysctl -p

- run: node run-tests.js --timings -g ${{ matrix.group }}/6 -c 3

testsPass:
name: thank you, next
runs-on: ubuntu-latest
needs: [lint, testAll]
steps:
- run: exit 0

testFirefox:
name: Test Firefox (production)
runs-on: ubuntu-latest
needs: build
env:
NEXT_TELEMETRY_DISABLED: 1
HEADLESS: true
steps:
- uses: actions/cache@v1
id: restore-build
with:
path: '.'
key: ${{ github.sha }}
- run: yarn testfirefox --forceExit test/integration/production/

testSafari:
name: Test Safari (production)
runs-on: ubuntu-latest
needs: build
env:
NEXT_TELEMETRY_DISABLED: 1
BROWSERSTACK: true
SKIP_LOCAL_SELENIUM_SERVER: true
BROWSERSTACK_USERNAME: ${{ secrets.BROWSERSTACK_USERNAME }}
BROWSERSTACK_ACCESS_KEY: ${{ secrets.BROWSERSTACK_ACCESS_KEY }}
steps:
- uses: actions/cache@v1
id: restore-build
with:
path: '.'
key: ${{ github.sha }}
- run: '[[ -z "$BROWSERSTACK_ACCESS_KEY" ]] && echo "Skipping for PR" || yarn testsafari --forceExit test/integration/production/'

publishRelease:
name: Potentially publish release
runs-on: ubuntu-latest
needs: [testsPass]
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
steps:
- uses: actions/cache@v1
id: restore-build
with:
path: '.'
key: ${{ github.sha }}

- run: ./publish-release.sh
@@ -1,11 +1,14 @@
on: pull_request
name: Generate pull request stats
on:
pull_request:
types: [opened, synchronize]

name: Generate Pull Request Stats

jobs:
prStats:
stats:
name: PR Stats
runs-on: ubuntu-latest
steps:
- name: PR Stats
uses: zeit/next-stats-action@master
- uses: zeit/next-stats-action@master
env:
COMMENT_ENDPOINT: https://next-stats.jjsweb.site/api/comment
@@ -1,5 +1,7 @@
on: release
name: Generate release stats

name: Generate Release Stats

jobs:
prStats:
name: PR Stats
Expand Down

0 comments on commit eef5ece

Please sign in to comment.