mdformat-space-control 0.4.2__tar.gz → 0.4.3__tar.gz
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.
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/PKG-INFO +1 -1
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/mdformat_space_control/__init__.py +1 -1
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/mdformat_space_control/plugin.py +6 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/.editorconfig +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/.gitignore +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/CLAUDE.md +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/LICENSE +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/README.md +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/dev/CLAUDE.md +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/dev/contributing.md +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/dev/default-formatting-style.md +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/dev/installation-and-usage.md +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/dev/overview.md +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/dev/plugins.md +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/mdformat_space_control/config.py +0 -0
- {mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/pyproject.toml +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mdformat_space_control
|
|
3
|
-
Version: 0.4.
|
|
3
|
+
Version: 0.4.3
|
|
4
4
|
Summary: An mdformat plugin for space control: EditorConfig indentation, tight lists, frontmatter spacing, smart dash conversion, explicit line breaks, and wikilinks.
|
|
5
5
|
Project-URL: Homepage, https://github.com/jdmonaco/mdformat-space-control
|
|
6
6
|
Author-email: Joseph Monaco <joe@selfmotion.net>
|
{mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/mdformat_space_control/plugin.py
RENAMED
|
@@ -411,6 +411,9 @@ def _convert_dash_sequences(text: str) -> str:
|
|
|
411
411
|
em_dash_re = re.compile(r"(?<!-)---(?!-)")
|
|
412
412
|
en_dash_re = re.compile(r"(?<!-)--(?!-)")
|
|
413
413
|
|
|
414
|
+
# CLI option pattern: --word or ---word preceded by whitespace or line start
|
|
415
|
+
cli_option_re = re.compile(r"(?<=\s)-{2,3}(?=\w)")
|
|
416
|
+
|
|
414
417
|
# Lines that are only dashes (thematic breaks, frontmatter delimiters)
|
|
415
418
|
only_dashes_re = re.compile(r"^-{2,}\s*$")
|
|
416
419
|
|
|
@@ -453,6 +456,9 @@ def _convert_dash_sequences(text: str) -> str:
|
|
|
453
456
|
protected = html_comment_re.sub(_save_placeholder, protected)
|
|
454
457
|
protected = html_tag_re.sub(_save_placeholder, protected)
|
|
455
458
|
|
|
459
|
+
# Protect CLI option dashes (e.g., --output, ---long-opt)
|
|
460
|
+
protected = cli_option_re.sub(_save_placeholder, protected)
|
|
461
|
+
|
|
456
462
|
# Convert em-dash first (longer match), then en-dash
|
|
457
463
|
protected = em_dash_re.sub("\u2014", protected)
|
|
458
464
|
protected = en_dash_re.sub("\u2013", protected)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/dev/default-formatting-style.md
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{mdformat_space_control-0.4.2 → mdformat_space_control-0.4.3}/mdformat_space_control/config.py
RENAMED
|
File without changes
|
|
File without changes
|