Skip to content

Add thematic break formatting#57

Merged
leynos merged 4 commits intomainfrom
codex/add-breaks-commandline-option
Jul 13, 2025
Merged

Add thematic break formatting#57
leynos merged 4 commits intomainfrom
codex/add-breaks-commandline-option

Conversation

@leynos
Copy link
Copy Markdown
Owner

@leynos leynos commented Jul 13, 2025

Summary

  • introduce a --breaks option in the CLI
  • implement format_breaks to normalise thematic breaks
  • update README with usage of new option
  • extend tests for break formatting and CLI support

Testing

  • cargo +nightly-2025-06-10 fmt --all
  • cargo clippy -- -D warnings
  • RUSTFLAGS="-D warnings" cargo test
  • markdownlint *.md docs/*.md

https://chatgpt.com/codex/tasks/task_e_6873b23756788322b41601109565b38f

Summary by Sourcery

Introduce a --breaks option to the CLI and implement logic to normalize thematic break lines as 70 underscores, integrating it into the processing pipeline and documenting and testing the new feature.

New Features:

  • Add --breaks CLI option to normalize thematic breaks to 70 underscores

Enhancements:

  • Implement format_breaks function to detect and replace thematic break lines outside fenced code blocks
  • Integrate breaks formatting into the processing pipeline for both stdin and file inputs

Documentation:

  • Update README to document the new --breaks option usage

Tests:

  • Add unit tests for basic break formatting and code block exemption and an integration test for the CLI breaks option

@sourcery-ai
Copy link
Copy Markdown
Contributor

sourcery-ai Bot commented Jul 13, 2025

Reviewer's Guide

Adds a regex-based format_breaks function to normalize thematic breaks to 70 underscores outside fenced code, exposes it via a new --breaks CLI flag integrated into the processing pipeline, and updates tests and documentation accordingly.

Class diagram for updated CLI argument parsing and processing

classDiagram
    class Cli {
        +bool in_place
        +FormatOpts opts
        +Vec<PathBuf> files
    }
    class FormatOpts {
        +bool wrap
        +bool renumber
        +bool breaks
    }
    Cli --> FormatOpts : has-a
Loading

Class diagram for new format_breaks function

classDiagram
    class format_breaks {
        +Vec<String> format_breaks(&[String])
    }
Loading

File-Level Changes

Change Details Files
Introduce --breaks CLI option and wire it through processing
  • Add breaks field to FormatOpts and flatten it into Cli
  • Extend process_lines, rewrite_path, and main to accept and pass the breaks flag
  • Update argument parsing to include --breaks in usage and help text
src/main.rs
Implement format_breaks function for thematic break normalization
  • Define THEMATIC_BREAK_RE to match breaks outside code fences
  • Add format_breaks to replace matching lines with 70 underscores while tracking fenced code blocks
  • Invoke format_breaks in process_lines when breaks flag is enabled
src/lib.rs
Add integration tests for break formatting and CLI support
  • Test basic break normalization to underscores
  • Test that code blocks are ignored when formatting breaks
  • Test CLI --breaks output for a break line
tests/integration.rs
Update README to document the new breaks option
  • Include --breaks in the command-line usage synopsis
  • Describe break normalization behavior in option list
README.md

Tips and commands

Interacting with Sourcery

  • Trigger a new review: Comment @sourcery-ai review on the pull request.
  • Continue discussions: Reply directly to Sourcery's review comments.
  • Generate a GitHub issue from a review comment: Ask Sourcery to create an
    issue from a review comment by replying to it. You can also reply to a
    review comment with @sourcery-ai issue to create an issue from it.
  • Generate a pull request title: Write @sourcery-ai anywhere in the pull
    request title to generate a title at any time. You can also comment
    @sourcery-ai title on the pull request to (re-)generate the title at any time.
  • Generate a pull request summary: Write @sourcery-ai summary anywhere in
    the pull request body to generate a PR summary at any time exactly where you
    want it. You can also comment @sourcery-ai summary on the pull request to
    (re-)generate the summary at any time.
  • Generate reviewer's guide: Comment @sourcery-ai guide on the pull
    request to (re-)generate the reviewer's guide at any time.
  • Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
    pull request to resolve all Sourcery comments. Useful if you've already
    addressed all the comments and don't want to see them anymore.
  • Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
    request to dismiss all existing Sourcery reviews. Especially useful if you
    want to start fresh with a new review - don't forget to comment
    @sourcery-ai review to trigger a new review!

Customizing Your Experience

Access your dashboard to:

  • Enable or disable review features such as the Sourcery-generated pull request
    summary, the reviewer's guide, and others.
  • Change the review language.
  • Add, remove or edit custom review instructions.
  • Adjust other review settings.

Getting Help

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Jul 13, 2025

Summary by CodeRabbit

  • New Features
    • Added a new command-line option (--breaks) to normalise thematic breaks in Markdown files to a consistent line of underscores.
  • Documentation
    • Updated usage instructions to include the new --breaks option and its description.
  • Tests
    • Introduced new tests to verify the correct formatting of thematic breaks and ensure the new CLI option works as intended.

Summary by CodeRabbit

  • New Features
    • Added a new --breaks command-line option to standardise thematic breaks in markdown files as lines of 70 underscores.
  • Documentation
    • Updated usage instructions to include the new --breaks option and its description.
  • Tests
    • Introduced tests to verify correct formatting of thematic breaks and ensure code blocks remain unaffected.
    • Added integration test for the --breaks CLI option.

Walkthrough

Introduce a new --breaks command-line option to normalise thematic breaks in Markdown files to a line of 70 underscores. Refactor CLI parsing to group formatting flags, implement the formatting logic in the library, and add integration and unit tests for the new feature and its CLI interface. Update documentation accordingly.

Changes

File(s) Change Summary
README.md Document the new --breaks CLI option and describe its effect on thematic breaks.
src/lib.rs Add regex for detecting thematic breaks; implement format_breaks to normalise them; add constant for line length.
src/main.rs Refactor CLI options into FormatOpts; add breaks flag; update processing logic and signatures.
tests/integration.rs Add tests for format_breaks and CLI integration of the --breaks flag.

Sequence Diagram(s)

sequenceDiagram
    participant User
    participant CLI
    participant Library

    User->>CLI: Run mdtablefix with --breaks
    CLI->>CLI: Parse arguments (wrap, renumber, breaks)
    CLI->>Library: Call format_breaks(lines) if breaks enabled
    Library-->>CLI: Return lines with thematic breaks normalised
    CLI-->>User: Output formatted Markdown
Loading

Poem

A line of stars, a dash, or three,
Now morphs to underscores, seventy,
The CLI learns a brand new trick,
With tests to prove it’s smooth and slick.
Markdown’s breaks are neat and true—
Thanks to the fix, your docs shine through!

✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch codex/add-breaks-commandline-option

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai auto-generate unit tests to generate unit tests for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link
Copy Markdown
Contributor

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @leynos - I've reviewed your changes and found some issues that need to be addressed.

  • Extract the hardcoded break length (70) into a named constant so it’s easy to adjust and document.
  • Consider grouping the wrap/renumber/breaks flags into a single config struct instead of passing multiple booleans through process_lines and rewrite_path.
  • Add tests for additional edge cases (e.g. mixed characters, varying leading whitespace) to validate the thematic break regex covers all valid patterns.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- Extract the hardcoded break length (70) into a named constant so it’s easy to adjust and document.
- Consider grouping the wrap/renumber/breaks flags into a single config struct instead of passing multiple booleans through process_lines and rewrite_path.
- Add tests for additional edge cases (e.g. mixed characters, varying leading whitespace) to validate the thematic break regex covers all valid patterns.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between e22e748 and ca54aaf.

📒 Files selected for processing (4)
  • README.md (1 hunks)
  • src/lib.rs (2 hunks)
  • src/main.rs (3 hunks)
  • tests/integration.rs (2 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
**/*.md

