From 1696aa982148a2e3dd16b39762883270517bd763 Mon Sep 17 00:00:00 2001 From: gesslar <1266935+gesslar@users.noreply.github.com> Date: Sat, 21 Feb 2026 21:58:41 -0500 Subject: [PATCH] chore: update dev tooling and project metadata Co-Authored-By: Claude Sonnet 4.6 --- .gitignore | 2 + .vscode/launch.json | 139 ++++++----------------- .vscode/settings.json | 1 - README.md | 4 +- UNLICENSE.txt | 24 ++++ bin | 1 - eslint.config.js | 255 ++---------------------------------------- 7 files changed, 70 insertions(+), 356 deletions(-) create mode 100644 UNLICENSE.txt delete mode 120000 bin diff --git a/.gitignore b/.gitignore index 8a305a1..c16e026 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,5 @@ node_modules .env **/*.tgz work/ +.claude/ +output/ diff --git a/.vscode/launch.json b/.vscode/launch.json index 6ab0b4a..20acf71 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -2,7 +2,7 @@ "version": "0.2.0", "configurations": [ { - "name": "CLI - LPCDocs to Markdown (Lang, Format)", + "name": "CLI - LPCDocs to Markdown (Specific)", "type": "node", "request": "launch", "skipFiles": [ @@ -13,19 +13,21 @@ "--debug", "--debugLevel", "4", + "-C", + "100", "--input", "examples/source/lpc/**/*.c", "--output", "examples/output/markdown/", "--parser", "examples/node_modules_test/bedoc-lpc-parser/bedoc-lpc-parser.js", - "--printer", - "examples/node_modules_test/bedoc-markdown-printer/bedoc-markdown-printer.js", + "--formatter", + "examples/node_modules_test/bedoc-markdown-formatter/bedoc-markdown-formatter.js", ], "console": "integratedTerminal" }, { - "name": "CLI - LPCDocs to Markdown (Specific, Hooks)", + "name": "CLI - LPCDocs to Markdown (Discovery)", "type": "node", "request": "launch", "skipFiles": [ @@ -35,49 +37,22 @@ "args": [ "--debug", "--debugLevel", - "1", + "4", + "-C", + "100", "--input", "examples/source/lpc/**/*.c", "--output", "examples/output/markdown/", - "--parser", - "examples/node_modules_test/bedoc-lpc-parser/bedoc-lpc-parser.js", - "--printer", - "examples/node_modules_test/bedoc-markdown-printer/bedoc-markdown-printer.js", - "--hooks", - "examples/hooks/lpc-markdown-hooks.js" - ], - "console": "integratedTerminal" - }, - { - "name": "CLI - LPCDocs to Wikitext (Lang, Format, Hooks)", - "type": "node", - "request": "launch", - "skipFiles": [ - "/**" - ], - "program": "${workspaceFolder}/src/cli.js", - "args": [ - "--debug", - "--debugLevel", - "5", - "--input", - "examples/source/lpc/**/*.c", - "--output", - "examples/output/wikitext/", "--language", "lpc", "--format", - "wikitext", - "--hooks", - "examples/hooks/lpc-wikitext-hooks.js", - "--maxConcurrent", - "50" + "markdown", ], "console": "integratedTerminal" }, { - "name": "CLI - LPCDocs to Wikitext (Specific, Hooks)", + "name": "CLI - LPCDocs to Markdown (Discovery, Hooks)", "type": "node", "request": "launch", "skipFiles": [ @@ -87,22 +62,24 @@ "args": [ "--debug", "--debugLevel", - "1", + "4", + "-C", + "100", "--input", "examples/source/lpc/**/*.c", "--output", - "examples/output/wikitext/", - "--parser", - "examples/node_modules_test/bedoc-lpc-parser/bedoc-lpc-parser.js", - "--printer", - "examples/node_modules_test/bedoc-wikitext-printer/bedoc-wikitext-printer.js", + "examples/output/markdown/", + "--language", + "lpc", + "--format", + "markdown", "--hooks", - "examples/hooks/lpc-wikitext-hooks.js" + "examples/hooks/lpc-markdown-hooks.js" ], "console": "integratedTerminal" }, { - "name": "CLI - LPCDocs to Wikitext (Specific, Hooks, Upload)", + "name": "CLI - LPCDocs to wikitext (Discovery, Hooks, Upload)", "type": "node", "request": "launch", "skipFiles": [ @@ -110,26 +87,26 @@ ], "program": "${workspaceFolder}/src/cli.js", "args": [ - "--maxConcurrent", - "50", "--debug", "--debugLevel", - "1", + "4", + "-C", + "100", "--input", - "examples/source/lpc/**/*.c", + "examples/source/lpc/base64.c", "--output", "examples/output/wikitext/", - "--parser", - "examples/node_modules_test/bedoc-lpc-parser/bedoc-lpc-parser.js", - "--printer", - "examples/node_modules_test/bedoc-wikitext-printer/bedoc-wikitext-printer.js", + "--language", + "lpc", + "--format", + "markdown", "--hooks", "examples/hooks/lpc-wikitext-hooks-with-upload.js" ], "console": "integratedTerminal" }, { - "name": "CLI - LuaDocs to Markdown (Lang, Format, Hooks)", + "name": "CLI - LuaDocs to Markdown (Discovery)", "type": "node", "request": "launch", "skipFiles": [ @@ -139,7 +116,9 @@ "args": [ "--debug", "--debugLevel", - "1", + "4", + "-C", + "100", "--input", "examples/source/lua/**/*.lua", "--output", @@ -148,58 +127,8 @@ "lua", "--format", "markdown", - "--hooks", - "examples/hooks/lua-markdown-hooks.js" - ], - "console": "integratedTerminal", - }, - { - "name": "CLI - LuaDocs to Wikitext (Lang, Format, Hooks)", - "type": "node", - "request": "launch", - "skipFiles": [ - "/**" ], - "program": "${workspaceFolder}/src/cli.js", - "args": [ - "--debug", - "--debugLevel", - "1", - "--input", - "examples/source/lua/**/*.lua", - "--output", - "examples/output/wikitext/", - "--language", - "lua", - "--format", - "wikitext", - "--hooks", - "examples/hooks/lua-wikitext-hooks.js", - ], - "console": "integratedTerminal", - }, - { - "name": "Chokidar - LPCDocs to Wikitext (Lang, Format, Hooks, Upload)", - "type": "node", - "request": "launch", - "skipFiles": [ - "/**" - ], - "program": "${workspaceFolder}/examples/chokidar-as-cli/index.js", - "cwd": "${workspaceFolder}/examples/chokidar-as-cli", - "args": [], - "console": "integratedTerminal", - }, - { - "name": "Chokidar - LPCDocs to Wikitext (NPM)", - "type": "node", - "request": "launch", - "skipFiles": [ - "/**" - ], - "program": "${workspaceFolder}/examples/chokidar-as-npm/index.js", - "cwd": "${workspaceFolder}/examples/chokidar-as-npm", - "console": "integratedTerminal", + "console": "integratedTerminal" }, ] } diff --git a/.vscode/settings.json b/.vscode/settings.json index 9ce5d9b..be16e2a 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -15,5 +15,4 @@ "files.trimTrailingWhitespace": true, "files.trimFinalNewlines": true, "files.eol": "\n", - "vscode-lua-format.configPath": "examples\\source\\lua\\lua.editorconfig", } diff --git a/README.md b/README.md index 0b547c4..ed19a09 100644 --- a/README.md +++ b/README.md @@ -7,14 +7,14 @@ **BeDoc** is a powerful, pluggable documentation generator designed to handle any programming language and output format. With its extensible framework, you -can easily create custom parsers and printers to generate structured +can easily create custom parsers and formatters to generate structured documentation for your projects. --- ## Key Features -- **Pluggable Design**: BeDoc works seamlessly with custom parsers and printers +- **Pluggable Design**: BeDoc works seamlessly with custom parsers and formatters to fit your unique needs. BeDoc also supports async operations, allowing for efficient handling of large projects. - **Customizable Input**: Accommodate any text input, whether it’s a well-known diff --git a/UNLICENSE.txt b/UNLICENSE.txt new file mode 100644 index 0000000..f50ef62 --- /dev/null +++ b/UNLICENSE.txt @@ -0,0 +1,24 @@ +This is free and unencumbered software released into the public domain. + +Anyone is free to copy, modify, publish, use, compile, sell, or +distribute this software, either in source code form or as a compiled +binary, for any purpose, commercial or non-commercial, and by any +means. + +In jurisdictions that recognize copyright laws, the author or authors +of this software dedicate any and all copyright interest in the +software to the public domain. We make this dedication for the benefit +of the public at large and to the detriment of our heirs and +successors. We intend this dedication to be an overt act of +relinquishment in perpetuity of all present and future rights to this +software under copyright law. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. +IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR +OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +For more information, please refer to diff --git a/bin b/bin deleted file mode 120000 index 7111267..0000000 --- a/bin +++ /dev/null @@ -1 +0,0 @@ -/home/gesslar/bin \ No newline at end of file diff --git a/eslint.config.js b/eslint.config.js index 85e987b..9b2a046 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -1,250 +1,11 @@ -import js from "@eslint/js" -import jsdoc from "eslint-plugin-jsdoc" -import stylistic from "@stylistic/eslint-plugin" -import globals from "globals" -import jsdoc from "eslint-plugin-jsdoc" -import stylistic from "@stylistic/eslint-plugin" -import globals from "globals" +import uglify from "@gesslar/uglier" export default [ - js.configs.recommended, - jsdoc.configs['flat/recommended'], { - name: "gesslar/uglier/ignores", - ignores: [], - name: "gesslar/uglier/ignores", - ignores: [], - }, { - name: "gesslar/uglier/languageOptions", - name: "gesslar/uglier/languageOptions", - languageOptions: { - ecmaVersion: "latest", - sourceType: "module", - globals: { - ...globals.node, - ...globals.node, - fetch: "readonly", - Headers: "readonly", - }, - }, - }, - // Add override for webview files to include browser globals - { - name: "gesslar/uglier/webview-env", - files: ["src/webview/**/*.{js,mjs,cjs}"], - languageOptions: { - globals: { - ...globals.browser, - acquireVsCodeApi: "readonly" - } - } - }, - // Add override for .cjs files to treat as CommonJS - { - name: "gesslar/uglier/webview-env", - files: ["src/webview/**/*.{js,mjs,cjs}"], - languageOptions: { - globals: { - ...globals.browser, - acquireVsCodeApi: "readonly" - } - } - }, - // Add override for .cjs files to treat as CommonJS - { - name: "gesslar/uglier/webview-env", - files: ["src/webview/**/*.{js,mjs,cjs}"], - languageOptions: { - globals: { - ...globals.browser, - acquireVsCodeApi: "readonly" - } - } - }, - // Add override for .cjs files to treat as CommonJS - { - name: "gesslar/uglier/cjs-override", - files: ["src/**/*.cjs"], - languageOptions: { - sourceType: "script", - ecmaVersion: 2021 - }, - }, - // Add override for .mjs files to treat as ES modules - { - name: "gesslar/uglier/mjs-override", - files: ["src/**/*.mjs"], - languageOptions: { - sourceType: "module", - ecmaVersion: 2021 - } - }, - { - name: "gesslar/uglier/lints-js", - files: ["src/**/*.{mjs,cjs,js}"], - plugins: { - "@stylistic": stylistic, - "@stylistic": stylistic, - }, - rules: { - "@stylistic/arrow-parens": ["error", "as-needed"], - "@stylistic/arrow-spacing": ["error", { before: true, after: true }], - "@stylistic/brace-style": ["error", "1tbs", {allowSingleLine: false}], - "@stylistic/nonblock-statement-body-position": ["error", "below"], - "@stylistic/padding-line-between-statements": [ - "@stylistic/arrow-parens": ["error", "as-needed"], - "@stylistic/arrow-spacing": ["error", { before: true, after: true }], - "@stylistic/brace-style": ["error", "1tbs", {allowSingleLine: false}], - "@stylistic/nonblock-statement-body-position": ["error", "below"], - "@stylistic/padding-line-between-statements": [ - "error", - {blankLine: "always", prev: "if", next: "*"}, - {blankLine: "always", prev: "*", next: "return"}, - {blankLine: "always", prev: "while", next: "*"}, - {blankLine: "always", prev: "for", next: "*"}, - {blankLine: "always", prev: "switch", next: "*"}, - {blankLine: "always", prev: "do", next: "*"}, - {blankLine: "always", prev: ["const", "let", "var"], next: "*"}, - {blankLine: "any", prev: ["const", "let", "var"], next: ["const", "let", "var"]}, - {blankLine: "always", prev: "directive", next: "*" }, - {blankLine: "any", prev: "directive", next: "directive" }, - ], - "@stylistic/eol-last": ["error", "always"], - "@stylistic/indent": ["error", 2, { - {blankLine: "always", prev: "if", next: "*"}, - {blankLine: "always", prev: "*", next: "return"}, - {blankLine: "always", prev: "while", next: "*"}, - {blankLine: "always", prev: "for", next: "*"}, - {blankLine: "always", prev: "switch", next: "*"}, - {blankLine: "always", prev: "do", next: "*"}, - {blankLine: "always", prev: ["const", "let", "var"], next: "*"}, - {blankLine: "any", prev: ["const", "let", "var"], next: ["const", "let", "var"]}, - {blankLine: "always", prev: "directive", next: "*" }, - {blankLine: "any", prev: "directive", next: "directive" }, - ], - "@stylistic/eol-last": ["error", "always"], - "@stylistic/indent": ["error", 2, { - SwitchCase: 1 // Indents `case` statements one level deeper than `switch` - }], - "@stylistic/key-spacing": ["error", { beforeColon: false, afterColon: true }], - "@stylistic/keyword-spacing": ["error", { - "@stylistic/key-spacing": ["error", { beforeColon: false, afterColon: true }], - "@stylistic/keyword-spacing": ["error", { - before: false, - after: true, - overrides: { - // Control statements - return: { before: true, after: true }, - if: { after: false }, - else: { before: true, after: true }, - for: { after: false }, - while: { before: true, after: false }, - do: { after: true }, - while: { before: true, after: false }, - do: { after: true }, - switch: { after: false }, - case: { before: true, after: true }, - throw: { before: true, after: false } , - - // Keywords - as: { before: true, after: true }, - of: { before: true, after: true }, - from: { before: true, after: true }, - async: { before: true, after: true }, - await: { before: true, after: false }, - class: { before: true, after: true }, - const: { before: true, after: true }, - let: { before: true, after: true }, - var: { before: true, after: true }, - - // Exception handling - catch: { before: true, after: true }, - catch: { before: true, after: true }, - finally: { before: true, after: true }, - } - }], - // Blocks - "@stylistic/space-before-blocks": ["error", "always"], - "@stylistic/max-len": ["warn", { - // Blocks - "@stylistic/space-before-blocks": ["error", "always"], - "@stylistic/max-len": ["warn", { - code: 80, - ignoreComments: true, - ignoreComments: true, - ignoreUrls: true, - ignoreStrings: true, - ignoreTemplateLiterals: true, - ignoreRegExpLiterals: true, - tabWidth: 2 - }], - "@stylistic/no-tabs": "error", - "@stylistic/no-trailing-spaces": ["error"], - "@stylistic/object-curly-spacing": ["error", "never", { - "@stylistic/no-tabs": "error", - "@stylistic/no-trailing-spaces": ["error"], - "@stylistic/object-curly-spacing": ["error", "never", { - objectsInObjects: false, - arraysInObjects: false - }], - "@stylistic/quotes": ["error", "double", { - "@stylistic/quotes": ["error", "double", { - avoidEscape: true, - allowTemplateLiterals: "always" - allowTemplateLiterals: "always" - }], - "@stylistic/semi": ["error", "never"], - "@stylistic/space-before-function-paren": ["error", "never"], - "@stylistic/yield-star-spacing": ["error", { before: true, after: false }], - "@stylistic/semi": ["error", "never"], - "@stylistic/space-before-function-paren": ["error", "never"], - "@stylistic/yield-star-spacing": ["error", { before: true, after: false }], - "constructor-super": "error", - "no-unexpected-multiline": "error", - "no-unused-vars": ["error", { - caughtErrors: "all", - caughtErrorsIgnorePattern: "^_+", - argsIgnorePattern: "^_+", - destructuredArrayIgnorePattern: "^_+", - varsIgnorePattern: "^_+" - }], - "no-useless-assignment": "error", - "prefer-const": "error", - "@stylistic/no-multiple-empty-lines": ["error", { max: 1 }], - "@stylistic/array-bracket-spacing": ["error", "never"], - } - }, - { - name: "gesslar/uglier/lints-jsdoc", - files: ["src/**/*.{mjs,cjs,js}"], - plugins: { - jsdoc, - }, - rules: { - "prefer-const": "error", - "@stylistic/no-multiple-empty-lines": ["error", { max: 1 }], - "@stylistic/array-bracket-spacing": ["error", "never"], - } - }, - { - name: "gesslar/uglier/lints-jsdoc", - files: ["src/**/*.{mjs,cjs,js}"], - plugins: { - jsdoc, - }, - rules: { - "jsdoc/require-description": "error", - "jsdoc/tag-lines": ["error", "any", {"startLines":1}], - "jsdoc/require-jsdoc": ["error", { publicOnly: true }], - "jsdoc/check-tag-names": "error", - "jsdoc/check-types": "error", - "jsdoc/require-param-type": "error", - "jsdoc/require-returns-type": "error" - "jsdoc/tag-lines": ["error", "any", {"startLines":1}], - "jsdoc/require-jsdoc": ["error", { publicOnly: true }], - "jsdoc/check-tag-names": "error", - "jsdoc/check-types": "error", - "jsdoc/require-param-type": "error", - "jsdoc/require-returns-type": "error" - } - } + ...uglify({ + with: [ + "lints-js", // default files: ["**/*.{js,mjs,cjs}"] + "lints-jsdoc", // default files: ["**/*.{js,mjs,cjs}"] + "node", // default files: ["**/*.{js,mjs,cjs}"] + ] + }) ]