📅 leetrs daily
Fetches today's LeetCode Problem of the Day and opens it the same way pick does.
Usage
leetrs daily [OPTIONS] [LANGUAGE]
Arguments
| Argument | Type | Required | Description |
|---|---|---|---|
[LANGUAGE] | string | No | Language for the code template (python, rust, pandas, mysql, postgres). Defaults to the config.toml setting. |
Options
| Option | Type | Required | Description |
|---|---|---|---|
-p, --preview | flag | No | Print the problem description Markdown to stdout without opening an editor. |
-b, --browser | flag | No | Open the problem in your default web browser in addition to default behavior. |
Behaviour
- The active challenge comes from LeetCode's
questionOfTodayGraphQL query. Its date, number, title and difficulty are printed tostderrbefore the problem is picked, soleetrs daily --preview > problem.mdkeeps that line out of the file. - Files are written and reused exactly as with
pick. - If today's problem is for LeetCode Premium subscribers and your account is not premium,
dailystops with a message instead of failing on the missing content. If premium status can't be confirmed, it warns and tries anyway. - When
-bor--browseris passed, the problem URL (https://leetcode.com/problems/<slug>) is opened in your default browser.
leetrs daily
leetrs daily rust
leetrs daily -b
leetrs daily --preview