Instructions used from:

Sources:
📄 CodeRabbit Inference Engine

  • AGENTS.md

⚙️ CodeRabbit Configuration File

**/*.rs

Instructions used from:

Sources:
📄 CodeRabbit Inference Engine

  • AGENTS.md

⚙️ CodeRabbit Configuration File

🧬 Code Graph Analysis (1)
tests/integration.rs (2)
src/html.rs (1)
  • convert_html_tables (294-337)
src/lib.rs (2)
  • format_breaks (549-568)
  • renumber_lists (498-541)
🪛 GitHub Actions: CI
tests/integration.rs

[error] 820-823: Clippy error: calls to push immediately after creation. Consider using the vec![] macro instead of creating a Vec and pushing elements. (clippy::vec_init_then_push)

🔇 Additional comments (12)
src/lib.rs (2)

230-232: LGTM: Regex pattern correctly implements CommonMark thematic break specification.

The regex properly matches thematic breaks with up to three leading spaces, followed by three or more matching characters (*, -, or _) optionally separated by spaces or tabs.


543-568: LGTM: Function implementation follows established patterns and correctly handles fenced code blocks.

The format_breaks function properly tracks fenced code block state and only processes thematic breaks outside code blocks. The implementation is consistent with other similar functions in the codebase like renumber_lists.

README.md (2)

23-23: LGTM: Usage line correctly includes the new --breaks option.

The command-line usage documentation properly reflects the new formatting option alongside existing flags.


29-29: LGTM: Clear and concise description of the --breaks functionality.

The bullet point accurately describes what the --breaks option does, maintaining consistency with other option descriptions.

tests/integration.rs (3)

4-10: LGTM: Import addition is correct and follows existing patterns.

The format_breaks function is properly imported alongside other library functions.


827-834: LGTM: Test correctly verifies that code blocks are ignored.

The test ensures that thematic breaks inside fenced code blocks remain unchanged, which is the expected behaviour.


836-849: LGTM: CLI integration test properly validates the --breaks option.

The test correctly invokes the CLI with the --breaks flag and verifies the expected output format.

src/main.rs (5)

8-8: LGTM: Import addition is correct and necessary.

The format_breaks function is properly imported for use in the processing pipeline.


16-33: LGTM: CLI refactoring improves code organisation.

The introduction of FormatOpts struct effectively groups related formatting flags and makes the CLI structure more maintainable. The breaks field is properly documented and follows existing patterns.


35-48: LGTM: Function signature and implementation correctly handle the new breaks parameter.

The process_lines function properly accepts and conditionally applies the format_breaks function when the breaks flag is enabled. The implementation follows the established pattern used for other formatting options.


50-55: LGTM: File rewriting function correctly passes through the breaks parameter.

The rewrite_path function signature and implementation properly thread the breaks parameter to process_lines.


87-87: LGTM: All function calls correctly pass the breaks parameter from CLI options.

The main function properly extracts the breaks flag from cli.opts.breaks and passes it to all relevant function calls, ensuring consistent behaviour across different execution paths.

Also applies to: 94-94, 98-98

Comment thread tests/integration.rs
@leynos
Copy link
Copy Markdown
Owner Author

leynos commented Jul 13, 2025

@coderabbitai

Please suggest a fix for the following error and provide a prompt suitable for passing to an agentic AI coding tool:

error: calls to `push` immediately after creation
   --> tests/integration.rs:820:5
    |
820 | /     let mut expected = Vec::new();
821 | |     expected.push("foo".to_string());
822 | |     expected.push("_".repeat(70));
823 | |     expected.push("bar".to_string());
    | |_____________________________________^ help: consider using the `vec![]` macro: `let expected = vec![..];`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#vec_init_then_push
    = note: `-D clippy::vec-init-then-push` implied by `-D warnings`
    = help: to override `-D warnings` add `#[allow(clippy::vec_init_then_push)]`

error: could not compile `mdtablefix` (test "integration") due to 1 previous error
Error: Process completed with exit code 101.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Jul 13, 2025

Tip

For best results, initiate chat on the files or code changes.

🧩 Analysis chain

@leynos Here's the fix for the Clippy error and the prompt for an agentic AI coding tool:

Fix

Replace lines 820-823 in tests/integration.rs with:

let expected = vec![
    "foo".to_string(),
    "_".repeat(70),
    "bar".to_string(),
];

This addresses the clippy::vec-init-then-push lint by using the more idiomatic vec![] macro instead of creating an empty vector and immediately pushing values to it.

Agentic AI Coding Tool Prompt

Fix the Clippy lint error `clippy::vec-init-then-push` in the file `tests/integration.rs` at lines 820-823. Replace the pattern of creating an empty Vec with Vec::new() followed by immediate push calls with the vec![] macro. The current code creates a vector and pushes three string values: "foo".to_string(), "_".repeat(70), and "bar".to_string(). Convert this to use the vec![] macro for more idiomatic Rust code.

This change makes the code more concise, eliminates the need for a mutable variable, and follows Rust best practices.


🏁 Script executed:

#!/bin/bash
# Let's look at the specific lines in tests/integration.rs around line 820
sed -n '815,825p' tests/integration.rs

Length of output: 389


@leynos Perfect! Now I can see the exact context. Here's the precise fix and AI tool prompt:

Fix

Replace lines 820-823 in tests/integration.rs with:

let expected = vec![
    "foo".to_string(),
    "_".repeat(70),
    "bar".to_string(),
];

The complete fixed function will look like:

fn test_format_breaks_basic() {
    let input = vec!["foo", "***", "bar"]
        .into_iter()
        .map(str::to_string)
        .collect::<Vec<_>>();
    let expected = vec![
        "foo".to_string(),
        "_".repeat(70),
        "bar".to_string(),
    ];
    assert_eq!(format_breaks(&input), expected);
}

Agentic AI Coding Tool Prompt

In the file tests/integration.rs, fix the Clippy lint error `clippy::vec-init-then-push` at lines 820-823 in the function `test_format_breaks_basic()`. Replace the following code:

let mut expected = Vec::new();
expected.push("foo".to_string());
expected.push("_".repeat(70));
expected.push("bar".to_string());

With the more idiomatic vec![] macro:

let expected = vec![
    "foo".to_string(),
    "_".repeat(70),
    "bar".to_string(),
];

This eliminates the mutable variable and follows Rust best practices.

This change will resolve the Clippy warning and make the code more idiomatic and readable.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

📜 Review details

Configuration used: CodeRabbit UI
Review profile: ASSERTIVE
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between bf2b75a and d1cd407.

📒 Files selected for processing (2)
  • README.md (1 hunks)
  • src/lib.rs (2 hunks)
🧰 Additional context used
📓 Path-based instructions (2)
**/*.md

