Skip to content

Commit a830fad

Browse files
committed
feat: complete phase 2 Resource Packaging
1 parent ff6c403 commit a830fad

File tree

95 files changed

+155
-110
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

95 files changed

+155
-110
lines changed

.amazonq/plans/cli-implementation.md

Lines changed: 33 additions & 5 deletions

.templates/check_test_cases.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import json
44
from pathlib import Path
5-
from typing import Optional
5+
66
import typer
77

88

.templates/leetcode/gen.py

Lines changed: 0 additions & 26 deletions
This file was deleted.

.templates/leetcode/scrape.py

Lines changed: 0 additions & 48 deletions
This file was deleted.

Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ define lint_target
2424
poetry run black $(1)
2525
poetry run isort $(1)
2626
$(if $(filter .,$(1)), \
27-
poetry run nbqa ruff . --nbqa-exclude=".templates" --ignore=F401$(COMMA)F821, \
27+
poetry run nbqa ruff . --nbqa-exclude="leetcode_py/cli/resources/" --ignore=F401$(COMMA)F821, \
2828
poetry run nbqa ruff $(1) --ignore=F401$(COMMA)F821)
2929
poetry run ruff check $(1) --exclude="**/*.ipynb"
3030
poetry run mypy $(1) \
@@ -33,10 +33,10 @@ define lint_target
3333
--non-interactive \
3434
--check-untyped-defs
3535
$(if $(filter .,$(1)), \
36-
poetry run nbqa isort . --nbqa-exclude=".templates", \
36+
poetry run nbqa isort . --nbqa-exclude="leetcode_py/cli/resources/", \
3737
poetry run nbqa isort $(1))
3838
$(if $(filter .,$(1)), \
39-
poetry run nbqa mypy . --nbqa-exclude=".templates" \
39+
poetry run nbqa mypy . --nbqa-exclude="leetcode_py/cli/resources/" \
4040
--ignore-missing-imports --disable-error-code=name-defined, \
4141
poetry run nbqa mypy $(1) --ignore-missing-imports --disable-error-code=name-defined)
4242
endef

README.md

Lines changed: 3 additions & 3 deletions
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# #!/usr/bin/env python3
2+
# """Compatibility wrapper for generator."""
3+
# import sys
4+
# from pathlib import Path
5+
# sys.path.insert(0, str(Path(__file__).parent.parent.parent))
6+
7+
# import typer
8+
# from leetcode_py.tools import TemplateGenerator
9+
10+
# app = typer.Typer(help="Generate LeetCode problem templates")
11+
12+
13+
# @app.command()
14+
# def generate(
15+
# json_file: str = typer.Argument(help="Path to JSON problem definition"),
16+
# force: bool = typer.Option(False, "--force", help="Force overwrite existing files")
17+
# ):
18+
# """Generate LeetCode problem from JSON using cookiecutter."""
19+
# generator = TemplateGenerator()
20+
# template_dir = Path(__file__).parent
21+
# output_dir = template_dir.parent.parent / "leetcode"
22+
# generator.generate_problem(json_file, template_dir, output_dir, force)
23+
24+
25+
# if __name__ == "__main__":
26+
# app()

0 commit comments

Comments
 (0)