@docubook/cli 0.2.6 → 0.2.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@docubook/cli",
3
- "version": "0.2.6",
3
+ "version": "0.2.7",
4
4
  "description": "DocuBook CLI tool that helps you initialize, update, and deploy documentation directly from your terminal.",
5
5
  "type": "module",
6
6
  "files": [
@@ -28,16 +28,17 @@
28
28
  "author-url": "https://wildan.dev",
29
29
  "license": "MIT",
30
30
  "dependencies": {
31
+ "boxen": "^8.0.1",
31
32
  "chalk": "^5.3.0",
33
+ "cli-progress": "^3.12.0",
32
34
  "commander": "^12.1.0",
33
35
  "ora": "^8.1.0",
34
36
  "prompts": "^2.4.2",
35
- "boxen": "^8.0.1",
36
- "cli-progress": "^3.12.0"
37
+ "semver": "^7.7.4"
37
38
  },
38
39
  "devDependencies": {
39
- "eslint": "^9.39.3",
40
40
  "@eslint/js": "^9.39.3",
41
+ "eslint": "^9.39.3",
41
42
  "eslint-config-next": "^16.1.3"
42
43
  },
43
44
  "engines": {
@@ -12,6 +12,7 @@ import ora from "ora";
12
12
  import fs from "fs";
13
13
  import os from "os";
14
14
  import path from "path";
15
+ import { lt } from "semver";
15
16
 
16
17
  // Helpers to show changelog once per installed version. Stores shown versions under
17
18
  // $HOME/.docubook_cli_seen_changelogs.json as a map: { "@docubook/cli": ["1.2.3"] }
@@ -94,7 +95,7 @@ async function showChangelogOnce(pkgName, version) {
94
95
  if (!section) return;
95
96
 
96
97
  // Print a concise changelog section
97
- console.log("\n=== DocuBook CLI changelog (new) ===\n");
98
+ console.log("\n===========================================================\n");
98
99
  console.log(section.trim());
99
100
  console.log("\nFor full changelog, visit:");
100
101
  console.log(` https://github.com/DocuBook/docubook/blob/main/CHANGELOG.md\n`);
@@ -145,8 +146,8 @@ export function initializeProgram(version) {
145
146
  if (spinner && typeof spinner.stop === 'function') spinner.stop();
146
147
  console.log('Checking for updates...');
147
148
 
148
- if (latest === version) {
149
- console.log(`No update needed, current version is ${version}, fetched latest release is ${latest}`);
149
+ if (!lt(version, latest)) {
150
+ console.log(`No update needed, current version is ${version}, latest release is ${latest}`);
150
151
  return;
151
152
  }
152
153
 
@@ -192,7 +193,7 @@ export function initializeProgram(version) {
192
193
  .argument("[directory]", "The name of the project directory")
193
194
  .action(async (directory) => {
194
195
  const state = new CLIState();
195
-
196
+
196
197
  try {
197
198
  // Render welcome screen with version
198
199
  renderWelcome(version);
package/templates.json CHANGED
@@ -3,7 +3,7 @@
3
3
  {
4
4
  "id": "nextjs-vercel",
5
5
  "name": "nextjs-vercel",
6
- "description": "Modern documentation with Next.js and Vercel deployment",
6
+ "description": "Next.js and Vercel deployment (optimized for vercel)",
7
7
  "features": [
8
8
  "Next.js 16",
9
9
  "React 19",
@@ -19,7 +19,7 @@
19
19
  {
20
20
  "id": "nextjs-docker",
21
21
  "name": "nextjs-docker",
22
- "description": "Modern documentation with Next.js standalone and Docker deployment",
22
+ "description": "Next.js standalone with Docker image (optimized for coolify, etc.)",
23
23
  "features": [
24
24
  "Next.js 16",
25
25
  "React 19",