Instructions used from:

Sources:
📄 CodeRabbit Inference Engine

  • AGENTS.md

⚙️ CodeRabbit Configuration File

**/*.rs

Instructions used from:

Sources:
📄 CodeRabbit Inference Engine

  • AGENTS.md

⚙️ CodeRabbit Configuration File

⏰ Context from checks skipped due to timeout of 240000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: build-test

Comment thread src/lib.rs
Comment on lines +569 to +573
if !in_code && THEMATIC_BREAK_RE.is_match(line.trim_end()) {
out.push("_".repeat(THEMATIC_BREAK_LEN));
} else {
out.push(line.clone());
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛠️ Refactor suggestion

Preserve leading indentation when rewriting thematic breaks

Dropping the original leading whitespace alters the visual alignment of thematic breaks that sit inside nested structures (e.g. list items). Capture the whitespace prefix (up to three spaces per the spec) and prepend it to the generated underscore line.

-            out.push("_".repeat(THEMATIC_BREAK_LEN));
+            let indent: String = line.chars().take_while(|c| c.is_whitespace()).collect();
+            out.push(format!("{indent}{}", "_".repeat(THEMATIC_BREAK_LEN)));
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
if !in_code && THEMATIC_BREAK_RE.is_match(line.trim_end()) {
out.push("_".repeat(THEMATIC_BREAK_LEN));
} else {
out.push(line.clone());
}
if !in_code && THEMATIC_BREAK_RE.is_match(line.trim_end()) {
let indent: String = line.chars().take_while(|c| c.is_whitespace()).collect();
out.push(format!("{indent}{}", "_".repeat(THEMATIC_BREAK_LEN)));
} else {
out.push(line.clone());
}
🤖 Prompt for AI Agents
In src/lib.rs around lines 569 to 573, the code replaces thematic break lines
with underscores but drops the original leading whitespace, which breaks
indentation in nested structures. Modify the code to capture up to three leading
spaces from the original line and prepend this whitespace to the generated
underscore line before pushing it to the output, preserving the visual
alignment.

Comment thread src/lib.rs
Comment on lines +569 to +571
if !in_code && THEMATIC_BREAK_RE.is_match(line.trim_end()) {
out.push("_".repeat(THEMATIC_BREAK_LEN));
} else {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Avoid repeated heap allocation for the underscore line

"_".repeat(THEMATIC_BREAK_LEN) allocates a fresh String for every thematic break. Store a single static &str and clone it as needed.

+/// Pre-computed 70-underscore break to avoid repeated allocation.
+static THEMATIC_BREAK_LINE: &str = "______________________________________________________________________";
...
-            out.push("_".repeat(THEMATIC_BREAK_LEN));
+            let indent: String = line.chars().take_while(|c| c.is_whitespace()).collect();
+            out.push(format!("{indent}{THEMATIC_BREAK_LINE}"));

Run cargo +nightly-2025-06-10 fmt --all and cargo clippy -- -D warnings after applying.

📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
if !in_code && THEMATIC_BREAK_RE.is_match(line.trim_end()) {
out.push("_".repeat(THEMATIC_BREAK_LEN));
} else {
/// Pre-computed 70-underscore break to avoid repeated allocation.
static THEMATIC_BREAK_LINE: &str =
"______________________________________________________________________";
// … later in the function …
if !in_code && THEMATIC_BREAK_RE.is_match(line.trim_end()) {
let indent: String = line
.chars()
.take_while(|c| c.is_whitespace())
.collect();
out.push(format!("{indent}{THEMATIC_BREAK_LINE}"));
} else {
// …
}
🤖 Prompt for AI Agents
In src/lib.rs around lines 569 to 571, the code repeatedly allocates a new
String with "_".repeat(THEMATIC_BREAK_LEN) for each thematic break, causing
unnecessary heap allocations. To fix this, define a static &str with the
underscore line repeated THEMATIC_BREAK_LEN times once, then clone or reuse this
static string whenever needed instead of calling repeat each time. After making
this change, run cargo +nightly-2025-06-10 fmt --all and cargo clippy -- -D
warnings to ensure formatting and linting compliance.

Comment thread README.md
Comment on lines +31 to +32
- Use `--breaks` to normalize thematic breaks to a line of 70 underscores
(configurable via the `THEMATIC_BREAK_LEN` constant).
Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot Jul 13, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🧹 Nitpick (assertive)

Use en-GB spelling and finish the bullet with a full stop

Maintain stylistic consistency with the rest of the bullets.

- Use `--breaks` to normalize thematic breaks to a line of 70 underscores
- (configurable via the `THEMATIC_BREAK_LEN` constant).
+ Use `--breaks` to normalise thematic breaks to a line of 70 underscores.
+   (Configurable via the `THEMATIC_BREAK_LEN` constant.)
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
- Use `--breaks` to normalize thematic breaks to a line of 70 underscores
(configurable via the `THEMATIC_BREAK_LEN` constant).
- Use `--breaks` to normalise thematic breaks to a line of 70 underscores.
(Configurable via the `THEMATIC_BREAK_LEN` constant.)
🤖 Prompt for AI Agents
In README.md around lines 31 to 32, update the bullet point to use en-GB
spelling by changing "normalize" to "normalise" and ensure the sentence ends
with a full stop to maintain stylistic consistency with other bullet points.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This repo uses en-oxendict spelling

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@leynos Thank you for the correction! You're absolutely right. I apologise for the error in my previous suggestion. Oxford spelling (en-oxendic) uses "-ize" endings, so "normalize" is indeed the correct spelling for this repository. I should not have suggested changing it to "normalise".


✏️ Learnings added
Learnt from: leynos
PR: leynos/mdtablefix#57
File: README.md:31-32
Timestamp: 2025-07-13T22:20:49.785Z
Learning: This repository uses en-oxendic (Oxford) spelling for markdown files, which means using "-ize" endings (like "normalize") rather than "-ise" endings (like "normalise"), while maintaining other British spelling conventions.

Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.

@leynos leynos merged commit 1320a9d into main Jul 13, 2025
2 checks passed
@leynos leynos deleted the codex/add-breaks-commandline-option branch July 13, 2025 22:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant