forked from redwoodjs/redwood
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' of github.com:redwoodjs/redwood into feature/prer…
…ender-p1 * 'main' of github.com:redwoodjs/redwood: v0.25.0 yarn rw prisma commands now show a little tip (redwoodjs#1772) FIx typo (redwoodjs#1779) Ensure all data is removed during the teardown step (redwoodjs#1714) [v0.25] revert to @prisma/cli; recreate yarn.lock (redwoodjs#1774) use prisma db push for test DB (redwoodjs#1768) Disable --version and -v for prisma alias. (redwoodjs#1767) Rebuild Prisma Client between upgrades (redwoodjs#1155) upgrade Prisma v2.16.1 (redwoodjs#1766) [v0.25] Remove warning if you scaffold a model with a relation (redwoodjs#1757) [v0.25] Scaffolded many-to-many relationship fixes (redwoodjs#1758) add forrest and kim-adeline; update all contribs (redwoodjs#1763) Run clean and then build the js. Fix: applying afterQuery in storybook mocks (redwoodjs#1740) restructure and update Deploy command and change Setup Deploy command template [breaking] (redwoodjs#1747) Fixes prisma command when path has spaces Make tutorial work with workspaces. Add "packages/*" to the template.
- Loading branch information
Showing
50 changed files
with
758 additions
and
420 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
{ | ||
"version": "0.24.0", | ||
"version": "0.25.0", | ||
"npmClient": "yarn", | ||
"useWorkspaces": true, | ||
"command": { | ||
|
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
{ | ||
"name": "@redwoodjs/auth", | ||
"version": "0.24.0", | ||
"version": "0.25.0", | ||
"files": [ | ||
"dist" | ||
], | ||
|
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,14 @@ | ||
export const command = 'deploy <command>' | ||
export const command = 'deploy <target>' | ||
export const description = 'Deploy your Redwood project' | ||
import terminalLink from 'terminal-link' | ||
|
||
export const builder = (yargs) => | ||
yargs | ||
.commandDir('./deploy', { recurse: true }) | ||
.commandDir('./deploy', { recurse: false }) | ||
.demandCommand() | ||
.epilogue( | ||
`Also see the ${terminalLink( | ||
'Redwood CLI Reference', | ||
'https://redwoodjs.com/reference/command-line-interface#deploy' | ||
)}` | ||
'https://redwoodjs.com/docs/cli-commands#deploy' | ||
)}\n` | ||
) |
File renamed without changes.
8 changes: 4 additions & 4 deletions
8
...ds/deploy/api/providers/aws_serverless.js → ...mmands/deploy/aws-providers/serverless.js
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
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
import execa from 'execa' | ||
import terminalLink from 'terminal-link' | ||
|
||
import { getPaths } from '@redwoodjs/internal' | ||
|
||
export const deployBuilder = (yargs) => { | ||
yargs | ||
.option('build', { | ||
description: 'Build for production', | ||
type: 'boolean', | ||
default: 'true', | ||
}) | ||
.option('prisma', { | ||
description: 'Apply database migrations', | ||
type: 'boolean', | ||
default: 'true', | ||
}) | ||
.option('data-migrate', { | ||
description: 'Migrate the data in your database', | ||
type: 'boolean', | ||
default: 'true', | ||
alias: 'dm', | ||
}) | ||
.epilogue( | ||
`For more commands, options, and examples, see ${terminalLink( | ||
'Redwood CLI Reference', | ||
'https://redwoodjs.com/docs/cli-commands#deploy' | ||
)}` | ||
) | ||
} | ||
|
||
export const deployHandler = async ({ build, prisma, dm: dataMigrate }) => { | ||
const paths = getPaths() | ||
|
||
let commandSet = [] | ||
if (build) { | ||
commandSet.push('yarn rw build') | ||
} | ||
if (prisma) { | ||
commandSet.push('yarn rw prisma migrate deploy') | ||
} | ||
if (dataMigrate) { | ||
commandSet.push('yarn rw dataMigrate up') | ||
} | ||
|
||
execa(commandSet.join(' && '), { | ||
shell: true, | ||
stdio: 'inherit', | ||
cwd: paths.base, | ||
extendEnv: true, | ||
cleanup: true, | ||
}) | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import { deployBuilder, deployHandler } from './helpers/helpers' | ||
|
||
export const command = 'netlify [...commands]' | ||
export const description = 'Build command for Netlify deploy' | ||
|
||
export const builder = (yargs) => deployBuilder(yargs) | ||
|
||
export const handler = deployHandler |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import { deployBuilder, deployHandler } from './helpers/helpers' | ||
|
||
export const command = 'vercel [...commands]' | ||
export const description = 'Build command for Vercel deploy' | ||
|
||
export const builder = (yargs) => deployBuilder(yargs) | ||
|
||
export const handler = deployHandler |
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
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
Oops, something went wrong.