Compare commits

..

25 Commits

Author SHA1 Message Date
Steven
6dfefc2fe4 Publish Stable
- gatsby-plugin-now@1.2.5
 - now@16.5.2
 - @now/node@1.1.2
 - @now/static-build@0.12.2
2019-11-12 18:52:28 -05:00
Steven
9ba8a8454c Bump versions 2019-11-12 18:51:32 -05:00
Steven
9c72839bfa Empty commit 2019-11-12 18:48:26 -05:00
Steven
2e24c92799 Publish Canary
- gatsby-plugin-now@1.2.4-canary.0
 - @now/node@1.1.1-canary.0
 - @now/static-build@0.12.1-canary.0
2019-11-12 18:18:17 -05:00
Andy
fa98c8aeeb Revert "[now-static-build] Inject gatsby-plugin-now in Gatsby deployments (#3182)" (#3303)
This reverts the following gatsby changes:

- Reverts #3182
- Reverts #3260
- Reverts #3212
2019-11-12 23:13:39 +00:00
Steven
f92e3496b1 [now-node] Bump now-node-bridge (#3304)
A trivial change to follow up to #3300 so that the latest `@now/node-bridge` is bundled with `ncc`.
2019-11-12 22:37:49 +00:00
Steven
0ceea76aa4 Publish Canary
- now@16.5.1-canary.0
 - @now/node-bridge@1.2.7-canary.0
2019-11-12 14:57:22 -05:00
Steven
897d11a1e1 [now-node] Disable default node timeout (#3300)
Node had a default [timeout](https://nodejs.org/api/http.html#http_server_timeout) of 2 minutes until Node 13.x so we'll need to manually disable the timeout so that the `maxDuration` config works properly.
2019-11-12 19:54:05 +00:00
Andy Bitz
8ed59fcdd3 Publish Stable
- gatsby-plugin-now@1.2.3
 - @now/build-utils@1.0.0
 - @now/cgi@1.0.0
 - now@16.5.0
 - now-client@5.2.3
 - @now/go@1.0.0
 - @now/node-bridge@1.2.6
 - @now/node@1.1.0
 - @now/python@1.0.0
 - @now/routing-utils@1.3.3
 - @now/ruby@1.0.0
 - @now/static-build@0.12.0
2019-11-12 15:55:59 +01:00
Andy
7f211cc7fc [all] Set the versions to stable (#3297) 2019-11-12 15:52:16 +01:00
Andy Bitz
c511147c7c Publish Canary
- @now/build-utils@1.0.0-canary.23
 - now@16.1.4-canary.43
 - now-client@5.1.1-canary.18
 - @now/node@1.0.0-canary.17
2019-11-11 23:33:18 +01:00
Nathan Rajlich
2f7f965188 [now-cli] Update execa to v3.2.0 (#3292)
* [now-cli] Update `execa` to v3.2.0

Also requires updating TypeScript to v3.4+
(See: https://github.com/sindresorhus/execa/issues/336)

* Fix tests: code -> exitCode

* code -> exitCode

* More .code to .exitCode

* Update `@zeit/fun` to v0.10.3
2019-11-11 14:21:27 -08:00
Andy
24da26e7cf [@now/build-utils] Add support for includeFiles and excludeFiles to Functions (#3285)
Add support for `includeFiles` and `excludeFiles` to Functions.

[PRODUCT-27]

[PRODUCT-27]: https://zeit.atlassian.net/browse/PRODUCT-27
2019-11-11 22:17:59 +00:00
Andy
f8f9d656e8 [@now/node] Configure helpers and handler with env variables (#3286)
Allow to configure helpers and handler with env variables.

[PRODUCT-27]

[PRODUCT-27]: https://zeit.atlassian.net/browse/PRODUCT-27
2019-11-11 21:24:28 +00:00
Steven
b357f3055d [docs] Cleanup canary links, use master instead (#3291)
Follow up to #3287
2019-11-11 19:54:40 +00:00
Max
f9c1f519f4 [now-client] Clean up fetch headers (#3290)
Reopen of #3255
2019-11-11 19:31:20 +00:00
Steven
057f9f7045 Publish Canary
- now@16.1.4-canary.42
 - @now/node@1.0.0-canary.16
 - @now/ruby@0.1.5-canary.8
2019-11-11 13:53:20 -05:00
Steven
58ec38437d [now-node] Fix TS version selection (#3289)
Previously, the `typescript` dependency resolution was using the package.json beside the `now.json` base directory.

This PR changes the behavior to start looking for package.json in the entrypoint directory.

Fixes #3258
2019-11-11 18:45:39 +00:00
Steven
2964bf50e0 [now-ruby] Fix rails test (#3288)
This test was failing for the last week.

The issue was fixed in the build environment. The root cause was [ruby-build](https://github.com/rbenv/ruby-build) which is used to install the version of Ruby used in `@now/ruby`. It started using an older (possible broken) version of `bundler`. I pinned `ruby-build` to a previous version so that deployments continue working.

So now we can enable the Rails test again (which uses nokogiri).

Fixes #3246
Closes #3274
2019-11-11 16:34:20 +00:00
Leo Lamprecht
c9572c352a Adjust commands for creating releases (#3287)
* Adjust commands for creating releases

* Update package.json

Co-Authored-By: Steven <steven@ceriously.com>

* Update package.json

Co-Authored-By: Steven <steven@ceriously.com>

* Adjusted log line

* Deleted diff.js

* Remove script

* Fix run.js to use master
2019-11-11 10:50:04 -05:00
Andy
b69f176143 [now-cli] Enable Runtime tests (#3284)
Enable Runtime tests, since a new version of the `now-php` package was released.
2019-11-11 12:33:54 +00:00
Leo Lamprecht
484dcd5dc1 Publish
- now@16.1.4-canary.41
2019-11-11 12:59:08 +01:00
Leo Lamprecht
a3412113b7 Trigger publish 2019-11-11 12:58:49 +01:00
Leo Lamprecht
693043bc27 Fixed dependencies 2019-11-11 12:57:44 +01:00
Leo Lamprecht
82a5bafb42 Fixed dependencies (#3283) 2019-11-11 12:51:44 +01:00
68 changed files with 957 additions and 905 deletions

View File

@@ -147,7 +147,7 @@ The exported functions [`analyze`](#analyze), [`build`](#build), and [`prepareCa
## Examples
Check out our [Node.js Runtime](https://github.com/zeit/now/tree/canary/packages/now-node), [Go Runtime](https://github.com/zeit/now/tree/canary/packages/now-go), [Python Runtime](https://github.com/zeit/now/tree/canary/packages/now-python) or [Ruby Runtime](https://github.com/zeit/now/tree/canary/packages/now-ruby) for examples of how to build one.
Check out our [Node.js Runtime](https://github.com/zeit/now/tree/master/packages/now-node), [Go Runtime](https://github.com/zeit/now/tree/master/packages/now-go), [Python Runtime](https://github.com/zeit/now/tree/master/packages/now-python) or [Ruby Runtime](https://github.com/zeit/now/tree/master/packages/now-ruby) for examples of how to build one.
## Technical Details

View File

@@ -3,8 +3,6 @@
[![Build Status](https://badgen.net/circleci/github/zeit/now/master)](https://circleci.com/gh/zeit/workflows/now/tree/master)
[![Join the community on Spectrum](https://withspectrum.github.io/badge/badge.svg)](https://spectrum.chat/zeit)
**NOTE**: The [canary](https://github.com/zeit/now/tree/canary) branch is under heavy development the stable release branch is [master](https://github.com/zeit/now/tree/master).
## Usage
To install the latest version of Now CLI, visit [zeit.co/download](https://zeit.co/download) or run this command:

View File

@@ -1,25 +0,0 @@
# Versioning
Builders are released to two different channels.
## Channels
| Channel | Git Branch | npm dist-tag | use example |
| ------- | ------------------------------------------------------------- | ------------ | ------------------ |
| Canary | [canary](https://github.com/zeit/now/commits/canary) | `@canary` | `@now/node@canary` |
| Stable | [master](https://github.com/zeit/now/commits/master) | `@latest` | `@now/node@latest` |
All PRs are submitted to the `canary` branch. Once a PR is merged into the `canary` branch, it should be published to npm immediately using the Canary Channel.
## Version Selection
Since Builders are published to [npmjs.com](https://npmjs.com), this makes versioning works the same for Builders as it does for any npm package. The `use` statement in [now.json](https://zeit.co/docs/v2/advanced/configuration#builds) has a similar syntax to `npm install`.
The following are valid examples [@now/node](https://www.npmjs.com/package/@now/node?activeTab=versions):
- `@now/node`
- `@now/node@0.7.3`
- `@now/node@canary`
- `@now/node@0.7.2-canary.2`
We always recommend using the latest version by leaving off the dist-tag suffix, `@now/node` for example.

View File

@@ -4,7 +4,7 @@ const commit = execSync('git log --pretty=format:"%s %H"')
.toString()
.trim()
.split('\n')
.find(line => line.startsWith('Publish '))
.find(line => line.startsWith('Publish Stable '))
.split(' ')
.pop();

36
diff.js
View File

@@ -1,36 +0,0 @@
const { execSync } = require('child_process');
const { join } = require('path');
const { tmpdir } = require('os');
const { mkdirSync, writeFileSync } = require('fs');
function getCommits(count) {
return execSync('git log --pretty=format:"%s [%an]"')
.toString()
.trim()
.split('\n')
.slice(0, count)
.filter(line => !line.startsWith('Publish '))
.join('\n');
}
function main(count = '100') {
console.log(`Generating diff using last ${count} commits...`);
const randomTmpId = Math.random().toString().slice(2);
const dir = join(tmpdir(), 'now-diff' + randomTmpId);
mkdirSync(dir);
execSync('git checkout canary && git pull');
const canary = getCommits(count);
execSync('git checkout master && git pull');
const master = getCommits(count);
writeFileSync(join(dir, 'log.txt'), '# canary\n' + canary);
execSync('git init && git add -A && git commit -m "init"', { cwd: dir });
writeFileSync(join(dir, 'log.txt'), '# master\n' + master);
console.log(`Done generating diff. Run the following:`);
console.log(`cd ${dir}`);
console.log('Then use `git diff` or `git difftool` to view the differences.');
}
main(process.argv[2]);

View File

@@ -30,10 +30,9 @@
"scripts": {
"lerna": "lerna",
"bootstrap": "lerna bootstrap",
"publish-stable": "git checkout master && git pull && lerna version --exact",
"publish-canary": "git checkout canary && git pull && lerna version prerelease --preid canary --exact",
"publish-stable": "git pull && lerna version --message 'Publish Stable' --exact",
"publish-canary": "git pull && lerna version prerelease --preid canary --message 'Publish Canary' --exact",
"publish-from-github": "./.circleci/publish.sh",
"diff": "node diff.js",
"changelog": "node changelog.js",
"build": "node run.js build all",
"test-lint": "node run.js test-lint",

View File

@@ -6,6 +6,10 @@ const REDIRECT_FILE_NAME = '__now_routes_g4t5bY.json';
exports.onPostBuild = async ({ store }) => {
const { redirects, program } = store.getState();
if (!redirects.length === 0) {
return;
}
const routes = [{ handle: 'filesystem' }];
for (const redirect of redirects) {
@@ -22,30 +26,8 @@ exports.onPostBuild = async ({ store }) => {
}
}
// we implement gatsby's recommendations
// https://www.gatsbyjs.org/docs/caching/
const finalRoutes = [
{
src: '^/static/(.*)$',
headers: { 'cache-control': 'public,max-age=31536000,immutable' },
continue: true,
},
{
src: '^/.*\\.(js|css)$',
headers: { 'cache-control': 'public,max-age=31536000,immutable' },
continue: true,
},
{
src: '^/(sw\\.js|app-data\\.json|.*\\.html|page-data/.*)$',
headers: { 'cache-control': 'public,max-age=0,must-revalidate' },
continue: true,
},
...routes,
{ src: '.*', status: 404, dest: '/404.html' },
];
await writeFile(
path.join(program.directory, 'public', REDIRECT_FILE_NAME),
JSON.stringify(finalRoutes)
JSON.stringify(routes)
);
};

View File

@@ -1,6 +1,6 @@
{
"name": "gatsby-plugin-now",
"version": "1.2.1-canary.5",
"version": "1.2.5",
"main": "index.js",
"license": "MIT",
"homepage": "https://zeit.co/guides/deploying-gatsby-with-now",

View File

@@ -1,7 +1,24 @@
# gatsby-plugin-now
⚠️ The use of this plugin is deprecated. ZEIT Now supports Gatsby Redirects out-of-the-box and does not require the use a plugin.
---
This plugin generates [Now Routes](https://zeit.co/docs/v2/advanced/routes) for [redirects](https://www.gatsbyjs.org/docs/actions/#createRedirect) you configured for to your Gatsby project.
### Usage
1. Install the plugin:
```
npm install gatsby-plugin-now --save-dev
```
2. Add it to the configuration file:
```
// gatsby-config.js
module.exports = {
plugins: [
'gatsby-plugin-now'
]
}
```
3. [Deploy your project to ZEIT Now](https://www.gatsbyjs.org/docs/deploying-to-zeit-now/)

View File

@@ -2,27 +2,6 @@
exports[`test generated now routes 1`] = `
Array [
Object {
"continue": true,
"headers": Object {
"cache-control": "public,max-age=31536000,immutable",
},
"src": "^/static/(.*)$",
},
Object {
"continue": true,
"headers": Object {
"cache-control": "public,max-age=31536000,immutable",
},
"src": "^/.*\\\\.(js|css)$",
},
Object {
"continue": true,
"headers": Object {
"cache-control": "public,max-age=0,must-revalidate",
},
"src": "^/(sw\\\\.js|app-data\\\\.json|.*\\\\.html|page-data/.*)$",
},
Object {
"headers": Object {
"Location": "/",
@@ -103,10 +82,5 @@ Array [
"src": "/randorect",
"status": 302,
},
Object {
"dest": "/404.html",
"src": ".*",
"status": 404,
},
]
`;

View File

@@ -1,10 +1,10 @@
{
"name": "@now/build-utils",
"version": "1.0.0-canary.22",
"version": "1.0.0",
"license": "MIT",
"main": "./dist/index.js",
"types": "./dist/index.d.js",
"homepage": "https://github.com/zeit/now/blob/canary/DEVELOPING_A_RUNTIME.md",
"homepage": "https://github.com/zeit/now/blob/master/DEVELOPING_A_RUNTIME.md",
"repository": {
"type": "git",
"url": "https://github.com/zeit/now.git",

View File

@@ -83,6 +83,11 @@ function getApiFunctionBuilder(
});
}
const { includeFiles, excludeFiles } = fn;
if (includeFiles) Object.assign(config, { includeFiles });
if (excludeFiles) Object.assign(config, { excludeFiles });
return use ? { use, src, config } : prevBuilder;
}
@@ -308,6 +313,24 @@ function validateFunctions(files: string[], { functions = {} }: Options) {
};
}
}
if (func.includeFiles !== undefined) {
if (typeof func.includeFiles !== 'string') {
return {
code: 'invalid_function_property',
message: `The property \`includeFiles\` must be a string.`
};
}
}
if (func.excludeFiles !== undefined) {
if (typeof func.excludeFiles !== 'string') {
return {
code: 'invalid_function_property',
message: `The property \`excludeFiles\` must be a string.`
};
}
}
}
return null;

View File

@@ -316,5 +316,7 @@ export interface BuilderFunctions {
memory?: number;
maxDuration?: number;
runtime?: string;
includeFiles?: string;
excludeFiles?: string;
};
}

View File

@@ -634,6 +634,85 @@ describe('Test `detectBuilders`', () => {
expect(errors).toBeDefined();
expect(errors[0].code).toBe('invalid_function_runtime');
});
it('Must include includeFiles config property', async () => {
const functions = {
'api/test.js': { includeFiles: 'text/include.txt' }
}
const files = ['api/test.js'];
const { builders, errors } = await detectBuilders(files, null, { functions });
expect(errors).toBe(null);
expect(builders).not.toBe(null);
expect(builders[0].use).toBe('@now/node');
expect(builders[0].config).toMatchObject({
functions,
zeroConfig: true,
includeFiles: 'text/include.txt'
});
});
it('Must include excludeFiles config property', async () => {
const functions = {
'api/test.js': { excludeFiles: 'text/exclude.txt' }
}
const files = ['api/test.js'];
const { builders, errors } = await detectBuilders(files, null, { functions });
expect(errors).toBe(null);
expect(builders).not.toBe(null);
expect(builders[0].use).toBe('@now/node');
expect(builders[0].config).toMatchObject({
functions,
zeroConfig: true,
excludeFiles: 'text/exclude.txt'
});
});
it('Must include excludeFiles and includeFiles config property', async () => {
const functions = {
'api/test.js': { excludeFiles: 'text/exclude.txt', includeFiles: 'text/include.txt' }
}
const files = ['api/test.js'];
const { builders, errors } = await detectBuilders(files, null, { functions });
expect(errors).toBe(null);
expect(builders).not.toBe(null);
expect(builders[0].use).toBe('@now/node');
expect(builders[0].config).toMatchObject({
functions,
zeroConfig: true,
excludeFiles: 'text/exclude.txt',
includeFiles: 'text/include.txt'
});
});
it('Must fail for includeFiles config property', async () => {
const functions = {
'api/test.js': { includeFiles: { test: 1 } }
}
const files = ['api/test.js'];
const { errors } = await detectBuilders(files, null, { functions });
expect(errors).not.toBe(null);
expect(errors[0].code).toBe('invalid_function_property');
});
it('Must fail for excludeFiles config property', async () => {
const functions = {
'api/test.js': { excludeFiles: { test: 1 } }
}
const files = ['api/test.js'];
const { errors } = await detectBuilders(files, null, { functions });
expect(errors).not.toBe(null);
expect(errors[0].code).toBe('invalid_function_property');
});
});
it('Test `detectRoutes`', async () => {

View File

@@ -1,6 +1,6 @@
{
"name": "@now/cgi",
"version": "0.1.5-canary.4",
"version": "1.0.0",
"license": "MIT",
"repository": {
"type": "git",

View File

@@ -13,7 +13,7 @@ npm i -g now
To quickly start a new project, run the following commands:
```
now init # Pick an example project to clone
now init # Pick an example project
cd <PROJECT> # Change directory to the new project
now dev # Run locally during development
now # Deploy to the cloud

View File

@@ -1,6 +1,6 @@
{
"name": "now",
"version": "16.1.4-canary.40",
"version": "16.5.2",
"preferGlobal": true,
"license": "Apache-2.0",
"description": "The command-line interface for Now",
@@ -70,7 +70,6 @@
"@types/debug": "0.0.31",
"@types/dotenv": "6.1.1",
"@types/escape-html": "0.0.20",
"@types/execa": "0.9.0",
"@types/fs-extra": "5.0.5",
"@types/glob": "7.1.1",
"@types/http-proxy": "1.16.2",
@@ -93,7 +92,7 @@
"@types/which": "1.3.1",
"@types/write-json-file": "2.2.1",
"@zeit/dockerignore": "0.0.5",
"@zeit/fun": "0.10.2",
"@zeit/fun": "0.10.3",
"@zeit/ncc": "0.18.5",
"@zeit/source-map-support": "0.6.2",
"ajv": "6.10.2",
@@ -125,7 +124,7 @@
"epipebomb": "1.0.0",
"escape-html": "1.0.3",
"esm": "3.1.4",
"execa": "1.0.0",
"execa": "3.2.0",
"fs-extra": "7.0.1",
"glob": "7.1.2",
"http-proxy": "1.17.0",
@@ -171,7 +170,7 @@
"tmp-promise": "1.0.3",
"tree-kill": "1.2.1",
"ts-node": "8.3.0",
"typescript": "3.2.4",
"typescript": "3.6.4",
"universal-analytics": "0.4.20",
"update-check": "1.5.3",
"utility-types": "2.1.0",

View File

@@ -29,8 +29,8 @@ import getUser from './util/get-user.ts';
import Client from './util/client.ts';
import NowTeams from './util/teams';
import cmd from './util/output/cmd';
import highlight from './util/output/highlight';
import { handleError } from './util/error';
import highlight from './util/output/highlight';
import reportError from './util/report-error';
import getConfig from './util/get-config';
import * as ERRORS from './util/errors-ts';

View File

@@ -141,6 +141,7 @@ export default class DevServer {
this.cachedNowConfig = null;
this.server = http.createServer(this.devServerHandler);
this.server.timeout = 0; // Disable timeout
this.serverUrlPrinted = false;
this.stopping = false;
this.buildMatches = new Map();

View File

@@ -89,7 +89,7 @@ async function getPackedBuilderPath(builderDirName) {
cwd: packagePath,
});
if (output.code !== 0 || output.stdout.trim() === '') {
if (output.exitCode !== 0 || output.stdout.trim() === '') {
throw new Error(
`Failed to pack ${builderDirName}: ${formatOutput(output)}`
);
@@ -158,7 +158,7 @@ test('[now dev] validate builds', async t => {
const directory = fixture('invalid-builds');
const output = await exec(directory);
t.is(output.code, 1, formatOutput(output));
t.is(output.exitCode, 1, formatOutput(output));
t.regex(
output.stderr,
/Invalid `builds` property: \[0\]\.src should be string/gm
@@ -169,7 +169,7 @@ test('[now dev] validate routes', async t => {
const directory = fixture('invalid-routes');
const output = await exec(directory);
t.is(output.code, 1, formatOutput(output));
t.is(output.exitCode, 1, formatOutput(output));
t.regex(
output.stderr,
/Invalid `routes` property: \[0\]\.src should be string/gm
@@ -180,7 +180,7 @@ test('[now dev] validate cleanUrls', async t => {
const directory = fixture('invalid-clean-urls');
const output = await exec(directory);
t.is(output.code, 1, formatOutput(output));
t.is(output.exitCode, 1, formatOutput(output));
t.regex(output.stderr, /Invalid `cleanUrls` property:\s+should be boolean/gm);
});
@@ -188,7 +188,7 @@ test('[now dev] validate trailingSlash', async t => {
const directory = fixture('invalid-trailing-slash');
const output = await exec(directory);
t.is(output.code, 1, formatOutput(output));
t.is(output.exitCode, 1, formatOutput(output));
t.regex(
output.stderr,
/Invalid `trailingSlash` property:\s+should be boolean/gm
@@ -199,7 +199,7 @@ test('[now dev] validate rewrites', async t => {
const directory = fixture('invalid-rewrites');
const output = await exec(directory);
t.is(output.code, 1, formatOutput(output));
t.is(output.exitCode, 1, formatOutput(output));
t.regex(
output.stderr,
/Invalid `rewrites` property: \[0\]\.destination should be string/gm
@@ -210,7 +210,7 @@ test('[now dev] validate redirects', async t => {
const directory = fixture('invalid-redirects');
const output = await exec(directory);
t.is(output.code, 1, formatOutput(output));
t.is(output.exitCode, 1, formatOutput(output));
t.regex(
output.stderr,
/Invalid `redirects` property: \[0\]\.statusCode should be integer/gm
@@ -221,7 +221,7 @@ test('[now dev] validate headers', async t => {
const directory = fixture('invalid-headers');
const output = await exec(directory);
t.is(output.code, 1, formatOutput(output));
t.is(output.exitCode, 1, formatOutput(output));
t.regex(
output.stderr,
/Invalid `headers` property: \[0\]\.headers\[0\]\.value should be string/gm
@@ -232,7 +232,7 @@ test('[now dev] validate mixed routes and rewrites', async t => {
const directory = fixture('invalid-mixed-routes-rewrites');
const output = await exec(directory);
t.is(output.code, 1, formatOutput(output));
t.is(output.exitCode, 1, formatOutput(output));
t.regex(output.stderr, /Cannot define both `routes` and `rewrites`/gm);
});

View File

@@ -432,12 +432,12 @@ CMD ["node", "index.js"]`,
},
}),
},
'lambda-with-node-runtime': {
'lambda-with-php-runtime': {
'api/test.php': `<?php echo 'Hello from PHP'; ?>`,
'now.json': JSON.stringify({
functions: {
'api/**/*.php': {
runtime: 'now-php@0.0.6',
runtime: 'now-php@0.0.7',
},
},
}),

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -1,6 +1,6 @@
{
"name": "now-client",
"version": "5.1.1-canary.17",
"version": "5.2.3",
"main": "dist/src/index.js",
"typings": "dist/src/index.d.ts",
"homepage": "https://zeit.co",

View File

@@ -44,7 +44,6 @@ async function* createDeployment(
method: 'POST',
headers: {
'Content-Type': 'application/json',
Authorization: `Bearer ${options.token}`,
},
body: JSON.stringify({
...metadata,

View File

@@ -98,8 +98,9 @@ export default async function* upload(
method: 'POST',
headers: {
'Content-Type': 'application/octet-stream',
'Content-Length': data.length,
'x-now-digest': sha,
'x-now-length': data.length,
'x-now-size': data.length,
},
body: stream,
teamId,

View File

@@ -133,11 +133,12 @@ export const fetch = async (
delete opts.teamId;
}
opts.headers = opts.headers || {};
// @ts-ignore
opts.headers.Authorization = `Bearer ${token}`;
// @ts-ignore
opts.headers['user-agent'] = `now-client-v${pkg.version}`;
opts.headers = {
...opts.headers,
authorization: `Bearer ${token}`,
accept: 'application/json',
'user-agent': `now-client-v${pkg.version}`,
};
debug(`${opts.method || 'GET'} ${url}`);
time = Date.now();

View File

@@ -1,6 +1,6 @@
{
"name": "@now/go",
"version": "0.5.11-canary.9",
"version": "1.0.0",
"license": "MIT",
"main": "./dist/index",
"homepage": "https://zeit.co/docs/runtimes#official-runtimes/go",

View File

@@ -1,6 +1,6 @@
{
"name": "@now/next",
"version": "1.0.0-canary.22",
"version": "1.0.5",
"license": "MIT",
"main": "./dist/index",
"homepage": "https://zeit.co/docs/runtimes#official-runtimes/next-js",

View File

@@ -1,6 +1,6 @@
{
"name": "@now/node-bridge",
"version": "1.2.4-canary.3",
"version": "1.2.7-canary.0",
"license": "MIT",
"main": "./index.js",
"repository": {

View File

@@ -5,7 +5,7 @@ import {
Server,
IncomingHttpHeaders,
OutgoingHttpHeaders,
request
request,
} from 'http';
interface NowProxyEvent {
@@ -29,6 +29,7 @@ export interface NowProxyResponse {
}
interface ServerLike {
timeout?: number;
listen: (
opts: {
host?: string;
@@ -132,16 +133,21 @@ export class Bridge {
}
listen() {
if (!this.server) {
const { server, resolveListening } = this;
if (!server) {
throw new Error('Server has not been set!');
}
const resolveListening = this.resolveListening;
if (typeof server.timeout === 'number' && server.timeout > 0) {
// Disable timeout (usually 2 minutes until Node 13).
// Instead, user should assign function `maxDuration`.
server.timeout = 0;
}
return this.server.listen(
return server.listen(
{
host: '127.0.0.1',
port: 0
port: 0,
},
function listeningCallback() {
if (!this || typeof this.address !== 'function') {
@@ -206,7 +212,7 @@ export class Bridge {
statusCode: response.statusCode || 200,
headers: response.headers,
body: bodyBuffer.toString('base64'),
encoding: 'base64'
encoding: 'base64',
});
});
});

View File

@@ -1,6 +1,6 @@
{
"name": "@now/node",
"version": "1.0.0-canary.15",
"version": "1.1.2",
"license": "MIT",
"main": "./dist/index",
"homepage": "https://zeit.co/docs/runtimes#official-runtimes/node-js",

View File

@@ -1,4 +1,12 @@
import { basename, dirname, join, relative, resolve, sep } from 'path';
import {
basename,
dirname,
join,
relative,
resolve,
sep,
parse as parsePath,
} from 'path';
import nodeFileTrace from '@zeit/node-file-trace';
import {
glob,
@@ -19,6 +27,7 @@ import {
Config,
debug,
} from '@now/build-utils';
export { shouldServe };
export { NowRequest, NowResponse } from './types';
import { makeNowLauncher, makeAwsLauncher } from './launcher';
import { readFileSync, lstatSync, readlinkSync, statSync } from 'fs';
@@ -281,6 +290,21 @@ async function compile(
};
}
function getAWSLambdaHandler(entrypoint: string, config: Config) {
if (config.awsLambdaHandler) {
return config.awsLambdaHandler as string;
}
if (process.env.NODEJS_AWS_HANDLER_NAME) {
const { dir, name } = parsePath(entrypoint);
return `${dir}${dir ? sep : ''}${name}.${
process.env.NODEJS_AWS_HANDLER_NAME
}`;
}
return '';
}
export const version = 3;
export async function build({
@@ -290,8 +314,10 @@ export async function build({
config = {},
meta = {},
}: BuildOptions) {
const shouldAddHelpers = config.helpers !== false;
const awsLambdaHandler = config.awsLambdaHandler as string;
const shouldAddHelpers = !(
config.helpers === false || process.env.NODEJS_HELPERS === '0'
);
const awsLambdaHandler = getAWSLambdaHandler(entrypoint, config);
const {
entrypointPath,
@@ -374,5 +400,3 @@ export async function prepareCache({ workPath }: PrepareCacheOptions) {
...(await glob('yarn.lock', workPath)),
};
}
export { shouldServe };

View File

@@ -152,7 +152,7 @@ export function register(opts: Options = {}): Register {
let compiler: string;
try {
compiler = require.resolve(options.compiler || 'typescript', {
paths: [cwd, nowNodeBase],
paths: [options.project || cwd, nowNodeBase],
});
} catch (e) {
compiler = require.resolve(eval('"./typescript"'));

View File

@@ -0,0 +1,7 @@
const ts = require('typescript');
export default function handler(req: any, res: any) {
if (req) {
res.end(`RANDOMNESS_PLACEHOLDER:backend ts version ${ts.version}`);
}
}

View File

@@ -0,0 +1,8 @@
{
"private": true,
"name": "nested-backend",
"devDependencies": {
"@types/node": "*",
"typescript": "3.0.3"
}
}

View File

@@ -0,0 +1,12 @@
{
"compilerOptions": {
"strict": true,
"esModuleInterop": true,
"sourceMap": true,
"noEmitOnError": true,
"lib": ["esnext"],
"target": "esnext",
"module": "commonjs"
},
"include": ["index.ts"]
}

View File

@@ -0,0 +1,7 @@
const ts = require('typescript');
export default function handler(req: any, res: any) {
if (req) {
res.end(`RANDOMNESS_PLACEHOLDER:frontend ts version ${ts.version}`);
}
}

View File

@@ -0,0 +1,8 @@
{
"private": true,
"name": "nested-frontend",
"devDependencies": {
"@types/node": "*",
"typescript": "3.0.1"
}
}

View File

@@ -0,0 +1,12 @@
{
"compilerOptions": {
"strict": true,
"esModuleInterop": true,
"sourceMap": true,
"noEmitOnError": true,
"lib": ["esnext"],
"target": "esnext",
"module": "commonjs"
},
"include": ["index.ts"]
}

View File

@@ -0,0 +1,14 @@
{
"version": 2,
"builds": [{ "src": "**/*.ts", "use": "@now/node" }],
"probes": [
{
"path": "/backend",
"mustContain": "backend ts version 3.0.3"
},
{
"path": "/frontend",
"mustContain": "frontend ts version 3.0.1"
}
]
}

View File

@@ -0,0 +1,7 @@
module.exports = (req, res) => {
if (res.json) {
return res.end('helpers are enabled');
}
res.end('helpers are disabled');
}

View File

@@ -0,0 +1,20 @@
{
"version": 2,
"builds": [
{
"src": "index.js",
"use": "@now/node"
}
],
"build": {
"env": {
"NODEJS_HELPERS": "0"
}
},
"probes": [
{
"path": "/",
"mustContain": "helpers are disabled"
}
]
}

View File

@@ -0,0 +1,7 @@
exports.myCustomHandler = async function() {
return {
statusCode: 200,
headers: {},
body: 'custom handler',
};
};

View File

@@ -0,0 +1,20 @@
{
"version": 2,
"builds": [
{
"src": "index.js",
"use": "@now/node"
}
],
"build": {
"env": {
"NODEJS_AWS_HANDLER_NAME": "myCustomHandler"
}
},
"probes": [
{
"path": "/",
"mustContain": "custom handler"
}
]
}

View File

@@ -1,6 +1,6 @@
{
"name": "@now/python",
"version": "0.2.17-canary.11",
"version": "1.0.0",
"main": "./dist/index.js",
"license": "MIT",
"homepage": "https://zeit.co/docs/runtimes#official-runtimes/python",

View File

@@ -1,6 +1,6 @@
{
"name": "@now/routing-utils",
"version": "1.2.3-canary.12",
"version": "1.3.3",
"description": "ZEIT Now routing utilities",
"main": "./dist/index.js",
"types": "./dist/index.d.ts",

View File

@@ -1,7 +1,7 @@
{
"name": "@now/ruby",
"author": "Nathan Cahill <nathan@nathancahill.com>",
"version": "0.1.5-canary.7",
"version": "1.0.0",
"license": "MIT",
"main": "./dist/index",
"homepage": "https://zeit.co/docs/runtimes#official-runtimes/ruby",

View File

@@ -20,11 +20,6 @@ const fixturesPath = path.resolve(__dirname, 'fixtures');
// eslint-disable-next-line no-restricted-syntax
for (const fixture of fs.readdirSync(fixturesPath)) {
if (['06-rails'].includes(fixture)) {
console.log(`Skipping ${fixture}`);
continue;
}
// eslint-disable-next-line no-loop-func
it(`should build ${fixture}`, async () => {
await expect(

View File

@@ -1,5 +1 @@
dist/
# bypass all ignored files for the cache fixtures
# because they contain node_modules and package-lock.json files
!test/cache-fixtures/**

View File

@@ -3,9 +3,8 @@ set -euo pipefail
ncc build src/index.ts -o dist
# copy gatsby-plugin-now files to the dist folder to
# make them available when they need to be injected
# copy gatsby plugin files in the gatsby redirect test case
gatsby_plugin="$(dirname $(pwd))/gatsby-plugin-now"
gatsby_local="dist/gatsby-plugin-now"
gatsby_local="test/fixtures/10a-gatsby-redirects/plugins/gatsby-plugin-now"
mkdir -p $gatsby_local
cp -v "$gatsby_plugin/gatsby-node.js" "$gatsby_plugin/package.json" "$gatsby_local"

View File

@@ -1,6 +1,6 @@
{
"name": "@now/static-build",
"version": "0.9.9-canary.20",
"version": "0.12.2",
"license": "MIT",
"main": "./dist/index",
"homepage": "https://zeit.co/docs/runtimes#official-runtimes/static-builds",

View File

@@ -2,7 +2,6 @@ import { readdir, stat, readFile, unlink } from 'fs';
import { promisify } from 'util';
import { join } from 'path';
import { Route } from '@now/build-utils';
import { injectGatsbyConfig } from './utils/gatsby-config';
const readirPromise = promisify(readdir);
const readFilePromise = promisify(readFile);
@@ -45,10 +44,6 @@ export const frameworks: Framework[] = [
return [];
}
},
beforeBuildHook: async entrypointDir => {
await injectGatsbyConfig(entrypointDir);
},
cachePattern: '.cache/**',
},
{
name: 'Hexo',
@@ -317,6 +312,4 @@ export interface Framework {
getOutputDirName: (dirPrefix: string) => Promise<string>;
defaultRoutes?: Route[] | ((dirPrefix: string) => Promise<Route[]>);
minNodeRange?: string;
beforeBuildHook?: (entrypointDir: string) => Promise<void>;
cachePattern?: string;
}

View File

@@ -18,7 +18,6 @@ import {
getNodeVersion,
getSpawnOptions,
Files,
FileFsRef,
Route,
BuildOptions,
Config,
@@ -150,24 +149,6 @@ async function getFrameworkRoutes(
return routes;
}
function getPkg(entrypoint: string, workPath: string) {
if (path.basename(entrypoint) !== 'package.json') {
return null;
}
const pkgPath = path.join(workPath, entrypoint);
const pkg = JSON.parse(readFileSync(pkgPath, 'utf8')) as PackageJson;
return pkg;
}
function getFramework(pkg: PackageJson) {
const dependencies = Object.assign({}, pkg.dependencies, pkg.devDependencies);
const framework = frameworks.find(
({ dependency }) => dependencies[dependency || '']
);
return framework;
}
export async function build({
files,
entrypoint,
@@ -187,9 +168,11 @@ export async function build({
(config && (config.distDir as string)) || 'dist'
);
const pkg = getPkg(entrypoint, workPath);
const entrypointName = path.basename(entrypoint);
if (pkg) {
if (entrypointName === 'package.json') {
const pkgPath = path.join(workPath, entrypoint);
const pkg = JSON.parse(readFileSync(pkgPath, 'utf8')) as PackageJson;
const gemfilePath = path.join(workPath, 'Gemfile');
const requirementsPath = path.join(workPath, 'requirements.txt');
@@ -247,7 +230,15 @@ export async function build({
// `public` is the default for zero config
distPath = path.join(workPath, path.dirname(entrypoint), 'public');
framework = getFramework(pkg);
const dependencies = Object.assign(
{},
pkg.dependencies,
pkg.devDependencies
);
framework = frameworks.find(
({ dependency }) => dependencies[dependency || '']
);
}
if (framework) {
@@ -265,10 +256,6 @@ export async function build({
`${framework.name} does not require a specific Node.js version. Continuing ...`
);
}
if (framework.beforeBuildHook) {
await framework.beforeBuildHook(entrypointDir);
}
}
const nodeVersion = await getNodeVersion(
@@ -390,7 +377,7 @@ export async function build({
return { routes, watch, output, distPath };
}
if (!config.zeroConfig && entrypoint.endsWith('.sh')) {
if (!config.zeroConfig && entrypointName.endsWith('.sh')) {
debug(`Running build script "${entrypoint}"`);
const nodeVersion = await getNodeVersion(entrypointDir, undefined, config);
const spawnOpts = getSpawnOptions(meta, nodeVersion);
@@ -416,27 +403,10 @@ export async function build({
throw new Error(message);
}
export async function prepareCache({
entrypoint,
workPath,
}: PrepareCacheOptions) {
// default cache paths
const defaultCacheFiles = await glob(
'{node_modules/**,package-lock.json,yarn.lock}',
workPath
);
// framework specific cache paths
let frameworkCacheFiles: { [path: string]: FileFsRef } | null = null;
const pkg = getPkg(entrypoint, workPath);
if (pkg) {
const framework = getFramework(pkg);
if (framework && framework.cachePattern) {
frameworkCacheFiles = await glob(framework.cachePattern, workPath);
}
}
return { ...defaultCacheFiles, ...frameworkCacheFiles };
export async function prepareCache({ workPath }: PrepareCacheOptions) {
return {
...(await glob('node_modules/**', workPath)),
...(await glob('package-lock.json', workPath)),
...(await glob('yarn.lock', workPath)),
};
}

View File

@@ -1,75 +0,0 @@
import { writeFile, copyFile, mkdir } from 'fs';
import { join, dirname } from 'path';
import { promisify } from 'util';
const writeFilePromise = promisify(writeFile);
const mkdirPromise = promisify(mkdir);
const copyFilePromise = promisify(copyFile);
const GATSBY_PLUGIN_NOW_NAME = 'gatsby-plugin-now';
const GATSBY_USER_CONFIG_PATH = './__now_gatsby_config_user.js';
function createGatsbyConfig(hasUserConfig: boolean) {
return `let userConfig = {}
${hasUserConfig ? `userConfig = require('${GATSBY_USER_CONFIG_PATH}')` : ''}
module.exports = {
...userConfig,
plugins: [
...(userConfig.plugins || []),
'${GATSBY_PLUGIN_NOW_NAME}'
]
}`;
}
export async function injectGatsbyConfig(entrypointDir: string) {
try {
// first, we copy gatsby-plugin-now to plugins
const gatsbyPluginNowPath = join(
entrypointDir,
'plugins',
GATSBY_PLUGIN_NOW_NAME
);
try {
await mkdirPromise(dirname(gatsbyPluginNowPath));
} catch (err) {
// plugins folder already exists, ignore error
}
await mkdirPromise(gatsbyPluginNowPath);
await copyFilePromise(
require.resolve('./gatsby-plugin-now/gatsby-node.js'),
join(gatsbyPluginNowPath, 'gatsby-node.js')
);
await copyFilePromise(
require.resolve('./gatsby-plugin-now/package.json'),
join(gatsbyPluginNowPath, 'package.json')
);
// then, we wrap the existing config and
// inject the plugin into the config
let hasUserConfig = false;
try {
await copyFilePromise(
join(entrypointDir, 'gatsby-config.js'),
join(entrypointDir, GATSBY_USER_CONFIG_PATH)
);
hasUserConfig = true;
} catch (err) {
// do nothing here, it just means the user
// didn't define gatsby-config.js
}
await writeFilePromise(
join(entrypointDir, 'gatsby-config.js'),
createGatsbyConfig(hasUserConfig),
{ encoding: 'utf-8' }
);
} catch (err) {
// if a step fail, we can ignore the error since we're not breaking
// the user's gatsby configuration
}
}

View File

@@ -1,5 +0,0 @@
{
"dependencies": {
"gatsby": "^2.13.3"
}
}

View File

@@ -1,27 +0,0 @@
const { prepareCache } = require('../dist');
const path = require('path');
describe('prepareCache', () => {
test('should cache yarn.lock, package-lock.json and node_modules', async () => {
const files = await prepareCache({
workPath: path.resolve(__dirname, './cache-fixtures/default'),
entrypoint: 'index.js',
});
expect(files['yarn.lock']).toBeDefined();
expect(files['package-lock.json']).toBeDefined();
expect(files['node_modules/file']).toBeDefined();
expect(files['index.js']).toBeUndefined();
});
test('should cache `.cache` folder for gatsby deployments', async () => {
const files = await prepareCache({
workPath: path.resolve(__dirname, './cache-fixtures/gatsby'),
entrypoint: 'package.json',
});
expect(files['.cache/file']).toBeDefined();
expect(files['yarn.lock']).toBeDefined();
});
});

View File

@@ -1,55 +1,9 @@
{
"version": 2,
"builds": [
{
"src": "package.json",
"use": "@now/static-build",
"config": { "zeroConfig": true }
}
{ "src": "package.json", "use": "@now/static-build", "config": { "zeroConfig": true } }
],
"probes": [
{ "path": "/", "mustContain": "Welcome to your new Gatsby site" },
{
"path": "/static/d/856328897.json",
"responseHeaders": {
"cache-control": "public,max-age=31536000,immutable"
}
},
{
"path": "/app-08a9fb9626777db1bf33.js",
"responseHeaders": {
"cache-control": "public,max-age=31536000,immutable"
}
},
{
"path": "/styles.fc4fa5e094d218207796.css",
"responseHeaders": {
"cache-control": "public,max-age=31536000,immutable"
}
},
{
"path": "/sw.js",
"responseHeaders": { "cache-control": "public,max-age=0,must-revalidate" }
},
{
"path": "/app-data.json",
"responseHeaders": { "cache-control": "public,max-age=0,must-revalidate" }
},
{
"path": "/index.html",
"responseHeaders": { "cache-control": "public,max-age=0,must-revalidate" }
},
{
"path": "/page-data/404/page-data.json",
"responseHeaders": { "cache-control": "public,max-age=0,must-revalidate" }
},
{
"path": "/path-that-does-not-exist",
"mustContain": "You just hit a route that doesn&#x27;t exist..."
},
{
"path": "/path-that-does-not-exist",
"status": 404
}
{ "path": "/", "mustContain": "Welcome to your new Gatsby site" }
]
}

View File

@@ -6,3 +6,4 @@ node_modules
public/
.DS_Store
yarn-error.log
plugins

View File

@@ -0,0 +1,3 @@
module.exports = {
plugins: ["gatsby-plugin-now"]
};

2
run.js
View File

@@ -20,7 +20,7 @@ async function main() {
.toString()
.trim();
const gitPath = branch === 'master' ? 'HEAD~1' : 'origin/canary...HEAD';
const gitPath = branch === 'master' ? 'HEAD~1' : 'origin/master...HEAD';
const diff = execSync(`git diff ${gitPath} --name-only`).toString();
const changed = diff

121
yarn.lock
View File

@@ -1538,7 +1538,7 @@
resolved "https://registry.yarnpkg.com/@types/events/-/events-3.0.0.tgz#2862f3f58a9a7f7c3e78d79f130dd4d71c25c2a7"
integrity sha512-EaObqwIvayI5a8dCzhFrjKzVwKLxjoG9T6Ppd5CEo07LRKfQ8Yokw54r5+Wq7FaBQ+yXRvQAYPrHwya1/UFt9g==
"@types/execa@0.9.0", "@types/execa@^0.9.0":
"@types/execa@^0.9.0":
version "0.9.0"
resolved "https://registry.yarnpkg.com/@types/execa/-/execa-0.9.0.tgz#9b025d2755f17e80beaf9368c3f4f319d8b0fb93"
integrity sha512-mgfd93RhzjYBUHHV532turHC2j4l/qxsF/PbfDmprHDEUHmNZGlDn1CEsulGK3AfsPdhkWzZQT/S/k0UGhLGsA==
@@ -2015,14 +2015,14 @@
agentkeepalive "3.4.1"
debug "3.1.0"
"@zeit/fun@0.10.2":
version "0.10.2"
resolved "https://registry.yarnpkg.com/@zeit/fun/-/fun-0.10.2.tgz#799dbedfc931f439a541c6344e4faeaf3ded98b2"
integrity sha512-wIIF3X5ASnRJLa66RktuIF6oVtRa13WSAlt08Lc/01fpQTgNiVAd92PhlfRU4azJQkbKNEQ5o+OWncAvE4s+7w==
"@zeit/fun@0.10.3":
version "0.10.3"
resolved "https://registry.yarnpkg.com/@zeit/fun/-/fun-0.10.3.tgz#f41c1c75b2d61e464bd9eaf1aeab370a43b73d2e"
integrity sha512-+9zwr+nX7rF9FJtuLekgTex0Bq7Tgq2yyv+F5j2+kVUHoqRcoBuX2AdGzWV62+kMjBdx/ODRQmN4eZl9mWjNAw==
dependencies:
async-listen "1.0.0"
debug "4.1.1"
execa "1.0.0"
execa "3.2.0"
fs-extra "7.0.1"
generic-pool "3.4.2"
micro "9.3.5-canary.3"
@@ -2033,6 +2033,7 @@
stat-mode "0.3.0"
stream-to-promise "2.2.0"
tar "4.4.8"
tree-kill "1.2.1"
uid-promise "1.0.0"
uuid "3.3.2"
xdg-app-paths "5.1.0"
@@ -3361,6 +3362,13 @@ collection-visit@^1.0.0:
map-visit "^1.0.0"
object-visit "^1.0.0"
color-convert@^1.9.0:
version "1.9.3"
resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8"
integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==
dependencies:
color-name "1.1.3"
color-convert@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3"
@@ -3368,6 +3376,11 @@ color-convert@^2.0.1:
dependencies:
color-name "~1.1.4"
color-name@1.1.3:
version "1.1.3"
resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25"
integrity sha1-p9BVi9icQveV3UIyj3QIMcpTvCU=
color-name@~1.1.4:
version "1.1.4"
resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2"
@@ -3711,6 +3724,15 @@ cross-spawn@^5.0.1:
shebang-command "^1.2.0"
which "^1.2.9"
cross-spawn@^7.0.0:
version "7.0.1"
resolved "https://registry.yarnpkg.com/cross-spawn/-/cross-spawn-7.0.1.tgz#0ab56286e0f7c24e153d04cc2aa027e43a9a5d14"
integrity sha512-u7v4o84SwFpD32Z8IIcPZ6z1/ie24O6RU3RbtL5Y316l3KuHVPx9ItBgWQ6VlfAFnRnTtMUrsQ9MUUTuEZjogg==
dependencies:
path-key "^3.1.0"
shebang-command "^2.0.0"
which "^2.0.1"
crypto-random-string@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-1.0.0.tgz#a230f64f568310e1498009940790ec99545bca7e"
@@ -4519,19 +4541,6 @@ exec-sh@^0.3.2:
resolved "https://registry.yarnpkg.com/exec-sh/-/exec-sh-0.3.2.tgz#6738de2eb7c8e671d0366aea0b0db8c6f7d7391b"
integrity sha512-9sLAvzhI5nc8TpuQUh4ahMdCrWT00wPWz7j47/emR5+2qEfoZP5zzUXvx+vdx+H6ohhnsYC31iX04QLYJK8zTg==
execa@1.0.0, execa@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/execa/-/execa-1.0.0.tgz#c6236a5bb4df6d6f15e88e7f017798216749ddd8"
integrity sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==
dependencies:
cross-spawn "^6.0.0"
get-stream "^4.0.0"
is-stream "^1.1.0"
npm-run-path "^2.0.0"
p-finally "^1.0.0"
signal-exit "^3.0.0"
strip-eof "^1.0.0"
execa@2.0.4, execa@^2.0.3:
version "2.0.4"
resolved "https://registry.yarnpkg.com/execa/-/execa-2.0.4.tgz#2f5cc589c81db316628627004ea4e37b93391d8e"
@@ -4547,6 +4556,22 @@ execa@2.0.4, execa@^2.0.3:
signal-exit "^3.0.2"
strip-final-newline "^2.0.0"
execa@3.2.0:
version "3.2.0"
resolved "https://registry.yarnpkg.com/execa/-/execa-3.2.0.tgz#18326b79c7ab7fbd6610fd900c1b9e95fa48f90a"
integrity sha512-kJJfVbI/lZE1PZYDI5VPxp8zXPO9rtxOkhpZ0jMKha56AI9y2gGVC6bkukStQf0ka5Rh15BA5m7cCCH4jmHqkw==
dependencies:
cross-spawn "^7.0.0"
get-stream "^5.0.0"
human-signals "^1.1.1"
is-stream "^2.0.0"
merge-stream "^2.0.0"
npm-run-path "^4.0.0"
onetime "^5.1.0"
p-finally "^2.0.0"
signal-exit "^3.0.2"
strip-final-newline "^2.0.0"
execa@^0.7.0:
version "0.7.0"
resolved "https://registry.yarnpkg.com/execa/-/execa-0.7.0.tgz#944becd34cc41ee32a63a9faf27ad5a65fc59777"
@@ -4573,6 +4598,19 @@ execa@^0.8.0:
signal-exit "^3.0.0"
strip-eof "^1.0.0"
execa@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/execa/-/execa-1.0.0.tgz#c6236a5bb4df6d6f15e88e7f017798216749ddd8"
integrity sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==
dependencies:
cross-spawn "^6.0.0"
get-stream "^4.0.0"
is-stream "^1.1.0"
npm-run-path "^2.0.0"
p-finally "^1.0.0"
signal-exit "^3.0.0"
strip-eof "^1.0.0"
exit@^0.1.2:
version "0.1.2"
resolved "https://registry.yarnpkg.com/exit/-/exit-0.1.2.tgz#0632638f8d877cc82107d30a0fff1a17cba1cd0c"
@@ -5620,6 +5658,11 @@ https-proxy-agent@^2.2.1:
agent-base "^4.3.0"
debug "^3.1.0"
human-signals@^1.1.1:
version "1.1.1"
resolved "https://registry.yarnpkg.com/human-signals/-/human-signals-1.1.1.tgz#c5b1cd14f50aeae09ab6c59fe63ba3395fe4dfa3"
integrity sha512-SEQu7vl8KjNL2eoGBLF3+wAjpsNfA9XMlXAYj/3EdaNfAlxKthD1xjEQfGOUhllCGGJVNY34bRr6lPINhNjyZw==
humanize-ms@^1.2.1:
version "1.2.1"
resolved "https://registry.yarnpkg.com/humanize-ms/-/humanize-ms-1.2.1.tgz#c46e3159a293f6b896da29316d8b6fe8bb79bbed"
@@ -7930,7 +7973,7 @@ normalize-url@^4.1.0:
integrity sha512-0NLtR71o4k6GLP+mr6Ty34c5GA6CMoEsncKJxvQd8NzPxaHRJNnb5gZE8R1XF4CPIS7QPHLJ74IFszwtNVAHVQ==
now-client@./packages/now-client:
version "5.1.1-canary.16"
version "5.1.1-canary.17"
dependencies:
"@zeit/fetch" "5.1.0"
async-retry "1.2.3"
@@ -8021,6 +8064,13 @@ npm-run-path@^3.0.0:
dependencies:
path-key "^3.0.0"
npm-run-path@^4.0.0:
version "4.0.0"
resolved "https://registry.yarnpkg.com/npm-run-path/-/npm-run-path-4.0.0.tgz#d644ec1bd0569187d2a52909971023a0a58e8438"
integrity sha512-8eyAOAH+bYXFPSnNnKr3J+yoybe8O87Is5rtAQ8qRczJz1ajcsjg8l2oZqP+Ppx15Ii3S1vUTjQN2h4YO2tWWQ==
dependencies:
path-key "^3.0.0"
"npmlog@0 || 1 || 2 || 3 || 4", npmlog@^4.0.2, npmlog@^4.1.2:
version "4.1.2"
resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b"
@@ -8537,7 +8587,7 @@ path-key@^2.0.0, path-key@^2.0.1:
resolved "https://registry.yarnpkg.com/path-key/-/path-key-2.0.1.tgz#411cadb574c5a140d3a4b1910d40d80cc9f40b40"
integrity sha1-QRyttXTFoUDTpLGRDUDYDMn0C0A=
path-key@^3.0.0:
path-key@^3.0.0, path-key@^3.1.0:
version "3.1.0"
resolved "https://registry.yarnpkg.com/path-key/-/path-key-3.1.0.tgz#99a10d870a803bdd5ee6f0470e58dfcd2f9a54d3"
integrity sha512-8cChqz0RP6SHJkMt48FW0A7+qUOn+OsnOsVtzI59tZ8m+5bCSk7hzwET0pulwOM2YMn9J1efb07KB9l9f30SGg==
@@ -9623,11 +9673,23 @@ shebang-command@^1.2.0:
dependencies:
shebang-regex "^1.0.0"
shebang-command@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/shebang-command/-/shebang-command-2.0.0.tgz#ccd0af4f8835fbdc265b82461aaf0c36663f34ea"
integrity sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==
dependencies:
shebang-regex "^3.0.0"
shebang-regex@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-1.0.0.tgz#da42f49740c0b42db2ca9728571cb190c98efea3"
integrity sha1-2kL0l0DAtC2yypcoVxyxkMmO/qM=
shebang-regex@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/shebang-regex/-/shebang-regex-3.0.0.tgz#ae16f1644d873ecad843b0307b143362d4c42172"
integrity sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==
shellwords@^0.1.1:
version "0.1.1"
resolved "https://registry.yarnpkg.com/shellwords/-/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b"
@@ -10624,11 +10686,6 @@ typedarray@^0.0.6:
resolved "https://registry.yarnpkg.com/typedarray/-/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777"
integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=
typescript@3.2.4:
version "3.2.4"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.2.4.tgz#c585cb952912263d915b462726ce244ba510ef3d"
integrity sha512-0RNDbSdEokBeEAkgNbxJ+BLwSManFy9TeXz8uW+48j/xhEXv1ePME60olyzw2XzUqUBNAYFeJadIqAgNqIACwg==
typescript@3.5.1:
version "3.5.1"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.5.1.tgz#ba72a6a600b2158139c5dd8850f700e231464202"
@@ -10639,6 +10696,11 @@ typescript@3.5.2:
resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.5.2.tgz#a09e1dc69bc9551cadf17dba10ee42cf55e5d56c"
integrity sha512-7KxJovlYhTX5RaRbUdkAXN1KUZ8PwWlTzQdHV6xNqvuFOs7+WBo10TQUqT19Q/Jz2hk5v9TQDIhyLhhJY4p5AA==
typescript@3.6.4:
version "3.6.4"
resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.6.4.tgz#b18752bb3792bc1a0281335f7f6ebf1bbfc5b91d"
integrity sha512-unoCll1+l+YK4i4F8f22TaNVPRHcD9PA3yCuZ8g5e0qGqlVlJ/8FSateOLLSagn+Yg5+ZwuPkL8LFUc0Jcvksg==
uglify-js@^3.1.4:
version "3.6.0"
resolved "https://registry.yarnpkg.com/uglify-js/-/uglify-js-3.6.0.tgz#704681345c53a8b2079fb6cec294b05ead242ff5"
@@ -11012,6 +11074,13 @@ which@1.2.x:
dependencies:
isexe "^2.0.0"
which@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/which/-/which-2.0.1.tgz#f1cf94d07a8e571b6ff006aeb91d0300c47ef0a4"
integrity sha512-N7GBZOTswtB9lkQBZA4+zAXrjEIWAUOB93AvzUiudRzRxhUdLURQ7D/gAIMY1gatT/LTbmbcv8SiYazy3eYB7w==
dependencies:
isexe "^2.0.0"
wide-align@^1.1.0:
version "1.1.3"
resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.3.tgz#ae074e6bdc0c14a431e804e624549c633b000457"