@vuepress/cli
Advanced tools
Comparing version 2.0.0-beta.50 to 2.0.0-beta.51
// src/commands/build/createBuild.ts | ||
import process6 from "process"; | ||
import { createBuildApp } from "@vuepress/core"; | ||
import { debug, fs as fs5, logger as logger3 } from "@vuepress/utils"; | ||
import { debug, formatMs, fs as fs5, logger as logger3, withSpinner } from "@vuepress/utils"; | ||
@@ -194,2 +194,3 @@ // src/config/defineUserConfig.ts | ||
var createBuild = (defaultAppConfig) => async (sourceDir = ".", commandOptions = {}) => { | ||
const start = Date.now(); | ||
log(`commandOptions:`, commandOptions); | ||
@@ -214,16 +215,21 @@ if (process6.env.NODE_ENV === void 0) { | ||
if (commandOptions.cleanTemp === true) { | ||
logger3.info("Cleaning temp..."); | ||
await fs5.remove(app.dir.temp()); | ||
await withSpinner("Cleaning temp")(() => { | ||
return fs5.remove(app.dir.temp()); | ||
}); | ||
} | ||
if (commandOptions.cleanCache === true) { | ||
logger3.info("Cleaning cache..."); | ||
await fs5.remove(app.dir.cache()); | ||
await withSpinner("Cleaning cache")(() => { | ||
return fs5.remove(app.dir.cache()); | ||
}); | ||
} | ||
await fs5.emptyDir(app.dir.dest()); | ||
logger3.info("Initializing VuePress and preparing data..."); | ||
await app.init(); | ||
await app.prepare(); | ||
await withSpinner("Initializing and preparing data")(async () => { | ||
await app.init(); | ||
await app.prepare(); | ||
}); | ||
await app.build(); | ||
await app.pluginApi.hooks.onGenerated.process(app); | ||
logger3.success("VuePress build successfully!"); | ||
logger3.success( | ||
`VuePress build completed in ${formatMs(Date.now() - start)}!` | ||
); | ||
}; | ||
@@ -234,3 +240,3 @@ | ||
import { createDevApp } from "@vuepress/core"; | ||
import { debug as debug2, fs as fs6, logger as logger6 } from "@vuepress/utils"; | ||
import { debug as debug2, fs as fs6, logger as logger6, withSpinner as withSpinner2 } from "@vuepress/utils"; | ||
@@ -471,12 +477,15 @@ // src/commands/dev/watchPageFiles.ts | ||
if (commandOptions.cleanTemp === true) { | ||
logger6.info("Cleaning temp..."); | ||
await fs6.remove(app.dir.temp()); | ||
await withSpinner2("Cleaning temp")(() => { | ||
return fs6.remove(app.dir.temp()); | ||
}); | ||
} | ||
if (commandOptions.cleanCache === true) { | ||
logger6.info("Cleaning cache..."); | ||
await fs6.remove(app.dir.cache()); | ||
await withSpinner2("Cleaning cache")(() => { | ||
return fs6.remove(app.dir.cache()); | ||
}); | ||
} | ||
logger6.info("Initializing VuePress and preparing data..."); | ||
await app.init(); | ||
await app.prepare(); | ||
await withSpinner2("Initializing and preparing data")(async () => { | ||
await app.init(); | ||
await app.prepare(); | ||
}); | ||
const close = await app.dev(); | ||
@@ -483,0 +492,0 @@ if (commandOptions.watch === false) { |
{ | ||
"name": "@vuepress/cli", | ||
"version": "2.0.0-beta.50", | ||
"version": "2.0.0-beta.51", | ||
"description": "CLI package of VuePress", | ||
@@ -35,5 +35,5 @@ "keywords": [ | ||
"dependencies": { | ||
"@vuepress/core": "2.0.0-beta.50", | ||
"@vuepress/shared": "2.0.0-beta.50", | ||
"@vuepress/utils": "2.0.0-beta.50", | ||
"@vuepress/core": "2.0.0-beta.51", | ||
"@vuepress/shared": "2.0.0-beta.51", | ||
"@vuepress/utils": "2.0.0-beta.51", | ||
"cac": "^6.7.12", | ||
@@ -40,0 +40,0 @@ "chokidar": "^3.5.3", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
27222
723
0
+ Added@mdit-vue/plugin-component@0.10.0(transitive)
+ Added@mdit-vue/plugin-frontmatter@0.10.0(transitive)
+ Added@mdit-vue/plugin-headers@0.10.0(transitive)
+ Added@mdit-vue/plugin-sfc@0.10.0(transitive)
+ Added@mdit-vue/plugin-title@0.10.0(transitive)
+ Added@mdit-vue/plugin-toc@0.10.0(transitive)
+ Added@mdit-vue/shared@0.10.0(transitive)
+ Added@mdit-vue/types@0.10.0(transitive)
+ Added@vuepress/client@2.0.0-beta.51(transitive)
+ Added@vuepress/core@2.0.0-beta.51(transitive)
+ Added@vuepress/markdown@2.0.0-beta.51(transitive)
+ Added@vuepress/shared@2.0.0-beta.51(transitive)
+ Added@vuepress/utils@2.0.0-beta.51(transitive)
- Removed@mdit-vue/plugin-component@0.9.4(transitive)
- Removed@mdit-vue/plugin-frontmatter@0.9.2(transitive)
- Removed@mdit-vue/plugin-headers@0.9.3(transitive)
- Removed@mdit-vue/plugin-sfc@0.9.2(transitive)
- Removed@mdit-vue/plugin-title@0.9.3(transitive)
- Removed@mdit-vue/plugin-toc@0.9.2(transitive)
- Removed@mdit-vue/shared@0.9.2(transitive)
- Removed@mdit-vue/types@0.9.2(transitive)
- Removed@vuepress/client@2.0.0-beta.50(transitive)
- Removed@vuepress/core@2.0.0-beta.50(transitive)
- Removed@vuepress/markdown@2.0.0-beta.50(transitive)
- Removed@vuepress/shared@2.0.0-beta.50(transitive)
- Removed@vuepress/utils@2.0.0-beta.50(transitive)
Updated@vuepress/core@2.0.0-beta.51