Skip to content

Commit 2a3ca48

Browse files
committedMay 8, 2018
update scripts
1 parent 8cf85ec commit 2a3ca48

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed
 

‎README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,10 @@
99
```bash
1010
# get ready
1111
npm install
12+
1213
# create a solution file: npm run create $leetcodeProblemUrl
1314
npm run create https://leetcode.com/problems/two-sum
15+
1416
# build
1517
npm run build
1618
```

‎build/index.js

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,10 @@ function buildProblems () {
8686
});
8787
}
8888

89+
function sortProblems () {
90+
problemList.sort((a, b) => a.id - b.id);
91+
}
92+
8993
function buildPages () {
9094
listRender(
9195
'page',
@@ -152,6 +156,7 @@ function buildDifficulties () {
152156
}
153157

154158
buildProblems();
159+
sortProblems();
155160
buildPages();
156161
buildTags();
157162
buildDifficulties();

0 commit comments

Comments
 (0)