leetcode-cli
Cookies
The cookie plugin of leetcode-cil can work on OSX and Linux, If you are on other platforms or your cookies just don't want to be catched, you can handwrite your LeetCode Cookies to ~/.leetcode/leetcode.toml
# Make sure `leetcode.toml` file is placed at `~/.leetcode/leetcode.toml`
[]
= "..."
= "..."
How to find LeetCode Cookies?
For Example, if you're using chrome to login to leetcode.com.
Step 1
Open chrome and paste the link below to the chrome linkbar
.
chrome://settings/cookies/detail?site=leetcode.com
Step 2
Copy the contents of LEETCODE_SESSION
and csrftoken
.
Step 3
Paste them to session
and csrf
.
# Make sure `leetcode.toml` file is placed at `~/.leetcode/leetcode.toml`
[]
= "${LEETCODE_SESSION}"
= "${csrf}"
Building
Usage
Please make sure you have logined in leetcode.com
with chrome
, more info plz checkout this
Example
For example, if your config is:
[]
= "rust"
= "emacs"
1. pick
2. edit
3. test
4. submit
Success
Runtime: 0 ms, faster than 100% of Rustonline submissions for Two Sum.
Memory Usage: 2.4 MB, less than 100% of Rustonline submissions for Two Sum.
Features
- the edit flow —— solution files will generate automatically!
- doc support,
lc-rs
can compile the annotation of your solutions to markdown!- btw, generate a site is easy for
lc-rs
!
- btw, generate a site is easy for
- support local signal to keep coding as longer as you want.
PR
PR is welcome, here it is.
LICENSE
MIT