@knowcode/doc-builder 1.1.0 → 1.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -5,6 +5,31 @@ All notable changes to @knowcode/doc-builder will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [1.1.2] - 2025-01-19
9
+
10
+ ### Changed
11
+ - Simplified deployment output - removed Root Directory warnings
12
+ - Cleaner deployment experience with just essential information
13
+ - Shows simple "Starting deployment" message instead of warnings
14
+
15
+ ### Removed
16
+ - Pre-deployment Root Directory check and warnings
17
+ - Project ID display during deployment
18
+ - Verbose deployment preparation messages
19
+
20
+ ## [1.1.1] - 2025-01-19
21
+
22
+ ### Added
23
+ - TL;DR section at the top of CLI help for quick understanding
24
+ - Clear production deployment behavior explanation in help
25
+ - Visual indicators for v1.1.0+ deployment changes
26
+ - Examples showing production URLs vs preview URLs
27
+
28
+ ### Improved
29
+ - Help text now prominently shows default production deployment
30
+ - Added emoji and color highlights for important changes
31
+ - Clearer deployment behavior section
32
+
8
33
  ## [1.1.0] - 2025-01-19
9
34
 
10
35
  ### Changed (BREAKING)
package/cli.js CHANGED
@@ -27,11 +27,16 @@ program
27
27
  .addHelpText('before', `
28
28
  ${chalk.cyan('šŸš€ @knowcode/doc-builder')} - Transform your markdown into beautiful documentation sites
29
29
 
30
+ ${chalk.bgGreen.black(' TL;DR ')} ${chalk.green('Just run:')} ${chalk.cyan.bold('npx @knowcode/doc-builder')} ${chalk.green('→ Your docs are live on Vercel!')}
31
+
32
+ ${chalk.gray('━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━')}
33
+
30
34
  ${chalk.yellow('What it does:')}
31
35
  • Converts markdown files to static HTML with a beautiful Notion-inspired theme
32
36
  • Automatically generates navigation from your folder structure
33
37
  • Supports mermaid diagrams, syntax highlighting, and dark mode
34
38
  • Deploys to Vercel with one command (zero configuration)
39
+ • ${chalk.green.bold('NEW:')} Deploys directly to production by default (v1.1.0+)
35
40
  • Optional authentication to protect private documentation
36
41
 
37
42
  ${chalk.yellow('Requirements:')}
@@ -183,10 +188,12 @@ ${chalk.yellow('First-time Vercel Setup:')}
183
188
  • Under "Deployment Protection", set to ${chalk.yellow('Disabled')}
184
189
  • This allows public access to your docs
185
190
 
186
- ${chalk.yellow('Subsequent Deployments:')}
187
- ${chalk.gray('$')} npx @knowcode/doc-builder ${chalk.gray('# Build and deploy to production')}
188
- ${chalk.gray('$')} npx @knowcode/doc-builder deploy ${chalk.gray('# Deploy to production')}
189
- ${chalk.gray('$')} npx @knowcode/doc-builder deploy --no-prod ${chalk.gray('# Deploy preview only')}
191
+ ${chalk.yellow('Deployment Behavior (v1.1.0+):')}
192
+ ${chalk.green.bold('šŸŽÆ DEFAULT: All deployments go to PRODUCTION')}
193
+
194
+ ${chalk.gray('$')} npx @knowcode/doc-builder ${chalk.gray('# → yourdocs.vercel.app')}
195
+ ${chalk.gray('$')} npx @knowcode/doc-builder deploy ${chalk.gray('# → yourdocs.vercel.app')}
196
+ ${chalk.gray('$')} npx @knowcode/doc-builder deploy --no-prod ${chalk.gray('# → preview URL only')}
190
197
 
191
198
  ${chalk.yellow('When All Else Fails - Delete and Start Fresh:')}
192
199
  Sometimes the cleanest solution is to delete the Vercel project:
package/lib/deploy.js CHANGED
@@ -164,35 +164,9 @@ async function deployToVercel(config, isProd = false) {
164
164
  throw new Error(`Output directory ${outputPath} does not exist. Run 'doc-builder build' first.`);
165
165
  }
166
166
 
167
- // Check for existing project link and warn about common issues
168
- const vercelProjectPath = path.join(outputPath, '.vercel', 'project.json');
169
- if (fs.existsSync(vercelProjectPath)) {
170
- try {
171
- const projectInfo = fs.readJsonSync(vercelProjectPath);
172
- const projectId = projectInfo.projectId || 'unknown';
173
-
174
- console.log(chalk.blue('\n━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━'));
175
- console.log(chalk.yellow('šŸ“¦ Deploying to existing Vercel project'));
176
- console.log(chalk.blue('━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\n'));
177
-
178
- console.log(chalk.white('Project ID: ') + chalk.cyan(projectId));
179
-
180
- // Check if .vercel/project.json has rootDirectory set
181
- if (projectInfo.settings && projectInfo.settings.rootDirectory) {
182
- console.log(chalk.red.bold('\nāš ļø WARNING: Root Directory is set to: ') + chalk.yellow(projectInfo.settings.rootDirectory));
183
- console.log(chalk.red('This may cause deployment to fail!\n'));
184
- }
185
-
186
- console.log(chalk.yellow.bold('\n⚔ BEFORE CONTINUING:'));
187
- console.log(chalk.white('1. Check your Root Directory setting at:'));
188
- console.log(chalk.cyan(` https://vercel.com/dashboard/project/${projectId}`));
189
- console.log(chalk.white('2. Root Directory should be ') + chalk.green.bold('EMPTY (blank)'));
190
- console.log(chalk.white('3. If it says "html", ') + chalk.red.bold('DELETE IT NOW!\n'));
191
-
192
- } catch (e) {
193
- // Ignore read errors
194
- }
195
- }
167
+ // Simple deployment message
168
+ console.log(chalk.blue('\nšŸš€ Starting deployment to Vercel...'));
169
+ console.log(chalk.gray('This will take a few seconds...\n'));
196
170
 
197
171
  // Create vercel.json in output directory for deployment
198
172
  const vercelConfigPath = path.join(outputPath, 'vercel.json');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@knowcode/doc-builder",
3
- "version": "1.1.0",
3
+ "version": "1.1.2",
4
4
  "description": "Reusable documentation builder for markdown-based sites with Vercel deployment support",
5
5
  "main": "index.js",
6
6
  "bin": {