Skip to content

Commit 35c5457

Browse files
committed
🚜 [refactor] Large-scale docs localization + ANSI conversion scripts overhaul + tooling updates
- 🧪 Improved encoding support: use iconv decode(cp437) for legacy ANSI files and return both content and sauce metadata. - ✨ Better return shapes: convertAnsiToPs1 now returns { lines, warnings, terminal } for programmatic consumption; main() gives clearer status and exits non-zero on fatal errors. - 🔁 Consistent style & exports: standardized function exports (TerminalEmulator, readAnsiFile, convertAnsiToPs1, parseArguments, sanitizeName, main, createDefaultAttrs, stripSauce) and applied consistent formatting/whitespace for readability. 🚜 [refactor] Split-AnsiFile.js — CLI splitting utility hardened & modernized - 🔧 Reworked CLI parsing into typed SplitOptions with JSDoc and solid defaults (DEFAULT_OUTPUT_DIR). - 🔧 Implemented robust segmentation pipeline: extractLinesFromPs1(), determineBreaks(), splitLines(), ensureTrailingReset(), plus chunk-writing helpers writeChunkPs1/writeChunkAnsi. - 🔧 Added features: --heights (cumulative), --breaks (absolute), --every (regular chunking), --auto (blank-line gap detection with gap/minSegment thresholds), --dry-run and --strip-space-bg; improved user-facing error/help output. - 🔧 Now uses the conversion utilities (readAnsiFile/convertAnsiToPs1) and produces consistent part files (sanitized names, padded suffixes) and safe writes. 👷 [ci] Tooling & formatting additions (package.json & package-lock) - 🔧 Added Prettier + an array of Prettier plugins to devDependencies: prettier, prettier-plugin-powershell, prettier-plugin-ini, prettier-plugin-jsdoc, prettier-plugin-multiline-arrays, prettier-plugin-packagejson, prettier-plugin-merge, prettier-plugin-sql, prettier-plugin-sort-json, prettier-plugin-tailwindcss, and helper plugins (prettier-plugin-interpolated-html-tags, @awmottaz/prettier-plugin-void-html, prettier-plugin-properties). - 🔧 Updated package-lock.json to reflect new plugin dependency graph and included supporting libs (micromark/mdast ecosystem, json5, luxon, etc.) for the new formatting toolchain. - ⚙️ Rationale: unify code style across JS/Markdown/PowerShell and enable safe automated formatting in CI pipelines. 📝 [docs] Massive localization & help content hygiene (pt / ru / zh-CN + others) - ✍️ Standardized many localized Markdown help pages under ColorScripts-Enhanced/{pt,ru,zh-CN}: added blank-line separations, improved examples, clarified descriptions, expanded Best Practices and Advanced Usage sections where missing. - ✍️ Escaped wildcard characters in docs (changed "*" to "\*") in multiple languages to avoid unintended Markdown rendering and to make parameter docs literal and copy-paste safe. - ✍️ Normalized parameter YAML fragments: standardized keys (DontShow, AcceptedValues, HelpMessage) and consistent formatting (HelpMessage: ""), added small blank lines for readability. - ✍️ Inserted several translated refinements and extra sample snippets for configuration, caching and profile installation workflows. 📝 [docs] HelpInfo and generated help XML updates - ✍️ Bumped UICultureVersion timestamps in HelpInfo.xml files for pt/ru/zh-CN to reflect documentation refresh (2025.11.05.1608 → 2025.11.05.1615). - ✍️ Reflowed long description paragraphs in the module help XMLs to improve readability and to separate lists into distinct maml:para blocks. 📝 [docs] Documentation index & summary artifacts updated - ✍️ Updated DOCUMENTATION_EXPANSION_SUMMARY.md, DOCUMENTATION_INDEX.md, DOCUMENTATION_STATUS_REPORT.md, HELP_ENHANCEMENTS_SUMMARY.md and related artifacts: reflowed tables, aligned columns, improved metrics and "Last Updated" formatting (converted trailing bullets to underscored metadata). - ✍️ README.md: small table alignment fixes and clarified Get-Help -Online behavior wording. ✨ [feat] help-redirect.html — rewrite for robust language detection & redirects - ✨ Normalized doctype and modernized HTML head; improved language mapping and browser language probing (navigator.languages fallback), better supportedCultures mapping and safe redirect to localized markdown pages on GitHub. - 📝 UI improvements: spinner, friendly message, and explicit "Detected language" feedback prior to redirect. 🧹 [chore] CI/config formatting and docs support fixes - 🧹 _config.yml: normalized plugin list indentation for Jekyll site config. - 🧹 codecov.yml: comment spacing & inline comment normalizations; minor whitespace cleanups in ignored paths to reduce diff noise. - 🧹 Updated multiple docs (Development.md, CODECOV_JUNIT_SETUP.md, NPM_SCRIPTS.md, Publishing.md, QUICK_REFERENCE.md) to fix table alignment, wording, and code-block formatting. 📝 [docs] micro-fixes & release artifacts - ✍️ Cleaned dist release notes templates (dist/LatestReleaseNotes.md, dist/PowerShellGalleryReleaseNotes.md): removed empty placeholders, reflowed contributor/license blocks and ensured git-cliff footer note is present. - ✍️ Minor localized help adjustments: consistent quoting, added minor explanatory text and small example expansions across many command docs (Get-ColorScriptList, Show-ColorScript, New-ColorScript, New-ColorScriptCache, Clear-ColorScriptCache, etc.). 🧪 [test] Validation notes and guardrails - 🔍 Conversion & split scripts now emit warnings array for conversion anomalies (parser/CSI/ESC warnings). CLI surfaces top warnings and summarizes them for troubleshooting. - 🔁 Conversion pipeline improved to return programmatic values enabling unit-style verification in future tests. Notes / Impact - 🔔 Primary focus: stabilise and modernize the ANSI → PowerShell conversion pipeline and make CLI splitting deterministic and extensible. - 🧾 Secondary focus: large documentation/localization cleanup for better UX and consistent help output across supported locales. - ⚠️ Backwards compatibility: conversion CLI options were extended; calling scripts that relied on older export names should adapt to the exported function names (convertAnsiToPs1/readAnsiFile/etc.). Review calling points if external automation used prior private exports. - ✅ This commit bundles code + doc + tooling changes because they are tightly coupled: new formatting toolchain ensures consistent style for the refactored JS and the regenerated help content. Files / areas touched (non-exhaustive) - src/scripts: Convert-AnsiToColorScript.js (major), Split-AnsiFile.js (major) - package.json & package-lock.json (prettier + plugins) - docs/ & docs/*.md (many updates), docs/help-redirect.html (rewrite) - ColorScripts-Enhanced/{pt,ru,zh-CN}/**/*.md and help.xml (localized docs & UICultureVersion bumps) - dist/*.md (release notes) - README.md, _config.yml, codecov.yml, various DOCUMENTATION_*.md and HELP_ENHANCEMENTS_SUMMARY.md — End of changes Signed-off-by: Nick2bad4u <20943337+Nick2bad4u@users.noreply.github.com>
1 parent 3493565 commit 35c5457

191 files changed

Lines changed: 10191 additions & 7023 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/PROMPTS/Consistency-Check.prompt.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ If you find documentation gaps add them. If you find out-of-date documentation a
5252
### 1. Categorized Report
5353

5454
For each inconsistency provide:
55+
5556
- Relevant file path(s) with concise excerpts.
5657
- A short description of the issue, including the layer or pattern it affects.
5758
- A recommended alignment approach grounded in an existing best practice within the repository.
@@ -63,13 +64,15 @@ Rank findings by their risk to stability, potential to introduce bugs, and overa
6364
### 3. Improvement Suggestions
6465

6566
Group related findings and outline:
67+
6668
- The preferred approach or exemplar to follow.
6769
- Ordered steps to realign the affected code.
6870
- Expected impact across modules, IPC contracts, schemas, or docs.
6971

7072
### 4. Roadmap
7173

7274
Suggest a staged plan:
75+
7376
- **Quick Wins** – light standardisations with meaningful payoff.
7477
- **Medium-Term** – coordinated refactors requiring moderate coordination.
7578
- **Long-Term** – deeper architectural work worth tracking separately.
@@ -85,6 +88,7 @@ Suggest a staged plan:
8588
## Fixing Inconsistencies
8689

8790
When addressing identified inconsistencies, follow these steps:
91+
8892
1. **Understand the Context**: Review the relevant code sections to fully grasp the intended functionality and how it fits within the overall architecture.
8993
2. **Consult Documentation**: Refer to any existing documentation or architectural guidelines to ensure your changes align with established best practices.
9094
3. **Refactor Thoughtfully**: Make changes that enhance consistency without introducing new issues. Ensure that your refactoring maintains the original functionality.
@@ -96,6 +100,7 @@ When addressing identified inconsistencies, follow these steps:
96100
## Examples of Inconsistencies to Look For
97101

98102
Examples of inconsistencies include:
103+
99104
- Different naming conventions for similar functions or variables (e.g., verb-noun patterns, parameter names).
100105
- Varied approaches to error handling in public cmdlets versus private helpers.
101106
- Divergent data transformation logic for the same data structure in different functions.

.github/PROMPTS/Continue.prompt.md

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ name: "Continue"
1111
- Locate the next incomplete TODO item (those not marked as done or resolved).
1212
- If you have any questions or need clarification on any TODO items, document them clearly for further review or stop and ask for assistance.
1313
- For each incomplete TODO item, proceed systematically:
14-
1514
- Review the context, problem description, and any relevant files mentioned.
1615
- Assess the current state and any blockers or dependencies.
1716
- Implement necessary changes, fixes, or features using available tools.

.github/agents/BeastMode.agent.md

Lines changed: 44 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,40 @@ name: BeastMode
33
description: Beast Mode 3.1 (Custom) - PowerShell Module Specialist
44
argument-hint: "💻 🤖 😈 Beast Mode agent ready for PowerShell excellence. 👿 🤖 💻"
55
model: GPT-5-Codex (Preview) (copilot)
6-
tools: ['edit/createFile', 'edit/createDirectory', 'edit/editFiles', 'search/fileSearch', 'search/textSearch', 'search/listDirectory', 'search/readFile', 'search/codebase', 'tavily/tavily-extract', 'tavily/tavily-map', 'tavily/tavily-search', 'vscode-mcp/execute_command', 'vscode-mcp/get_diagnostics', 'vscode-mcp/get_references', 'vscode-mcp/get_symbol_lsp_info', 'vscode-mcp/rename_symbol', 'runCommands/getTerminalOutput', 'runCommands/terminalLastCommand', 'runCommands/runInTerminal', 'runTasks/runTask', 'runTasks/getTaskOutput', 'runSubagent', 'usages', 'problems', 'changes', 'testFailure', 'fetch', 'memory', 'ms-vscode.vscode-websearchforcopilot/websearch', 'todos', 'runTests']
6+
tools:
7+
[
8+
"edit/createFile",
9+
"edit/createDirectory",
10+
"edit/editFiles",
11+
"search/fileSearch",
12+
"search/textSearch",
13+
"search/listDirectory",
14+
"search/readFile",
15+
"search/codebase",
16+
"tavily/tavily-extract",
17+
"tavily/tavily-map",
18+
"tavily/tavily-search",
19+
"vscode-mcp/execute_command",
20+
"vscode-mcp/get_diagnostics",
21+
"vscode-mcp/get_references",
22+
"vscode-mcp/get_symbol_lsp_info",
23+
"vscode-mcp/rename_symbol",
24+
"runCommands/getTerminalOutput",
25+
"runCommands/terminalLastCommand",
26+
"runCommands/runInTerminal",
27+
"runTasks/runTask",
28+
"runTasks/getTaskOutput",
29+
"runSubagent",
30+
"usages",
31+
"problems",
32+
"changes",
33+
"testFailure",
34+
"fetch",
35+
"memory",
36+
"ms-vscode.vscode-websearchforcopilot/websearch",
37+
"todos",
38+
"runTests",
39+
]
740
handoffs:
841
- label: Consistency Check
942
agent: BeastMode
@@ -44,11 +77,13 @@ target: vscode
4477

4578
1. Fetch any URL's provided by the user using the `fetch` tool.
4679
2. Understand the problem deeply. Think harder and Super Think. Carefully read the issue and think critically about what is required. Use sequential thinking and memory tools if needed to break down the problem into manageable parts. Consider the following:
47-
- What is the expected behavior?
48-
- What are the edge cases?
49-
- What are the potential pitfalls?
50-
- How does this fit into the larger context of the PowerShell module?
51-
- What are the dependencies and interactions with other parts of the code?
80+
81+
- What is the expected behavior?
82+
- What are the edge cases?
83+
- What are the potential pitfalls?
84+
- How does this fit into the larger context of the PowerShell module?
85+
- What are the dependencies and interactions with other parts of the code?
86+
5287
3. Investigate the codebase. Explore relevant files, search for key functions, and gather context.
5388
4. If the problem is with 3rd party libraries or frameworks, research the problem on the internet by reading relevant articles, documentation, and forums.
5489
5. Develop a clear, step-by-step plan. Break down the fix into manageable, incremental steps. Display those steps in a simple todo list.
@@ -131,14 +166,17 @@ Refer to the detailed sections below for more information on each step.
131166
- You have no time or compute constraints, do not rush to try and finish the task.
132167

133168
## Thinking
169+
134170
If the thinking tool is available, use it to break down complex problems into smaller, manageable steps.
135171

136172
## Override Constraints
173+
137174
- All constraints are updated to `unlimited` or `maximum` for this session.
138175
- Making decisions based on time is not allowed.
139176
- You have time to finish any task no matter how large it is or long it takes.
140177

141178
## Thinking Mode
179+
142180
- **Time constraint setting:** `unlimited`
143181
- **Compute Resource setting:** `unlimited`
144182
- **Thinking Mode setting:** `Ultrathink`

.github/dependabot.yml

Lines changed: 63 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -10,68 +10,68 @@
1010

1111
version: 2
1212
updates:
13-
- package-ecosystem: github-actions
14-
cooldown:
15-
default-days: 3
16-
include: ["*"]
17-
directory: /
18-
schedule:
19-
interval: quarterly
20-
time: "05:30"
21-
timezone: "America/Detroit"
22-
assignees: ["Nick2bad4u"]
23-
allow:
24-
# Allow both direct and indirect updates for all packages
25-
- dependency-type: "all"
26-
labels:
27-
- "github-actions"
28-
- "dependabot"
29-
- "dependencies"
30-
commit-message:
31-
prefix: "[ci][skip-ci]"
32-
prefix-development: "[ci][skip-ci]"
33-
include: "scope"
34-
groups:
35-
github-actions:
36-
applies-to: version-updates
37-
patterns:
38-
- "*"
13+
- package-ecosystem: github-actions
14+
cooldown:
15+
default-days: 3
16+
include: ["*"]
17+
directory: /
18+
schedule:
19+
interval: quarterly
20+
time: "05:30"
21+
timezone: "America/Detroit"
22+
assignees: ["Nick2bad4u"]
23+
allow:
24+
# Allow both direct and indirect updates for all packages
25+
- dependency-type: "all"
26+
labels:
27+
- "github-actions"
28+
- "dependabot"
29+
- "dependencies"
30+
commit-message:
31+
prefix: "[ci][skip-ci]"
32+
prefix-development: "[ci][skip-ci]"
33+
include: "scope"
34+
groups:
35+
github-actions:
36+
applies-to: version-updates
37+
patterns:
38+
- "*"
3939

40-
- package-ecosystem: npm
41-
cooldown:
42-
default-days: 3
43-
include: ["*"]
44-
directory: /
45-
schedule:
46-
interval: quarterly
47-
assignees: ["Nick2bad4u"]
48-
versioning-strategy: increase
49-
allow:
50-
# Allow both direct and indirect updates for all packages
51-
- dependency-type: "all"
52-
ignore:
53-
- dependency-name: "electron-builder"
54-
versions: ["< 26.0.18"]
55-
- dependency-name: "electron-builder-squirrel-windows"
56-
versions: ["< 26.0.18"]
57-
# Ignore local workspace dependencies completely
58-
- dependency-name: "@shared/*"
59-
- dependency-name: "file:*"
40+
- package-ecosystem: npm
41+
cooldown:
42+
default-days: 3
43+
include: ["*"]
44+
directory: /
45+
schedule:
46+
interval: quarterly
47+
assignees: ["Nick2bad4u"]
48+
versioning-strategy: increase
49+
allow:
50+
# Allow both direct and indirect updates for all packages
51+
- dependency-type: "all"
52+
ignore:
53+
- dependency-name: "electron-builder"
54+
versions: ["< 26.0.18"]
55+
- dependency-name: "electron-builder-squirrel-windows"
56+
versions: ["< 26.0.18"]
57+
# Ignore local workspace dependencies completely
58+
- dependency-name: "@shared/*"
59+
- dependency-name: "file:*"
6060

61-
labels:
62-
- "npm"
63-
- "dependabot"
64-
- "dependencies"
65-
commit-message:
66-
prefix: "[dependency]"
67-
prefix-development: "[dev-dependency][skip-ci]"
68-
include: "scope"
69-
groups:
70-
npm-all:
71-
applies-to: version-updates
72-
patterns:
73-
- "*"
74-
# Exclude local packages from grouping
75-
exclude-patterns:
76-
- "@shared/*"
77-
- "file:*"
61+
labels:
62+
- "npm"
63+
- "dependabot"
64+
- "dependencies"
65+
commit-message:
66+
prefix: "[dependency]"
67+
prefix-development: "[dev-dependency][skip-ci]"
68+
include: "scope"
69+
groups:
70+
npm-all:
71+
applies-to: version-updates
72+
patterns:
73+
- "*"
74+
# Exclude local packages from grouping
75+
exclude-patterns:
76+
- "@shared/*"
77+
- "file:*"

.github/workflows/ActionLint.yml

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -16,30 +16,30 @@
1616

1717
name: ActionLint
1818
concurrency:
19-
group: actionlint-${{ github.ref }}
20-
cancel-in-progress: false
19+
group: actionlint-${{ github.ref }}
20+
cancel-in-progress: false
2121
on:
22-
push:
23-
paths:
24-
- ".github/**"
25-
pull_request:
26-
paths:
27-
- ".github/**"
28-
workflow_dispatch:
22+
push:
23+
paths:
24+
- ".github/**"
25+
pull_request:
26+
paths:
27+
- ".github/**"
28+
workflow_dispatch:
2929

3030
permissions:
31-
contents: read
32-
pull-requests: write
31+
contents: read
32+
pull-requests: write
3333

3434
jobs:
35-
job-1:
36-
runs-on: ubuntu-latest
37-
steps:
38-
- name: Harden Runner
39-
uses: step-security/harden-runner@f4a75cfd619ee5ce8d5b864b0d183aff3c69b55a # v2.13.1
40-
with:
41-
egress-policy: audit
42-
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
43-
- uses: devops-actions/actionlint@c6744a34774e4e1c1df0ff66bdb07ec7ee480ca0 #v0.1.9
44-
continue-on-error: true
45-
id: action-lint
35+
job-1:
36+
runs-on: ubuntu-latest
37+
steps:
38+
- name: Harden Runner
39+
uses: step-security/harden-runner@f4a75cfd619ee5ce8d5b864b0d183aff3c69b55a # v2.13.1
40+
with:
41+
egress-policy: audit
42+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
43+
- uses: devops-actions/actionlint@c6744a34774e4e1c1df0ff66bdb07ec7ee480ca0 #v0.1.9
44+
continue-on-error: true
45+
id: action-lint

0 commit comments

Comments
 (0)