kguzek / kguzek/leetcode-project-generator
Add new language interfaces
- Dominant language
- Python
- Stars
- 4
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
Currently, the project only supports code generation in C. In order to support more languages, each language requires an implementation of [BaseLanguageInterface](https://github.com/kguzek/leetcode-project-generator/blob/main/src/lpg/interfaces/lang/base.py) in [interfaces/lang](https://github.com/kguzek/leetcode-project-generator/tree/main/src/lpg/interfaces/lang). Additionally, the interface will need to be registered in [interfaces/file.py](https://github.com/kguzek/leetcode-project-generator/blob/main/src/lpg/interfaces/file.py#L8) to be available for use via the CLI.
List of languages to be added:
- [x] python
- [x] python3 (thanks @dancikmad)
- [x] javascript
- [x] typescript
- [x] c
- [ ] cpp
- [ ] csharp
- [x] java
- [ ] php
- [ ] swift
- [ ] kotlin
- [ ] dart
- [x] golang (thanks @dancikmad)
- [ ] ruby
- [ ] scala
- [ ] rust
- [ ] racket
- [ ] erlang
- [ ] elixir
If you know any of the above languages and are willing to help, feel free to submit a PR and mention me to check it out!
> [!TIP]
> Be sure to use the provided unit test to verify your implementation handles various cases:
> ```sh
> python -m src.lpg.interfaces.lang_test
> ```
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with src/lpg/interfaces/lang/base.py to understand BaseLanguageInterface, then inspect the existing implementations under src/lpg/interfaces/lang and registration in src/lpg/interfaces/file.py. Choose one unchecked language, register it for CLI use, and run python -m src.lpg.interfaces.lang_test to verify the implementation handles the provided cases.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c, cpp, csharp, dart, elixir, erlang, go, java, javascript, kotlin, php, python, ruby, rust, scala, swift, typescript
- Domain
- cli, tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100