uncomment 3.0.2

A CLI tool to remove comments from code using tree-sitter for accurate parsing
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# This is a line comment that should be removed
"""This is a module docstring that should be preserved."""


def greet(name):
    """Return a greeting for the given name."""
    # This comment should be removed
    url = "http://example.com#anchor"  # noqa: E501
    message = "Hello # world"
    # TODO: add logging here
    # FIXME: handle empty name
    return f"{message}, {name}!"


result = greet("Alice")