Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "wiki"]
path = wiki
url = https://github.com/OpenKotOR/ChangeEdit.wiki.git
26 changes: 7 additions & 19 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,15 @@
// Pascal extension is language/build support only, so native binaries still
// run through VS Code's native debugger adapters.
// On Linux/macOS, launching is proxied through Wine to run the Windows .exe.
// Inputs are intentionally sourced from changeEdit.* settings so launch is
// non-interactive by default and can run in automation contexts.
"version": "0.2.0",
"configurations": [
{
"name": "ChangeEdit: Launch built executable",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}\\${input:changeEditExecutable}",
"program": "${workspaceFolder}\\${config:changeEdit.executable}",
"args": [],
"cwd": "${workspaceFolder}",
"stopAtEntry": false,
Expand All @@ -22,16 +24,16 @@
"linux": {
"program": "/usr/bin/env",
"args": [
"${input:wineCommand}",
"${workspaceFolder}/${input:changeEditExecutable}"
"${config:changeEdit.wineCommand}",
"${workspaceFolder}/${config:changeEdit.executable}"
],
"MIMode": "gdb"
},
"osx": {
"program": "/usr/bin/env",
"args": [
"${input:wineCommand}",
"${workspaceFolder}/${input:changeEditExecutable}"
"${config:changeEdit.wineCommand}",
"${workspaceFolder}/${config:changeEdit.executable}"
],
"MIMode": "lldb"
}
Expand All @@ -50,19 +52,5 @@
"order": 2
}
}
],
"inputs": [
{
"id": "changeEditExecutable",
"type": "promptString",
"description": "Path to the built ChangeEdit executable, relative to the workspace root",
"default": "ChangEd.exe"
},
{
"id": "wineCommand",
"type": "promptString",
"description": "Wine launcher to use on Linux/macOS",
"default": "wine"
}
]
}
3 changes: 3 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,8 @@
"/c"
]
},
"changeEdit.delphiCompiler": "dcc32.exe",
"changeEdit.executable": "ChangEd.exe",
"changeEdit.wineCommand": "wine",
"omnipascal.defaultDevelopmentEnvironment": "Delphi"
}
2 changes: 2 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{
// Repo-matched task surface for the Delphi 7 ChangeEdit workflow.
// Task defaults come from changeEdit.* workspace settings to avoid prompt
// inputs and keep runs deterministic in local and CI-like automation.
"version": "2.0.0",
"windows": {
"options": {
Expand Down
2 changes: 2 additions & 0 deletions BUILD.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ The compiler will produce `ChangEd.exe` and `.dcu` files in the project director

If the compiler cannot be found, the task fails with a configuration message telling you to update `changeEdit.delphiCompiler`.

Both task and launch profiles are intentionally non-interactive: they read from `changeEdit.*` workspace settings instead of prompting for runtime inputs.

---

## Compiler options (summary)
Expand Down
21 changes: 15 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
A `changes.ini` file tells TSLPatcher which game files to modify and how. ChangeEdit exposes every supported operation as a point-and-click form:

| Section | Operations |
|---------|-----------|
| --- | --- |
| **Settings** | Patch caption, confirmation text, log style, mode, backup count, required-file checks |
| **TLK** | Map `StrRef` tokens to localised dialog strings, optional sound overrides |
| **2DA** | Add rows, modify cells, copy rows, add columns — for binary `.2da` game tables |
Expand All @@ -28,7 +28,7 @@ A `changes.ini` file tells TSLPatcher which game files to modify and how. Change
## File formats handled

| Format | Extension(s) | Handler unit |
|--------|-------------|-------------|
| --- | --- | --- |
| 2DA Binary v2.b | `.2da` | `U2DAEdit` |
| GFF v3.2 | `.gff`, `.uti`, `.utc`, `.dlg`, `.ssf`, … | `UGFFFile` |
| Dialog strings | `.tlk` | `UTLKFile` |
Expand All @@ -38,7 +38,7 @@ A `changes.ini` file tells TSLPatcher which game files to modify and how. Change

## Quick start

1. Build the project with Delphi 7 on Windows (see [BUILD.md](BUILD.md)).
1. Build the project with Delphi 7 on Windows, or run the VS Code task wrapper with a Wine-hosted Delphi 7 compiler on Linux/macOS (see [BUILD.md](BUILD.md)).
2. Launch `ChangEd.exe`.
3. **File → Open** to load an existing `changes.ini`, or **File → New** to start from scratch.
4. Navigate the left-hand tree to the section you want to edit.
Expand All @@ -49,7 +49,7 @@ A `changes.ini` file tells TSLPatcher which game files to modify and how. Change

## Project structure

```
```text
ChangEd.dpr Program entry point (registers all forms)
UMainForm.pas/.dfm Main window (tree + stacked panels)
U2DAEdit.pas Binary 2DA v2.b reader/writer
Expand All @@ -66,11 +66,20 @@ Full module-by-module breakdown: [ARCHITECTURE.md](ARCHITECTURE.md)

---

## Wiki

The project wiki is published on GitHub and versioned in the top-level `wiki/` submodule of this repository.

- Browse the published pages: <https://github.com/OpenKotOR/ChangeEdit/wiki>
- After cloning, fetch the local wiki working tree with `git submodule update --init wiki`

---

## Requirements

- **Build host**: Windows (Delphi 7 compiler — see [BUILD.md](BUILD.md))
- **Build host**: Windows with Delphi 7, or Linux/macOS through Wine when the VS Code build task is pointed at a Wine-visible `dcc32.exe` (see [BUILD.md](BUILD.md))
- **Runtime**: Windows 9x / NT 4+ (XP visual styles via `TXPManifest`)
- **Linux**: Run the compiled `.exe` under Wine
- **Linux / macOS**: Run the compiled `.exe` under Wine

---

Expand Down
91 changes: 91 additions & 0 deletions docs/plans/2026-05-27-005-wiki-submodule-and-user-docs-plan.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
# Plan: Add Wiki Submodule and Project Wiki

Status: completed
Date: 2026-05-28
Scope: top-level `wiki/` submodule + thorough GitHub wiki content derived from repo evidence
Origin: direct user request to investigate the repo and create the wiki using `gh` and `git`

## Problem Frame

ChangeEdit already has strong repo-local documentation in root markdown files, but it does not yet expose that material through a checked-out wiki repository in the superproject. The requested work is not only to add the `wiki/` submodule, but to investigate the codebase thoroughly enough that the wiki becomes a durable contributor and user reference rather than a thin mirror of `README.md`.

## Requirements Traceability

1. Create and wire a GitHub wiki for this repository as a top-level submodule at `wiki/`.
2. Use GitHub CLI and git CLI for setup, verification, and publication rather than hand-waving the wiki bootstrap.
3. Investigate the codebase and existing repo docs deeply enough to cover product purpose, architecture, workflows, formats, build/run expectations, contribution guidance, and known limitations.
4. Keep repo changes focused on markdown content, submodule metadata, and any minimal repo links needed to make the wiki discoverable.
5. Push the wiki repository content and commit the superproject gitlink so collaborators can clone the wiki working tree locally.

## Key Decisions

1. Treat the root markdown files (`README.md`, `ARCHITECTURE.md`, `BUILD.md`, `CONTRIBUTING.md`, `CONVENTIONS.md`, `FORMATS.md`, `TODO.txt`) plus the core Delphi units as the primary evidence sources for wiki content.
2. Keep the wiki user-facing and navigable, but do not flatten important technical constraints such as Delphi 7 only support, Wine-based Linux/macOS workflows, startup-created form singletons, and known binary-format write limitations.
3. Use standard GitHub wiki entry points (`Home.md` and `_Sidebar.md`) plus topic pages instead of a single mega-page.
4. Preserve a clear separation between the superproject and the wiki repository: wiki page commits belong inside `wiki/`, while submodule pointer and `.gitmodules` changes belong in the main repository.
5. Prefer the existing root docs as source-of-truth references where practical, with the wiki acting as the curated navigation layer and public-facing knowledge surface.

## Implementation Units

1. IU-1 Repo investigation and evidence capture

- Read the existing high-signal docs and the code surfaces that directly define application behavior and constraints.
- Minimum investigation set: `README.md`, `ARCHITECTURE.md`, `BUILD.md`, `CONTRIBUTING.md`, `CONVENTIONS.md`, `FORMATS.md`, `TODO.txt`, `ChangEd.dpr`, `UMainForm.pas`, `U2DAEdit.pas`, `UGFFFile.pas`, `UTLKFile.pas`, `UST_IniFile.pas`, and `UST_Common.pas`.
- Extract the facts the wiki must preserve: supported editing areas, build/runtime constraints, file-format scope, known gaps, contribution workflow, and manual validation expectations.

1. IU-2 Wiki remote bootstrap and submodule setup

- Verify that the GitHub repository has wiki support enabled.
- Resolve the wiki git remote from the repository origin and initialize or connect the wiki repository through git.
- Add the wiki repository as a top-level submodule at `wiki/` and verify the resulting `.gitmodules` entry and gitlink.
- If the wiki remote is empty, seed it with an initial commit before the superproject pointer is finalized.

1. IU-3 Wiki information architecture and page set

- Create `wiki/Home.md` as the landing page with project summary, audience, and page map.
- Create `wiki/_Sidebar.md` so GitHub renders stable wiki navigation.
- Create a page set that covers, at minimum:
- what ChangeEdit is and who it is for
- how the main window and section tree map to editing tasks
- how TLK, 2DA, GFF, SSF, script, install, and namespace editing fit into the product
- build and run expectations on Windows and on Wine-hosted Linux/macOS setups
- known architectural limits, unsupported edges, and manual testing expectations
- contributor-oriented entry points back to the root repo docs
- Keep language direct and readable, but accurate enough for maintainers and mod authors.

1. IU-4 Cross-linking and repo discoverability

- Add only the minimal supporting repo-side references needed so contributors can discover the checked-out wiki workflow.
- Preserve the root docs as canonical detailed references rather than duplicating every technical detail into the wiki.

1. IU-5 Validation, publication, and handoff

- Validate markdown structure, internal links, and navigation completeness inside the wiki working tree.
- Validate that the wiki remote contains the authored pages and that the superproject points at the expected wiki commit.
- Commit and push the wiki repository first, then commit the superproject submodule pointer and any supporting repo-side documentation updates.

## File Plan

- Superproject metadata: `.gitmodules`, `wiki/` (gitlink)
- Possible superproject support doc: `README.md` if a wiki-discovery link is needed
- Wiki repository pages: `wiki/Home.md`, `wiki/_Sidebar.md`, and additional topic pages under `wiki/`

## Validation Scenarios

1. Wiki availability: GitHub reports wiki support enabled for `OpenKotOR/ChangeEdit`, and the resolved wiki git remote accepts fetch/push operations.
2. Submodule integrity: cloning or updating submodules produces a populated `wiki/` checkout with a correct `.gitmodules` entry.
3. Documentation completeness: the wiki covers product purpose, core workflows, supported file formats, build/run instructions, limitations, and contributor entry points without contradicting repo-local docs.
4. Navigation quality: `Home.md` and `_Sidebar.md` provide working page discovery and no orphaned top-level pages remain.
5. Publication order: the wiki repository commit exists upstream before the superproject gitlink commit is pushed.

## Risks and Mitigations

- Wiki remote permissions may differ from normal repo push permissions. Mitigation: verify access before finalizing the submodule pointer.
- The wiki can drift from the root docs over time. Mitigation: keep the wiki curated and cross-link to root canonical docs for deep technical detail.
- There is no automated test suite for docs or app behavior. Mitigation: rely on repo evidence, careful link checks, and the repo's documented manual validation expectations.

## Out of Scope

- Changing Delphi source behavior, build tooling, or application UI.
- Rewriting existing root docs into a different documentation system.
- Adding generated site tooling, docs build pipelines, or non-wiki publishing infrastructure.
121 changes: 121 additions & 0 deletions docs/plans/2026-05-27-006-vscode-launch-defaults-lfg-plan.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
---
title: "LFG: ChangeEdit Launch Defaults Follow-up"
date: 2026-05-27
status: completed
---

## Execution Outcome

- Completed on 2026-05-27.
- Verified that the branch diff stayed limited to `.vscode/launch.json`, `.vscode/settings.json`, and `README.md` for the implementation slice.
- Confirmed there were no prompt-backed launch inputs remaining in the branch diff.
- Review/autofix produced no residual actionable work and no review-only edits to persist.
- Browser testing was not applicable because the PR diff does not touch browser-routable surfaces.
- PR #2 remains open, and no CI checks are configured on the branch.

## Problem Frame

The current branch `fix/changeedit-vscode-launch-defaults` is a follow-up to the already-merged ChangeEdit VS Code task cleanup. Its purpose is to finish the remaining workspace automation gap on this branch: remove interactive prompt-backed launch inputs, move those defaults into workspace settings, and keep the user-facing README aligned with the non-interactive build/run workflow.

The implementation already exists on the branch, but this LFG pass still needs to complete the ordered pipeline against that slice: verify the branch state, review the diff against the requirements, persist any autofixes, confirm browser-test applicability, and close out the PR/CI steps.

## Scope

**In scope:**

- Verify the current branch diff for `.vscode/launch.json`, `.vscode/settings.json`, and `README.md`
- Confirm the launch configuration no longer depends on interactive `inputs`
- Confirm workspace defaults exist for the ChangeEdit executable, Wine launcher, and Delphi compiler
- Confirm docs match the shipped Windows-native and Wine-backed workflow
- Run the remaining LFG review, validation, commit/push, PR, and CI-watch steps on this branch

**Out of scope:**

- Reworking the already-merged `.vscode/tasks.json` and `BUILD.md` changes unless review exposes a new defect in the current branch slice
- Modifying Delphi source files or runtime behavior
- Touching unrelated untracked plan artifacts already present in the repo

## Requirements

| # | Requirement |
| --- | --- |
| R1 | `.vscode/launch.json` resolves the executable and Wine launcher through workspace configuration rather than prompt-backed task inputs |
| R2 | `.vscode/settings.json` provides ChangeEdit defaults for compiler, executable, and Wine launcher values |
| R3 | `README.md` reflects the current Windows-native and Wine-backed VS Code workflow without stale task-input language |
| R4 | The current branch diff remains limited to the launch-default follow-up slice and does not sweep in unrelated files |
| R5 | The branch passes an LFG review/autofix pass with any resulting fixes durably committed before closeout |
| R6 | Browser testing is either run or explicitly recorded as not applicable based on the actual diff |
| R7 | The open PR for this branch is updated only through normal push flow unless residual findings or unresolved CI failures require PR-body changes |

## Implementation Units

### IU-1: Verify current branch slice

**Files:**

- `.vscode/launch.json`
- `.vscode/settings.json`
- `README.md`

**Goals:**

- Confirm the branch still matches its intended scope
- Confirm the implementation already present on the branch is the slice to review and ship

**Verification:**

- `git diff --stat origin/main...HEAD` shows the expected three-file follow-up scope

### IU-2: Apply any small branch-local correction

**Files:**

- `.vscode/launch.json`
- `.vscode/settings.json`
- `README.md`

**Goals:**

- Fix any correctness or wording issue discovered while validating the current branch diff
- Keep changes minimal and branch-relevant

**Verification:**

- Touched files remain diagnostics-clean
- No interactive launch inputs remain in the branch diff

### IU-3: Run review and closeout

**Files:**

- `.vscode/launch.json`
- `.vscode/settings.json`
- `README.md`
- `docs/plans/2026-05-27-006-vscode-launch-defaults-lfg-plan.md`

**Goals:**

- Complete the review/autofix step against the current branch diff
- Persist any review fixes separately if needed
- Finish PR and CI closeout for the open branch PR

**Verification:**

- Review findings are either fixed or explicitly recorded as none
- Remaining working tree changes are either committed for this branch or confirmed unrelated

## Test Scenarios

| Scenario | Pass condition |
| --- | --- |
| Branch scope check | Current diff against `origin/main` stays limited to launch/settings/README follow-up files |
| Launch-input removal | No prompt-backed `inputs` are required for the current launch configuration |
| Workspace defaults present | `changeEdit.delphiCompiler`, `changeEdit.executable`, and `changeEdit.wineCommand` exist in `.vscode/settings.json` |
| README parity | README language matches the ChangeEdit Windows-native and Wine-backed workflow |
| Browser-test applicability | The pipeline records a grounded N/A result if the diff does not touch browser-routable surfaces |

## Dependencies

- Current branch: `fix/changeedit-vscode-launch-defaults`
- Open PR: #2 against `main`
- Prior task-surface changes already merged to `main`
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Plan: LFG Continuation for VS Code Launch Defaults

Status: active
Date: 2026-05-28
Scope: .vscode launch/task UX consistency and pipeline closeout on PR #2

## Goal

Continue the branch work with at least one concrete improvement aligned to the non-interactive launch-defaults objective, then complete LFG review/push/check stages.

## Implementation Units

1. IU-1 Inspect current launch/task defaults

- Verify whether interactive prompts still exist in launch/task surfaces.
- Identify a small, safe follow-up change to improve non-interactive behavior.

1. IU-2 Implement one follow-up improvement

- Apply minimal edits in .vscode files only.
- Keep behavior aligned with ChangeEdit and Delphi 7 constraints.

1. IU-3 Review/autofix and persist

- Run diagnostics/review pass.
- Commit review autofixes with required message if any are introduced.

1. IU-4 Pipeline closeout

- Push remaining changes.
- Run PR check-watch handling and complete the pass.
Loading