{"library":"rumdl","title":"rumdl","description":"rumdl is a high-performance Markdown linter and formatter written in Rust. It offers 71 lint rules, automatic formatting, and zero dependencies, providing a fast and consistent way to enforce best practices in Markdown files. The Python package primarily serves as a distribution mechanism for the `rumdl` CLI binary, and the project is actively maintained with frequent releases.","language":"python","status":"active","last_verified":"Thu Apr 16","install":{"commands":["pip install rumdl"],"cli":{"name":"rumdl","version":"rumdl 0.1.93"}},"imports":["import subprocess\n# rumdl is primarily a CLI tool; there is no direct Python API for linting functions.\n# Interact via subprocess calls."],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import subprocess\nimport os\n\n# Create a dummy markdown file\nmarkdown_content = \"\"\"\n# Hello World\n\nThis is a test.\n\n- List item 1\n- List item 2 \n  - Nested list item\n\nSome **bold** text.\n\"\"\"\n\nfile_path = \"test.md\"\nwith open(file_path, \"w\") as f:\n    f.write(markdown_content)\n\nprint(f\"Linting {file_path}...\")\n\n# Run rumdl check\n# capture_output=True and text=True are important for programmatic interaction\nresult = subprocess.run(['rumdl', 'check', file_path], capture_output=True, text=True)\n\nif result.returncode != 0:\n    print(\"Linting found issues:\")\n    print(result.stdout)\n    print(result.stderr)\nelse:\n    print(\"No linting issues found.\")\n\n# Optionally, try formatting:\n# result_fmt = subprocess.run(['rumdl', 'fmt', file_path], capture_output=True, text=True)\n# if result_fmt.returncode != 0:\n#     print(\"Formatting failed:\")\n#     print(result_fmt.stdout)\n#     print(result_fmt.stderr)\n# else:\n#     print(\"File formatted successfully (or no changes needed).\")\n#     with open(file_path, \"r\") as f:\n#         print(\"Formatted content:\")\n#         print(f.read())\n\n# Clean up the dummy file\nos.remove(file_path)\n","lang":"python","description":"Demonstrates how to invoke the `rumdl` CLI tool from Python using the `subprocess` module to lint a Markdown file. The primary interaction with `rumdl` is through its command-line interface, which the `pip` package installs.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}