mark-deco-cli 0.17.0 → 0.19.0
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/dist/index.cjs +4 -4
- package/dist/index.cjs.map +1 -1
- package/package.json +7 -7
package/dist/index.cjs
CHANGED
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
"use strict";
|
|
3
3
|
/*!
|
|
4
4
|
* name: mark-deco-cli
|
|
5
|
-
* version: 0.
|
|
5
|
+
* version: 0.19.0
|
|
6
6
|
* description: Command-line interface for mark-deco Markdown to HTML conversion processor
|
|
7
7
|
* author: Kouji Matsui (@kekyo@mi.kekyo.net)
|
|
8
8
|
* license: MIT
|
|
9
9
|
* repository.url: https://github.com/kekyo/mark-deco
|
|
10
|
-
* git.commit.hash:
|
|
10
|
+
* git.commit.hash: 0383f6b5dacf8b3d9c8d54b9ffad5180b3f58bea
|
|
11
11
|
*/
|
|
12
12
|
const commander = require("commander");
|
|
13
13
|
const promises = require("fs/promises");
|
|
@@ -15,11 +15,11 @@ const path = require("path");
|
|
|
15
15
|
const process$1 = require("process");
|
|
16
16
|
const markDeco = require("mark-deco");
|
|
17
17
|
const name = "mark-deco-cli";
|
|
18
|
-
const version = "0.
|
|
18
|
+
const version = "0.19.0";
|
|
19
19
|
const description = "Command-line interface for mark-deco Markdown to HTML conversion processor";
|
|
20
20
|
const author = "Kouji Matsui (@kekyo@mi.kekyo.net)";
|
|
21
21
|
const repository_url = "https://github.com/kekyo/mark-deco";
|
|
22
|
-
const git_commit_hash = "
|
|
22
|
+
const git_commit_hash = "0383f6b5dacf8b3d9c8d54b9ffad5180b3f58bea";
|
|
23
23
|
const loadConfig = async (configPath) => {
|
|
24
24
|
if (!configPath) {
|
|
25
25
|
return {};
|
package/dist/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.cjs","sources":["../src/generated/packageMetadata.ts","../src/config.ts","../src/io.ts","../src/processor.ts","../src/index.ts"],"sourcesContent":["// @ts-nocheck\n// This file is auto-generated by screw-up plugin\n// Do not edit manually\n\nexport const name = \"mark-deco-cli\";\nexport const version = \"0.17.0\";\nexport const description = \"Command-line interface for mark-deco Markdown to HTML conversion processor\";\nexport const author = \"Kouji Matsui (@kekyo@mi.kekyo.net)\";\nexport const license = \"MIT\";\nexport const repository_url = \"https://github.com/kekyo/mark-deco\";\nexport const git_commit_hash = \"50ed26c3accc15bee0957672d131f1a905d82351\";\n","// mark-deco - Flexible Markdown to HTML conversion library\n// Copyright (c) Kouji Matsui. (@kekyo@mi.kekyo.net)\n// Under MIT.\n// https://github.com/kekyo/mark-deco\n\nimport { readFile } from 'fs/promises';\nimport { resolve } from 'path';\n\nexport interface Config {\n plugins?: string[];\n noPlugins?: boolean;\n uniqueIdPrefix?: string;\n hierarchicalHeadingId?: boolean;\n contentBasedHeadingId?: boolean;\n headingBaseLevel?: number;\n headerTitleTransform?: 'extract' | 'extractAndRemove' | 'none';\n // Plugin-specific configurations\n oembed?: {\n enabled?: boolean;\n };\n card?: {\n enabled?: boolean;\n };\n mermaid?: {\n enabled?: boolean;\n };\n}\n\n/**\n * Load configuration from file\n */\nexport const loadConfig = async (configPath?: string): Promise<Config> => {\n if (!configPath) {\n return {};\n }\n\n try {\n const configFile = resolve(configPath);\n const configContent = await readFile(configFile, 'utf-8');\n\n // Support both JSON and JS config files\n if (configPath.endsWith('.json')) {\n return JSON.parse(configContent);\n } else if (\n configPath.endsWith('.js') ||\n configPath.endsWith('.cjs') ||\n configPath.endsWith('.mjs')\n ) {\n // For JS/MJS files, we need to use dynamic import\n const configModule = await import(configFile);\n return configModule.default || configModule;\n } else {\n // Default to JSON parsing\n return JSON.parse(configContent);\n }\n } catch (error) {\n throw new Error(\n `Failed to load config file \"${configPath}\": ${error instanceof Error ? error.message : String(error)}`\n );\n }\n};\n\n/**\n * Get default configuration\n */\nexport const getDefaultConfig = (): Config => {\n return {\n plugins: ['oembed', 'card', 'mermaid'],\n uniqueIdPrefix: 'section',\n hierarchicalHeadingId: true,\n contentBasedHeadingId: false,\n headingBaseLevel: 1,\n headerTitleTransform: 'extractAndRemove',\n oembed: {\n enabled: true,\n },\n card: {\n enabled: true,\n },\n mermaid: {\n enabled: true,\n },\n };\n};\n","// mark-deco - Flexible Markdown to HTML conversion library\n// Copyright (c) Kouji Matsui. (@kekyo@mi.kekyo.net)\n// Under MIT.\n// https://github.com/kekyo/mark-deco\n\nimport { readFile, writeFile } from 'fs/promises';\nimport { stdin } from 'process';\n\n/**\n * Read input from file or stdin\n */\nexport const readInput = async (inputPath?: string): Promise<string> => {\n if (inputPath) {\n // Read from file\n try {\n return await readFile(inputPath, 'utf-8');\n } catch (error) {\n throw new Error(\n `Failed to read input file \"${inputPath}\": ${error instanceof Error ? error.message : String(error)}`\n );\n }\n } else {\n // Read from stdin\n return new Promise((resolve, reject) => {\n let data = '';\n\n // Check if stdin is a TTY (interactive mode)\n if (stdin.isTTY) {\n reject(\n new Error(\n 'No input file specified and stdin is not available. Use -i option to specify input file.'\n )\n );\n return;\n }\n\n stdin.setEncoding('utf-8');\n\n stdin.on('data', (chunk) => {\n data += chunk;\n });\n\n stdin.on('end', () => {\n resolve(data);\n });\n\n stdin.on('error', (error) => {\n reject(new Error(`Failed to read from stdin: ${error.message}`));\n });\n });\n }\n};\n\n/**\n * Write output to file or stdout\n */\nexport const writeOutput = async (\n html: string,\n outputPath?: string\n): Promise<void> => {\n if (outputPath) {\n // Write to file\n try {\n await writeFile(outputPath, html, 'utf-8');\n } catch (error) {\n throw new Error(\n `Failed to write output file \"${outputPath}\": ${error instanceof Error ? error.message : String(error)}`\n );\n }\n } else {\n // Write to stdout\n try {\n process.stdout.write(html);\n } catch (error) {\n throw new Error(\n `Failed to write to stdout: ${error instanceof Error ? error.message : String(error)}`\n );\n }\n }\n};\n\n/**\n * Write JSON output to file\n */\nexport const writeJsonOutput = async (\n data: unknown,\n outputPath: string\n): Promise<void> => {\n try {\n const jsonContent = JSON.stringify(data, null, 2);\n await writeFile(outputPath, jsonContent, 'utf-8');\n } catch (error) {\n throw new Error(\n `Failed to write JSON output file \"${outputPath}\": ${error instanceof Error ? error.message : String(error)}`\n );\n }\n};\n","// mark-deco - Flexible Markdown to HTML conversion library\n// Copyright (c) Kouji Matsui. (@kekyo@mi.kekyo.net)\n// Under MIT.\n// https://github.com/kekyo/mark-deco\n\nimport {\n createMarkdownProcessor,\n createOEmbedPlugin,\n createCardPlugin,\n createMermaidPlugin,\n createCachedFetcher,\n createMemoryCacheStorage,\n getConsoleLogger,\n defaultProviderList,\n} from 'mark-deco';\nimport type { Config } from './config';\n\n// Import the MarkdownProcessor type - this should be available from mark-deco package\ntype MarkdownProcessor = ReturnType<typeof createMarkdownProcessor>;\n\n/**\n * Setup markdown processor with plugins based on configuration\n */\nexport const setupProcessor = (config: Config): MarkdownProcessor => {\n const plugins = [];\n const logger = getConsoleLogger();\n const fetcher = createCachedFetcher(\n 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.0.0 Safari/537.36',\n 5000,\n createMemoryCacheStorage()\n );\n\n // Determine which plugins to enable\n const enabledPlugins = config.noPlugins\n ? []\n : Array.isArray(config.plugins)\n ? config.plugins\n : ['oembed', 'card', 'mermaid'];\n\n // Add oEmbed plugin\n if (enabledPlugins.includes('oembed') && config.oembed?.enabled !== false) {\n plugins.push(createOEmbedPlugin(defaultProviderList, {}));\n }\n\n // Add card plugin\n if (enabledPlugins.includes('card') && config.card?.enabled !== false) {\n plugins.push(createCardPlugin({}));\n }\n\n // Add Mermaid plugin\n if (enabledPlugins.includes('mermaid') && config.mermaid?.enabled !== false) {\n plugins.push(createMermaidPlugin({}));\n }\n\n // Create and return processor\n return createMarkdownProcessor({\n plugins,\n logger,\n fetcher,\n });\n};\n","// mark-deco - Flexible Markdown to HTML conversion library\n// Copyright (c) Kouji Matsui. (@kekyo@mi.kekyo.net)\n// Under MIT.\n// https://github.com/kekyo/mark-deco\n\nimport { Command, Option } from 'commander';\nimport type { HeaderTitleTransform } from 'mark-deco';\n\nimport {\n author,\n description,\n git_commit_hash,\n name,\n repository_url,\n version,\n} from './generated/packageMetadata';\nimport { loadConfig } from './config';\nimport { readInput, writeOutput, writeJsonOutput } from './io';\nimport { setupProcessor } from './processor';\n\ninterface CLIOptions {\n input?: string;\n config?: string;\n output?: string;\n plugins?: string[];\n noPlugins?: boolean;\n uniqueIdPrefix?: string;\n hierarchicalHeadingId?: boolean;\n contentBasedHeadingId?: boolean;\n headingBaseLevel?: number;\n headerTitleTransform?: HeaderTitleTransform;\n frontmatterOutput?: string;\n headingTreeOutput?: string;\n}\n\nconst program = new Command();\n\nconst main = async () => {\n program\n .name(name)\n .summary(description)\n .version(`${version}-${git_commit_hash}`);\n\n program\n .addOption(\n new Option('-i, --input <file>', 'Input markdown file (default: stdin)')\n )\n .addOption(\n new Option('-o, --output <file>', 'Output HTML file (default: stdout)')\n )\n .addOption(new Option('-c, --config <file>', 'Configuration file path'))\n .addOption(\n new Option(\n '-p, --plugins [plugins...]',\n 'Enable specific plugins (oembed, card, mermaid)'\n )\n )\n .addOption(new Option('--no-plugins', 'Disable all default plugins'))\n .addOption(\n new Option(\n '--unique-id-prefix <prefix>',\n 'Prefix for unique IDs'\n ).default('section')\n )\n .addOption(\n new Option(\n '--hierarchical-heading-id',\n 'Use hierarchical heading IDs'\n ).default(true)\n )\n .addOption(\n new Option(\n '--content-based-heading-id',\n 'Use content-based heading IDs'\n ).default(false)\n )\n .addOption(\n new Option(\n '--heading-base-level <level>',\n 'Base heading level for markdown headings'\n )\n .argParser((value) => Number.parseInt(value, 10))\n .default(1)\n )\n .addOption(\n new Option(\n '--header-title-transform <mode>',\n 'Control how the first base-level heading is applied to frontmatter.title (extract, extractAndRemove, none)'\n ).choices(['extract', 'extractAndRemove', 'none'])\n )\n .addOption(\n new Option(\n '--frontmatter-output <file>',\n 'Output frontmatter as JSON to specified file'\n )\n )\n .addOption(\n new Option(\n '--heading-tree-output <file>',\n 'Output heading tree as JSON to specified file'\n )\n )\n .action(async () => {\n const options = program.opts<CLIOptions>();\n try {\n // Load configuration\n const config = await loadConfig(options.config);\n\n // Merge CLI options with config\n const mergedOptions = { ...config, ...options };\n\n // Read input\n const markdown = await readInput(options.input);\n\n // Setup processor with plugins\n const processor = setupProcessor(mergedOptions);\n\n // Process markdown\n const headerTitleTransform: HeaderTitleTransform =\n options.headerTitleTransform ??\n config.headerTitleTransform ??\n 'extractAndRemove';\n const headingBaseLevel =\n options.headingBaseLevel ?? config.headingBaseLevel ?? 1;\n\n const result = await processor.process(\n markdown,\n options.uniqueIdPrefix || 'section',\n {\n useHierarchicalHeadingId: options.hierarchicalHeadingId ?? true,\n useContentStringHeaderId: options.contentBasedHeadingId ?? false,\n headingBaseLevel,\n headerTitleTransform,\n }\n );\n\n // Write output\n await writeOutput(result.html, options.output);\n\n // Write frontmatter if output path is specified\n if (options.frontmatterOutput) {\n await writeJsonOutput(result.frontmatter, options.frontmatterOutput);\n }\n\n // Write heading tree if output path is specified\n if (options.headingTreeOutput) {\n await writeJsonOutput(result.headingTree, options.headingTreeOutput);\n }\n } catch (error) {\n console.error(\n 'Error:',\n error instanceof Error ? error.message : String(error)\n );\n process.exit(1);\n }\n });\n\n // Handle unhandled errors\n process.on('unhandledRejection', (reason, promise) => {\n console.error('Unhandled Rejection at:', promise, 'reason:', reason);\n process.exit(1);\n });\n\n process.on('uncaughtException', (error) => {\n console.error('Uncaught Exception:', error);\n process.exit(1);\n });\n\n // Parse command line arguments\n const userArgs = process.argv.slice(2);\n if (\n userArgs.length === 0 ||\n userArgs.includes('--help') ||\n userArgs.includes('-h')\n ) {\n console.log(`${name} [${version}-${git_commit_hash}]`);\n console.log(description);\n console.log(`Copyright (c) ${author}`);\n console.log(repository_url);\n console.log('License: Under MIT');\n console.log('');\n }\n program.parse();\n};\n\n// Run the main function\nmain().catch((error) => {\n console.error('Failed to start CLI:', error);\n process.exit(1);\n});\n"],"names":["resolve","readFile","stdin","writeFile","getConsoleLogger","createCachedFetcher","createMemoryCacheStorage","createOEmbedPlugin","defaultProviderList","createCardPlugin","createMermaidPlugin","createMarkdownProcessor","Command","Option"],"mappings":";;;;;;;;;;;;;;;;AAIO,MAAM,OAAO;AACb,MAAM,UAAU;AAChB,MAAM,cAAc;AACpB,MAAM,SAAS;AAEf,MAAM,iBAAiB;AACvB,MAAM,kBAAkB;ACqBxB,MAAM,aAAa,OAAO,eAAyC;AACxE,MAAI,CAAC,YAAY;AACf,WAAO,CAAA;AAAA,EACT;AAEA,MAAI;AACF,UAAM,aAAaA,KAAAA,QAAQ,UAAU;AACrC,UAAM,gBAAgB,MAAMC,kBAAS,YAAY,OAAO;AAGxD,QAAI,WAAW,SAAS,OAAO,GAAG;AAChC,aAAO,KAAK,MAAM,aAAa;AAAA,IACjC,WACE,WAAW,SAAS,KAAK,KACzB,WAAW,SAAS,MAAM,KAC1B,WAAW,SAAS,MAAM,GAC1B;AAEA,YAAM,eAAe,MAAM,OAAO;AAClC,aAAO,aAAa,WAAW;AAAA,IACjC,OAAO;AAEL,aAAO,KAAK,MAAM,aAAa;AAAA,IACjC;AAAA,EACF,SAAS,OAAO;AACd,UAAM,IAAI;AAAA,MACR,+BAA+B,UAAU,MAAM,iBAAiB,QAAQ,MAAM,UAAU,OAAO,KAAK,CAAC;AAAA,IAAA;AAAA,EAEzG;AACF;ACjDO,MAAM,YAAY,OAAO,cAAwC;AACtE,MAAI,WAAW;AAEb,QAAI;AACF,aAAO,MAAMA,SAAAA,SAAS,WAAW,OAAO;AAAA,IAC1C,SAAS,OAAO;AACd,YAAM,IAAI;AAAA,QACR,8BAA8B,SAAS,MAAM,iBAAiB,QAAQ,MAAM,UAAU,OAAO,KAAK,CAAC;AAAA,MAAA;AAAA,IAEvG;AAAA,EACF,OAAO;AAEL,WAAO,IAAI,QAAQ,CAAC,SAAS,WAAW;AACtC,UAAI,OAAO;AAGX,UAAIC,UAAAA,MAAM,OAAO;AACf;AAAA,UACE,IA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,gBAAgB,OAAO,aAAa,QAAQ,iBAAiB;AAAA,MACrE;AAGA,UAAI,QAAQ,mBAAmB;AAC7B,cAAM,gBAAgB,OAAO,aAAa,QAAQ,iBAAiB;AAAA,MACrE;AAAA,IACF,SAAS,OAAO;AACd,cAAQ;AAAA,QACN;AAAA,QACA,iBAAiB,QAAQ,MAAM,UAAU,OAAO,KAAK;AAAA,MAAA;AAEvD,cAAQ,KAAK,CAAC;AAAA,IAChB;AAAA,EACF,CAAC;AAGH,UAAQ,GAAG,sBAAsB,CAAC,QAAQ,YAAY;AACpD,YAAQ,MAAM,2BAA2B,SAAS,WAAW,MAAM;AACnE,YAAQ,KAAK,CAAC;AAAA,EAChB,CAAC;AAED,UAAQ,GAAG,qBAAqB,CAAC,UAAU;AACzC,YAAQ,MAAM,uBAAuB,KAAK;AAC1C,YAAQ,KAAK,CAAC;AAAA,EAChB,CAAC;AAGD,QAAM,WAAW,QAAQ,KAAK,MAAM,CAAC;AACrC,MACE,SAAS,WAAW,KACpB,SAAS,SAAS,QAAQ,KAC1B,SAAS,SAAS,IAAI,GACtB;AACA,YAAQ,IAAI,GAAG,IAAI,KAAK,OAAO,IAAI,eAAe,GAAG;AACrD,YAAQ,IAAI,WAAW;AACvB,YAAQ,IAAI,iBAAiB,MAAM,EAAE;AACrC,YAAQ,IAAI,cAAc;AAC1B,YAAQ,IAAI,oBAAoB;AAChC,YAAQ,IAAI,EAAE;AAAA,EAChB;AACA,UAAQ,MAAA;AACV;AAGA,OAAO,MAAM,CAAC,UAAU;AACtB,UAAQ,MAAM,wBAAwB,KAAK;AAC3C,UAAQ,KAAK,CAAC;AAChB,CAAC;"}
|
|
1
|
+
{"version":3,"file":"index.cjs","sources":["../src/generated/packageMetadata.ts","../src/config.ts","../src/io.ts","../src/processor.ts","../src/index.ts"],"sourcesContent":["// @ts-nocheck\n// This file is auto-generated by screw-up plugin\n// Do not edit manually\n\nexport const name = \"mark-deco-cli\";\nexport const version = \"0.19.0\";\nexport const description = \"Command-line interface for mark-deco Markdown to HTML conversion processor\";\nexport const author = \"Kouji Matsui (@kekyo@mi.kekyo.net)\";\nexport const license = \"MIT\";\nexport const repository_url = \"https://github.com/kekyo/mark-deco\";\nexport const git_commit_hash = \"0383f6b5dacf8b3d9c8d54b9ffad5180b3f58bea\";\n","// mark-deco - Flexible Markdown to HTML conversion library\n// Copyright (c) Kouji Matsui. (@kekyo@mi.kekyo.net)\n// Under MIT.\n// https://github.com/kekyo/mark-deco\n\nimport { readFile } from 'fs/promises';\nimport { resolve } from 'path';\n\nexport interface Config {\n plugins?: string[];\n noPlugins?: boolean;\n uniqueIdPrefix?: string;\n hierarchicalHeadingId?: boolean;\n contentBasedHeadingId?: boolean;\n headingBaseLevel?: number;\n headerTitleTransform?: 'extract' | 'extractAndRemove' | 'none';\n // Plugin-specific configurations\n oembed?: {\n enabled?: boolean;\n };\n card?: {\n enabled?: boolean;\n };\n mermaid?: {\n enabled?: boolean;\n };\n}\n\n/**\n * Load configuration from file\n */\nexport const loadConfig = async (configPath?: string): Promise<Config> => {\n if (!configPath) {\n return {};\n }\n\n try {\n const configFile = resolve(configPath);\n const configContent = await readFile(configFile, 'utf-8');\n\n // Support both JSON and JS config files\n if (configPath.endsWith('.json')) {\n return JSON.parse(configContent);\n } else if (\n configPath.endsWith('.js') ||\n configPath.endsWith('.cjs') ||\n configPath.endsWith('.mjs')\n ) {\n // For JS/MJS files, we need to use dynamic import\n const configModule = await import(configFile);\n return configModule.default || configModule;\n } else {\n // Default to JSON parsing\n return JSON.parse(configContent);\n }\n } catch (error) {\n throw new Error(\n `Failed to load config file \"${configPath}\": ${error instanceof Error ? error.message : String(error)}`\n );\n }\n};\n\n/**\n * Get default configuration\n */\nexport const getDefaultConfig = (): Config => {\n return {\n plugins: ['oembed', 'card', 'mermaid'],\n uniqueIdPrefix: 'section',\n hierarchicalHeadingId: true,\n contentBasedHeadingId: false,\n headingBaseLevel: 1,\n headerTitleTransform: 'extractAndRemove',\n oembed: {\n enabled: true,\n },\n card: {\n enabled: true,\n },\n mermaid: {\n enabled: true,\n },\n };\n};\n","// mark-deco - Flexible Markdown to HTML conversion library\n// Copyright (c) Kouji Matsui. (@kekyo@mi.kekyo.net)\n// Under MIT.\n// https://github.com/kekyo/mark-deco\n\nimport { readFile, writeFile } from 'fs/promises';\nimport { stdin } from 'process';\n\n/**\n * Read input from file or stdin\n */\nexport const readInput = async (inputPath?: string): Promise<string> => {\n if (inputPath) {\n // Read from file\n try {\n return await readFile(inputPath, 'utf-8');\n } catch (error) {\n throw new Error(\n `Failed to read input file \"${inputPath}\": ${error instanceof Error ? error.message : String(error)}`\n );\n }\n } else {\n // Read from stdin\n return new Promise((resolve, reject) => {\n let data = '';\n\n // Check if stdin is a TTY (interactive mode)\n if (stdin.isTTY) {\n reject(\n new Error(\n 'No input file specified and stdin is not available. Use -i option to specify input file.'\n )\n );\n return;\n }\n\n stdin.setEncoding('utf-8');\n\n stdin.on('data', (chunk) => {\n data += chunk;\n });\n\n stdin.on('end', () => {\n resolve(data);\n });\n\n stdin.on('error', (error) => {\n reject(new Error(`Failed to read from stdin: ${error.message}`));\n });\n });\n }\n};\n\n/**\n * Write output to file or stdout\n */\nexport const writeOutput = async (\n html: string,\n outputPath?: string\n): Promise<void> => {\n if (outputPath) {\n // Write to file\n try {\n await writeFile(outputPath, html, 'utf-8');\n } catch (error) {\n throw new Error(\n `Failed to write output file \"${outputPath}\": ${error instanceof Error ? error.message : String(error)}`\n );\n }\n } else {\n // Write to stdout\n try {\n process.stdout.write(html);\n } catch (error) {\n throw new Error(\n `Failed to write to stdout: ${error instanceof Error ? error.message : String(error)}`\n );\n }\n }\n};\n\n/**\n * Write JSON output to file\n */\nexport const writeJsonOutput = async (\n data: unknown,\n outputPath: string\n): Promise<void> => {\n try {\n const jsonContent = JSON.stringify(data, null, 2);\n await writeFile(outputPath, jsonContent, 'utf-8');\n } catch (error) {\n throw new Error(\n `Failed to write JSON output file \"${outputPath}\": ${error instanceof Error ? error.message : String(error)}`\n );\n }\n};\n","// mark-deco - Flexible Markdown to HTML conversion library\n// Copyright (c) Kouji Matsui. (@kekyo@mi.kekyo.net)\n// Under MIT.\n// https://github.com/kekyo/mark-deco\n\nimport {\n createMarkdownProcessor,\n createOEmbedPlugin,\n createCardPlugin,\n createMermaidPlugin,\n createCachedFetcher,\n createMemoryCacheStorage,\n getConsoleLogger,\n defaultProviderList,\n} from 'mark-deco';\nimport type { Config } from './config';\n\n// Import the MarkdownProcessor type - this should be available from mark-deco package\ntype MarkdownProcessor = ReturnType<typeof createMarkdownProcessor>;\n\n/**\n * Setup markdown processor with plugins based on configuration\n */\nexport const setupProcessor = (config: Config): MarkdownProcessor => {\n const plugins = [];\n const logger = getConsoleLogger();\n const fetcher = createCachedFetcher(\n 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.0.0 Safari/537.36',\n 5000,\n createMemoryCacheStorage()\n );\n\n // Determine which plugins to enable\n const enabledPlugins = config.noPlugins\n ? []\n : Array.isArray(config.plugins)\n ? config.plugins\n : ['oembed', 'card', 'mermaid'];\n\n // Add oEmbed plugin\n if (enabledPlugins.includes('oembed') && config.oembed?.enabled !== false) {\n plugins.push(createOEmbedPlugin(defaultProviderList, {}));\n }\n\n // Add card plugin\n if (enabledPlugins.includes('card') && config.card?.enabled !== false) {\n plugins.push(createCardPlugin({}));\n }\n\n // Add Mermaid plugin\n if (enabledPlugins.includes('mermaid') && config.mermaid?.enabled !== false) {\n plugins.push(createMermaidPlugin({}));\n }\n\n // Create and return processor\n return createMarkdownProcessor({\n plugins,\n logger,\n fetcher,\n });\n};\n","// mark-deco - Flexible Markdown to HTML conversion library\n// Copyright (c) Kouji Matsui. (@kekyo@mi.kekyo.net)\n// Under MIT.\n// https://github.com/kekyo/mark-deco\n\nimport { Command, Option } from 'commander';\nimport type { HeaderTitleTransform } from 'mark-deco';\n\nimport {\n author,\n description,\n git_commit_hash,\n name,\n repository_url,\n version,\n} from './generated/packageMetadata';\nimport { loadConfig } from './config';\nimport { readInput, writeOutput, writeJsonOutput } from './io';\nimport { setupProcessor } from './processor';\n\ninterface CLIOptions {\n input?: string;\n config?: string;\n output?: string;\n plugins?: string[];\n noPlugins?: boolean;\n uniqueIdPrefix?: string;\n hierarchicalHeadingId?: boolean;\n contentBasedHeadingId?: boolean;\n headingBaseLevel?: number;\n headerTitleTransform?: HeaderTitleTransform;\n frontmatterOutput?: string;\n headingTreeOutput?: string;\n}\n\nconst program = new Command();\n\nconst main = async () => {\n program\n .name(name)\n .summary(description)\n .version(`${version}-${git_commit_hash}`);\n\n program\n .addOption(\n new Option('-i, --input <file>', 'Input markdown file (default: stdin)')\n )\n .addOption(\n new Option('-o, --output <file>', 'Output HTML file (default: stdout)')\n )\n .addOption(new Option('-c, --config <file>', 'Configuration file path'))\n .addOption(\n new Option(\n '-p, --plugins [plugins...]',\n 'Enable specific plugins (oembed, card, mermaid)'\n )\n )\n .addOption(new Option('--no-plugins', 'Disable all default plugins'))\n .addOption(\n new Option(\n '--unique-id-prefix <prefix>',\n 'Prefix for unique IDs'\n ).default('section')\n )\n .addOption(\n new Option(\n '--hierarchical-heading-id',\n 'Use hierarchical heading IDs'\n ).default(true)\n )\n .addOption(\n new Option(\n '--content-based-heading-id',\n 'Use content-based heading IDs'\n ).default(false)\n )\n .addOption(\n new Option(\n '--heading-base-level <level>',\n 'Base heading level for markdown headings'\n )\n .argParser((value) => Number.parseInt(value, 10))\n .default(1)\n )\n .addOption(\n new Option(\n '--header-title-transform <mode>',\n 'Control how the first base-level heading is applied to frontmatter.title (extract, extractAndRemove, none)'\n ).choices(['extract', 'extractAndRemove', 'none'])\n )\n .addOption(\n new Option(\n '--frontmatter-output <file>',\n 'Output frontmatter as JSON to specified file'\n )\n )\n .addOption(\n new Option(\n '--heading-tree-output <file>',\n 'Output heading tree as JSON to specified file'\n )\n )\n .action(async () => {\n const options = program.opts<CLIOptions>();\n try {\n // Load configuration\n const config = await loadConfig(options.config);\n\n // Merge CLI options with config\n const mergedOptions = { ...config, ...options };\n\n // Read input\n const markdown = await readInput(options.input);\n\n // Setup processor with plugins\n const processor = setupProcessor(mergedOptions);\n\n // Process markdown\n const headerTitleTransform: HeaderTitleTransform =\n options.headerTitleTransform ??\n config.headerTitleTransform ??\n 'extractAndRemove';\n const headingBaseLevel =\n options.headingBaseLevel ?? config.headingBaseLevel ?? 1;\n\n const result = await processor.process(\n markdown,\n options.uniqueIdPrefix || 'section',\n {\n useHierarchicalHeadingId: options.hierarchicalHeadingId ?? true,\n useContentStringHeaderId: options.contentBasedHeadingId ?? false,\n headingBaseLevel,\n headerTitleTransform,\n }\n );\n\n // Write output\n await writeOutput(result.html, options.output);\n\n // Write frontmatter if output path is specified\n if (options.frontmatterOutput) {\n await writeJsonOutput(result.frontmatter, options.frontmatterOutput);\n }\n\n // Write heading tree if output path is specified\n if (options.headingTreeOutput) {\n await writeJsonOutput(result.headingTree, options.headingTreeOutput);\n }\n } catch (error) {\n console.error(\n 'Error:',\n error instanceof Error ? error.message : String(error)\n );\n process.exit(1);\n }\n });\n\n // Handle unhandled errors\n process.on('unhandledRejection', (reason, promise) => {\n console.error('Unhandled Rejection at:', promise, 'reason:', reason);\n process.exit(1);\n });\n\n process.on('uncaughtException', (error) => {\n console.error('Uncaught Exception:', error);\n process.exit(1);\n });\n\n // Parse command line arguments\n const userArgs = process.argv.slice(2);\n if (\n userArgs.length === 0 ||\n userArgs.includes('--help') ||\n userArgs.includes('-h')\n ) {\n console.log(`${name} [${version}-${git_commit_hash}]`);\n console.log(description);\n console.log(`Copyright (c) ${author}`);\n console.log(repository_url);\n console.log('License: Under MIT');\n console.log('');\n }\n program.parse();\n};\n\n// Run the main function\nmain().catch((error) => {\n console.error('Failed to start CLI:', error);\n process.exit(1);\n});\n"],"names":["resolve","readFile","stdin","writeFile","getConsoleLogger","createCachedFetcher","createMemoryCacheStorage","createOEmbedPlugin","defaultProviderList","createCardPlugin","createMermaidPlugin","createMarkdownProcessor","Command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": "2026-01-
|
|
11
|
+
"hash": "0383f6b5dacf8b3d9c8d54b9ffad5180b3f58bea",
|
|
12
|
+
"shortHash": "0383f6b",
|
|
13
|
+
"date": "2026-01-17T12:24:55+09:00",
|
|
14
14
|
"message": "Merge branch 'develop'"
|
|
15
15
|
}
|
|
16
16
|
},
|
|
17
|
-
"version": "0.
|
|
17
|
+
"version": "0.19.0",
|
|
18
18
|
"description": "Command-line interface for mark-deco Markdown to HTML conversion processor",
|
|
19
19
|
"name": "mark-deco-cli",
|
|
20
20
|
"keywords": [
|
|
@@ -66,5 +66,5 @@
|
|
|
66
66
|
"vite": ">=6.3.5",
|
|
67
67
|
"vitest": ">=1.0.0"
|
|
68
68
|
},
|
|
69
|
-
"buildDate": "2026-01-
|
|
69
|
+
"buildDate": "2026-01-17T12:26:48+09:00"
|
|
70
70
|
}
|