Skip to content

Commit

Permalink
Update leetcode-cli to v2.6.1
Browse files Browse the repository at this point in the history
  • Loading branch information
jdneo committed Dec 5, 2018
1 parent 3bae2a2 commit b3ddf71
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 37 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Check [Keep a Changelog](http://keepachangelog.com/) for recommendations on how

## [0.8.1]
### Changed
- Upgrade LeetCode CLI to v2.6.0
- Upgrade LeetCode CLI to v2.6.1

## [0.8.0]
### Added
Expand Down
62 changes: 28 additions & 34 deletions package-lock.json

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

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@
},
"dependencies": {
"fs-extra": "^6.0.1",
"leetcode-cli": "2.6.0",
"leetcode-cli": "2.6.1",
"opn": "^5.2.0"
}
}
2 changes: 1 addition & 1 deletion src/commands/list.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export async function listProblems(): Promise<IProblem[]> {
const result: string = await leetCodeExecutor.listProblems(showLocked);
const problems: IProblem[] = [];
const lines: string[] = result.split("\n");
const reg: RegExp = /^(.)\s(.{1,2})\s(.)\s\[\s*(\d*)\]\s*(.*)\s*(Easy|Medium|Hard)\s*\((\s*\d+\.\d+ %)\)/;
const reg: RegExp = /^(.)\s(.{1,2})\s(.)\s\[\s*(\d*)\s*\]\s*(.*)\s*(Easy|Medium|Hard)\s*\((\s*\d+\.\d+ %)\)/;
for (const line of lines) {
const match: RegExpMatchArray | null = line.match(reg);
if (match && match.length === 8) {
Expand Down

0 comments on commit b3ddf71

Please sign in to comment.