Skip to content

Commit 8acfe7d

Browse files
authored
Merge pull request #715 from simon04/fetch-webpack-contrib
Fetch also webpack-contrib plugins
2 parents 6e4652e + 80a8f16 commit 8acfe7d

File tree

2 files changed

+11
-4
lines changed

2 files changed

+11
-4
lines changed

scripts/fetch.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,10 @@ mkdir -p ./generated/plugins
88
cp -rf ./content/plugins/ ./generated/plugins
99

1010
# Fetches github.com/webpack/*-loader repositories
11-
./scripts/fetch_package_names.js "-loader" | ./scripts/fetch_package_files.js "README.md" "./generated/loaders"
11+
./scripts/fetch_package_names.js "webpack" "-loader" | ./scripts/fetch_package_files.js "README.md" "./generated/loaders"
1212

1313
# Fetches github.com/webpack/*-webpack-plugin repositories
14-
./scripts/fetch_package_names.js "-webpack-plugin" | ./scripts/fetch_package_files.js "README.md" "./generated/plugins"
14+
./scripts/fetch_package_names.js "webpack" "-webpack-plugin" | ./scripts/fetch_package_files.js "README.md" "./generated/plugins"
15+
16+
# Fetches github.com/webpack-contrib/*-webpack-plugin repositories
17+
./scripts/fetch_package_names.js "webpack-contrib" "-webpack-plugin" | ./scripts/fetch_package_files.js "README.md" "./generated/plugins"

scripts/fetch_package_names.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,14 +10,18 @@ if (require.main === module) {
1010
}
1111

1212
function main() {
13-
const suffix = process.argv[2];
13+
const organization = process.argv[2];
14+
const suffix = process.argv[3];
1415

16+
if(!organization) {
17+
return console.error('Missing organization!');
18+
}
1519
if(!suffix) {
1620
return console.error('Missing suffix!');
1721
}
1822

1923
fetchPackageNames({
20-
organization: 'webpack',
24+
organization: organization,
2125
suffix: suffix
2226
}, function(err, d) {
2327
if (err) {

0 commit comments

Comments
 (0)