Compare commits

..

4 Commits

Author SHA1 Message Date
Max Rovensky
aaf7d6b1cd Publish Canary
- @now/frameworks@0.0.4-canary.0
 - now@16.7.2-canary.4
2020-01-07 23:18:11 +08:00
Luc
d4b6814d40 [@now/frameworks] Improve Framework type (#3515)
Makes types more specific: we want to avoid missing project settings placeholder/value in the UIs that consume frameworks (cli, front-end, ...).
2020-01-07 15:12:33 +00:00
Max
a85f11aaef Store file count on file_count event for future use (#3505)
Fixes an undefined length issue introduced by #3502
2020-01-07 12:18:41 +00:00
Luc
090c3ef9fc [now-cli] Fix signal-exit in yarn.lock (#3508)
Fix https://github.com/zeit/now/pull/3490/files#r363418297.
2020-01-07 10:38:13 +00:00
5 changed files with 15 additions and 26 deletions

View File

@@ -3,10 +3,7 @@ export interface FrameworkDetectionItem {
matchContent?: string;
}
interface Setting {
value?: string;
placeholder?: string;
}
type Setting = { value: string } | { placeholder: string }
export interface Framework {
name: string;
@@ -18,9 +15,9 @@ export interface Framework {
every?: FrameworkDetectionItem[];
some?: FrameworkDetectionItem[];
};
settings?: {
buildCommand?: Setting;
devCommand?: Setting;
outputDirectory?: Setting;
settings: {
buildCommand: Setting;
devCommand: Setting;
outputDirectory: Setting;
};
}

View File

@@ -1,6 +1,6 @@
{
"name": "@now/frameworks",
"version": "0.0.3",
"version": "0.0.4-canary.0",
"main": "frameworks.json",
"license": "UNLICENSED"
}

View File

@@ -1,6 +1,6 @@
{
"name": "now",
"version": "16.7.2-canary.3",
"version": "16.7.2-canary.4",
"preferGlobal": true,
"license": "Apache-2.0",
"description": "The command-line interface for Now",

View File

@@ -59,6 +59,7 @@ export default async function processDeployment({
let queuedSpinner = null;
let buildSpinner = null;
let deploySpinner = null;
let fileCount = null;
for await (const event of createDeployment(
nowClientOptions,
@@ -81,6 +82,7 @@ export default async function processDeployment({
debug(
`Total files ${event.payload.total.size}, ${event.payload.missing.length} changed`
);
fileCount = event.payload.missing.length;
const missingSize = event.payload.missing
.map((sha: string) => event.payload.total.get(sha).data.length)
@@ -111,13 +113,7 @@ export default async function processDeployment({
now._host = event.payload.url;
if (!quiet) {
log(
`Synced ${pluralize(
'file',
event.payload.missing.length,
true
)} ${uploadStamp()}`
);
log(`Synced ${pluralize('file', fileCount, true)} ${uploadStamp()}`);
const version = isLegacy ? `${chalk.grey('[v1]')} ` : '';
log(`https://${event.payload.url} ${version}${deployStamp()}`);
} else {
@@ -187,6 +183,8 @@ export default async function processDeployment({
}
}
} else {
let fileCount = null;
for await (const event of createLegacyDeployment(
nowClientOptions,
requestBody,
@@ -200,7 +198,7 @@ export default async function processDeployment({
debug(
`Total files ${event.payload.total.size}, ${event.payload.missing.length} changed`
);
fileCount = event.payload.missing.length;
const missingSize = event.payload.missing
.map((sha: string) => event.payload.total.get(sha).data.length)
.reduce((a: number, b: number) => a + b, 0);
@@ -230,13 +228,7 @@ export default async function processDeployment({
now._host = event.payload.url;
if (!quiet) {
log(
`Synced ${pluralize(
'file',
event.payload.missing.length,
true
)} ${uploadStamp()}`
);
log(`Synced ${pluralize('file', fileCount, true)} ${uploadStamp()}`);
const version = isLegacy ? `${chalk.grey('[v1]')} ` : '';
log(`${event.payload.url} ${version}${deployStamp()}`);
} else {

View File

@@ -9738,7 +9738,7 @@ shellwords@^0.1.1:
resolved "https://registry.yarnpkg.com/shellwords/-/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b"
integrity sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==
signal-exit@3.0.2, signal-exit@^3.0.0, signal-exit@^3.0.2:
signal-exit@3.0.2, signal-exit@TooTallNate/signal-exit#update/sighub-to-sigint-on-windows, signal-exit@^3.0.0, signal-exit@^3.0.2:
version "3.0.2"
resolved "https://codeload.github.com/TooTallNate/signal-exit/tar.gz/58088fa7f715149f8411e089a4a6e3fe6ed265ec"