Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 38 additions & 0 deletions .github/workflows/cd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,3 +55,41 @@ jobs:
echo "published=${{ steps.release.outputs.new_release_published }}" >> $GITHUB_OUTPUT
echo "New release: ${{ steps.release.outputs.new_release_version }}"
fi

publish:
name: publish to pypi
runs-on: ubuntu-latest
needs: versioning
if: needs.versioning.outputs.new_release_published == 'true'
environment:
name: pypi
url: https://pypi.org/p/leetcode-py
permissions:
id-token: write
steps:
- name: Checkout
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0

- name: Set up Python
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b # v5.3.0
with:
python-version: "3.13"

- name: Install Poetry
uses: snok/install-poetry@76e04a911780d5b312d89783f7b1cd627778900a # v1.4.1
with:
version: latest
virtualenvs-create: true
virtualenvs-in-project: true

- name: Update version in pyproject.toml
run: |
poetry version ${{ needs.versioning.outputs.new_release_version }}

- name: Build package
run: poetry build

- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@15c56dba361d8335944d31a2ecd17d700fc7bcbc # v1.12.2
with:
verbose: true
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,9 @@ A modern Python LeetCode practice environment that goes beyond basic problem sol
- 🚀 **Modern Python**: PEP 585/604 type hints, Poetry, and professional tooling
- 📊 **Quality Assurance**: 95%+ test coverage, security scanning, automated linting

Includes all **75 Grind problems** - the most essential coding interview questions curated for maximum impact.

## 🎯 What's Included

**Current**: All 75 problems from [Grind 75](https://www.techinterviewhandbook.org/grind75/) - the most essential coding interview problems curated by the creator of Blind 75.
**Current**: All 75 problems from [Grind 75](https://www.techinterviewhandbook.org/grind75/) - the most essential coding interview questions curated by the creator of Blind 75.

**Future**: Planned expansion to all 169 Grind problems for comprehensive interview preparation.

Expand Down
4 changes: 2 additions & 2 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

25 changes: 20 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,12 +1,28 @@
[tool.poetry]
name = "leetcode-py"
version = "0.1.0"
description = "LeetCode solutions in Python"
authors = ["Your Name <[email protected]>"]
name = "leetcode-py-sdk"
version = "0.1.0" # use git tag instead
description = "Modern Python LeetCode practice environment with automated problem generation, beautiful data structure visualizations, and comprehensive testing"
authors = ["Wisaroot Lertthaweedech <[email protected]>"]
license = "Apache-2.0"
readme = "README.md"
homepage = "https://github.com/wisarootl/leetcode-py"
repository = "https://github.com/wisarootl/leetcode-py"
keywords = ["leetcode", "algorithms", "data-structures", "interview-prep", "coding-practice"]
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Intended Audience :: Education",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Education",
"License :: OSI Approved :: Apache Software License",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.13",
]
packages = [{include = "leetcode_py"}]

[tool.poetry.dependencies]
python = "^3.13"
graphviz = "^0.21"
requests = "^2.32.5"
typer = "^0.17.0"

Expand All @@ -17,7 +33,6 @@ loguru = "^0.7.3"
[tool.poetry.group.dev.dependencies]
black = "^25.1.0"
cookiecutter = "^2.6.0"
graphviz = "^0.21"
ipykernel = "^6.30.1"
isort = "^6.0.1"
jupytext = "^1.16.6"
Expand Down