Skip to content

Commit

Permalink
Merge branch 'dt-fastify-config-plugins' of https://github.com/dthyre…
Browse files Browse the repository at this point in the history
…sson/redwood into dt-fastify-config-plugins

* 'dt-fastify-config-plugins' of https://github.com/dthyresson/redwood:
  fix: temporarily disable telemetry on windows (redwoodjs#5899)
  fix(deps): update dependency dotenv-webpack to v7.1.1 (redwoodjs#5909)
  fix(deps): update dependency dotenv-defaults to v5.0.2 (redwoodjs#5908)
  fix(deps): update dependency webpack-dev-server to v4.9.3 (redwoodjs#5906)
  fix(deps): update dependency core-js to v3.23.4 (redwoodjs#5905)
  Fix single-character typo (redwoodjs#5904)
  • Loading branch information
dac09 committed Jul 12, 2022
2 parents e442dd3 + ccc20ed commit abcb3c7
Show file tree
Hide file tree
Showing 21 changed files with 77 additions and 68 deletions.
2 changes: 1 addition & 1 deletion docs/docs/deploy/serverless.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ description: Deploy to AWS with Serverless Framework
Yes, the name is confusing, but Serverless provides a very interesting option—deploy to your own cloud service account and skip the middleman entirely! By default, Serverless just orchestrates starting up services in your cloud provider of choice and pushing your code up to them. Any bill you receive is from your hosting provider (although many offer a generous free tier). You can optionally use the [Serverless Dashboard](https://www.serverless.com/dashboard/) to monitor your deploys and setup CI/CD to automatically deploy when pushing to your repo of choice. If you don't setup CI/CD you actually deploy from your development machine (or another designated machine you've setup to do the deployment).

Currently we default to deploying to AWS. We'd like to add more providers in the future but need help from the community in figuring our what services are equivalent to the ones we're using in AWS (Lambda for the api-side and S3/CloudFront for the web-side).
Currently we default to deploying to AWS. We'd like to add more providers in the future but need help from the community in figuring out what services are equivalent to the ones we're using in AWS (Lambda for the api-side and S3/CloudFront for the web-side).

We'll handle most of the deployment commands for you, you just need an [AWS account](https://www.serverless.com/framework/docs/providers/aws/guide/credentials#sign-up-for-an-aws-account) and your [access/secret keys](https://www.serverless.com/framework/docs/providers/aws/guide/credentials#create-an-iam-user-and-access-key) before we begin.

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@
"babel-plugin-auto-import": "1.1.0",
"babel-plugin-remove-code": "0.0.6",
"boxen": "5.1.2",
"core-js": "3.23.3",
"core-js": "3.23.4",
"cypress": "9.7.0",
"cypress-wait-until": "1.7.2",
"eslint": "8.18.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/api-server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"ansi-colors": "4.1.3",
"chalk": "4.1.2",
"chokidar": "3.5.3",
"core-js": "3.23.3",
"core-js": "3.23.4",
"fast-json-parse": "1.0.3",
"fastify": "3.29.0",
"fastify-raw-body": "3.2.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/api/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"dependencies": {
"@babel/runtime-corejs3": "7.16.7",
"@prisma/client": "3.15.2",
"core-js": "3.23.3",
"core-js": "3.23.4",
"cross-undici-fetch": "0.4.11",
"crypto-js": "4.1.1",
"humanize-string": "2.1.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
},
"dependencies": {
"@babel/runtime-corejs3": "7.16.7",
"core-js": "3.23.3"
"core-js": "3.23.4"
},
"devDependencies": {
"@auth0/auth0-spa-js": "1.22.1",
Expand Down
4 changes: 2 additions & 2 deletions packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,10 @@
"chalk": "4.1.2",
"concurrently": "7.2.2",
"configstore": "3.1.5",
"core-js": "3.23.3",
"core-js": "3.23.4",
"cross-env": "7.0.3",
"decamelize": "5.0.0",
"dotenv-defaults": "5.0.0",
"dotenv-defaults": "5.0.2",
"envinfo": "7.8.1",
"execa": "5.1.1",
"fast-glob": "3.2.11",
Expand Down
2 changes: 1 addition & 1 deletion packages/codemods/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"@babel/plugin-transform-typescript": "7.16.7",
"@babel/runtime-corejs3": "7.16.7",
"@vscode/ripgrep": "1.14.2",
"core-js": "3.23.3",
"core-js": "3.23.4",
"cross-undici-fetch": "0.4.11",
"deepmerge": "4.2.2",
"execa": "5.1.1",
Expand Down
6 changes: 3 additions & 3 deletions packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,10 @@
"babel-plugin-module-resolver": "4.1.0",
"babel-timing": "0.9.1",
"copy-webpack-plugin": "11.0.0",
"core-js": "3.23.3",
"core-js": "3.23.4",
"css-loader": "6.7.1",
"css-minimizer-webpack-plugin": "4.0.0",
"dotenv-webpack": "7.1.0",
"dotenv-webpack": "7.1.1",
"esbuild": "0.14.49",
"esbuild-loader": "2.19.0",
"fast-glob": "3.2.11",
Expand All @@ -83,7 +83,7 @@
"webpack": "5.73.0",
"webpack-bundle-analyzer": "4.5.0",
"webpack-cli": "4.10.0",
"webpack-dev-server": "4.9.2",
"webpack-dev-server": "4.9.3",
"webpack-manifest-plugin": "5.0.0",
"webpack-merge": "5.8.0",
"webpack-retry-chunk-load-plugin": "3.1.1"
Expand Down
2 changes: 1 addition & 1 deletion packages/create-redwood-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"@redwoodjs/telemetry": "2.0.0",
"chalk": "4.1.2",
"check-node-version": "4.2.1",
"core-js": "3.23.3",
"core-js": "3.23.4",
"execa": "5.1.1",
"fs-extra": "10.1.0",
"listr": "0.14.3",
Expand Down
2 changes: 1 addition & 1 deletion packages/forms/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
},
"dependencies": {
"@babel/runtime-corejs3": "7.16.7",
"core-js": "3.23.3",
"core-js": "3.23.4",
"pascalcase": "1.0.0",
"react-hook-form": "7.33.1"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/graphql-server/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"@graphql-yoga/common": "2.7.0",
"@prisma/client": "3.15.2",
"@redwoodjs/api": "2.0.0",
"core-js": "3.23.3",
"core-js": "3.23.4",
"cross-undici-fetch": "0.4.11",
"graphql": "16.5.0",
"graphql-scalars": "1.17.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/internal/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
"babel-plugin-graphql-tag": "3.3.0",
"babel-plugin-polyfill-corejs3": "0.5.0",
"chalk": "4.1.2",
"core-js": "3.23.3",
"core-js": "3.23.4",
"deepmerge": "4.2.2",
"esbuild": "0.14.49",
"fast-glob": "3.2.11",
Expand Down
2 changes: 1 addition & 1 deletion packages/prerender/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"@redwoodjs/web": "2.0.0",
"babel-plugin-ignore-html-and-css-imports": "0.1.0",
"cheerio": "1.0.0-rc.11",
"core-js": "3.23.3",
"core-js": "3.23.4",
"cross-undici-fetch": "0.4.11",
"mime-types": "2.1.35"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/record/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"dependencies": {
"@babel/runtime-corejs3": "7.16.7",
"@prisma/client": "3.15.2",
"core-js": "3.23.3"
"core-js": "3.23.4"
},
"devDependencies": {
"@babel/cli": "7.16.7",
Expand Down
2 changes: 1 addition & 1 deletion packages/router/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"@babel/runtime-corejs3": "7.16.7",
"@reach/skip-nav": "0.16.0",
"@redwoodjs/auth": "2.0.0",
"core-js": "3.23.3",
"core-js": "3.23.4",
"lodash.isequal": "4.5.0"
},
"devDependencies": {
Expand Down
4 changes: 2 additions & 2 deletions packages/structure/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@
"@redwoodjs/internal": "2.0.0",
"@types/line-column": "1.0.0",
"camelcase": "6.3.0",
"core-js": "3.23.3",
"core-js": "3.23.4",
"deepmerge": "4.2.2",
"dotenv-defaults": "5.0.0",
"dotenv-defaults": "5.0.2",
"enquirer": "2.3.6",
"findup-sync": "5.0.0",
"graphql": "16.5.0",
Expand Down
2 changes: 1 addition & 1 deletion packages/telemetry/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"@redwoodjs/internal": "2.0.0",
"@redwoodjs/structure": "2.0.0",
"ci-info": "3.3.2",
"core-js": "3.23.3",
"core-js": "3.23.4",
"cross-undici-fetch": "0.4.11",
"envinfo": "7.8.1",
"systeminformation": "5.11.21",
Expand Down
13 changes: 11 additions & 2 deletions packages/telemetry/src/telemetry.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { spawn } from 'child_process'
import os from 'node:os'
import path from 'path'

import { getPaths } from '@redwoodjs/internal'
Expand Down Expand Up @@ -43,8 +44,14 @@ export const timedTelemetry = async (
return result
}

// Returns 'Windows_NT' on Windows.
// See https://nodejs.org/docs/latest-v12.x/api/os.html#os_os_type.
const isWindows = os.type() === 'Windows_NT'

export const errorTelemetry = async (argv: Array<string>, error: any) => {
if (process.env.REDWOOD_DISABLE_TELEMETRY) {
// FIXME: on Windows, cmd opens and closes a few times.
// See https://github.com/redwoodjs/redwood/issues/5728.
if (isWindows || process.env.REDWOOD_DISABLE_TELEMETRY) {
return
}

Expand All @@ -53,7 +60,9 @@ export const errorTelemetry = async (argv: Array<string>, error: any) => {

// used as yargs middleware when any command is invoked
export const telemetryMiddleware = async () => {
if (process.env.REDWOOD_DISABLE_TELEMETRY) {
// FIXME: on Windows, cmd opens and closes a few times.
// See https://github.com/redwoodjs/redwood/issues/5728.
if (isWindows || process.env.REDWOOD_DISABLE_TELEMETRY) {
return
}

Expand Down
2 changes: 1 addition & 1 deletion packages/testing/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"@types/webpack": "5.28.0",
"babel-jest": "27.5.1",
"babel-plugin-inline-react-svg": "2.0.1",
"core-js": "3.23.3",
"core-js": "3.23.4",
"jest": "27.5.1",
"jest-watch-typeahead": "1.1.0",
"msw": "0.40.2",
Expand Down
2 changes: 1 addition & 1 deletion packages/web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
"@apollo/client": "3.6.9",
"@babel/runtime-corejs3": "7.16.7",
"@redwoodjs/auth": "2.0.0",
"core-js": "3.23.3",
"core-js": "3.23.4",
"graphql": "16.5.0",
"graphql-tag": "2.12.6",
"react-helmet-async": "1.3.0",
Expand Down
Loading

0 comments on commit abcb3c7

Please sign in to comment.