diff options
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/package.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/scripts/package.js b/scripts/package.js index 90a05a9..a241edc 100644 --- a/scripts/package.js +++ b/scripts/package.js | |||
@@ -92,6 +92,13 @@ Please make sure it contains: id, name, config`); | |||
92 | console.log('No package with ID found - creating new.'); | 92 | console.log('No package with ID found - creating new.'); |
93 | all.push(packageInfo); | 93 | all.push(packageInfo); |
94 | } | 94 | } |
95 | |||
96 | // Sort package list alphabetically | ||
97 | all = all.sort((a, b) => { | ||
98 | var textA = a.id.toLowerCase(); | ||
99 | var textB = b.id.toLowerCase(); | ||
100 | return (textA < textB) ? -1 : (textA > textB) ? 1 : 0; | ||
101 | }); | ||
95 | await fs.writeJson(allJson, all, { | 102 | await fs.writeJson(allJson, all, { |
96 | spaces: 2, | 103 | spaces: 2, |
97 | EOL: '\n', | 104 | EOL: '\n', |