Skip to content

Commit 6e207bc

Browse files
authored
fix: broken URL in generated webpack.config.js (#2600)
1 parent 0144aaa commit 6e207bc

File tree

3 files changed

+50
-25
lines changed

3 files changed

+50
-25
lines changed

packages/generators/init-template/default/webpack.configjs.tpl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
// Generated using webpack-cli http://github.com/webpack-cli
1+
// Generated using webpack-cli https://github.com/webpack/webpack-cli
2+
23
const path = require('path');<% if (htmlWebpackPlugin) { %>
34
const HtmlWebpackPlugin = require('html-webpack-plugin');<% } %><% if (isExtractPlugin) { %>
45
const MiniCssExtractPlugin = require('mini-css-extract-plugin');<% } %>

test/init/__snapshots__/init.test.js.snap.webpack4

Lines changed: 24 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ Object {
4242
`;
4343

4444
exports[`init command should configure WDS as opted 2`] = `
45-
"// Generated using webpack-cli http://github.com/webpack-cli
45+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
46+
4647
const path = require('path');
4748

4849
module.exports = {
@@ -96,7 +97,8 @@ Object {
9697
`;
9798

9899
exports[`init command should configure assets modules by default 2`] = `
99-
"// Generated using webpack-cli http://github.com/webpack-cli
100+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
101+
100102
const path = require('path');
101103
const HtmlWebpackPlugin = require('html-webpack-plugin');
102104

@@ -153,7 +155,8 @@ Object {
153155
`;
154156

155157
exports[`init command should configure html-webpack-plugin as opted 2`] = `
156-
"// Generated using webpack-cli http://github.com/webpack-cli
158+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
159+
157160
const path = require('path');
158161
const HtmlWebpackPlugin = require('html-webpack-plugin');
159162

@@ -208,7 +211,8 @@ Object {
208211
`;
209212

210213
exports[`init command should generate ES6 project correctly 2`] = `
211-
"// Generated using webpack-cli http://github.com/webpack-cli
214+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
215+
212216
const path = require('path');
213217

214218
module.exports = {
@@ -324,7 +328,8 @@ Object {
324328
`;
325329

326330
exports[`init command should generate typescript project correctly 2`] = `
327-
"// Generated using webpack-cli http://github.com/webpack-cli
331+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
332+
328333
const path = require('path');
329334

330335
module.exports = {
@@ -381,7 +386,8 @@ Object {
381386
`;
382387

383388
exports[`init command should use less in project when selected 2`] = `
384-
"// Generated using webpack-cli http://github.com/webpack-cli
389+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
390+
385391
const path = require('path');
386392

387393
module.exports = {
@@ -435,7 +441,8 @@ Object {
435441
`;
436442

437443
exports[`init command should use mini-css-extract-plugin when selected 2`] = `
438-
"// Generated using webpack-cli http://github.com/webpack-cli
444+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
445+
439446
const path = require('path');
440447
const MiniCssExtractPlugin = require('mini-css-extract-plugin');
441448

@@ -471,7 +478,8 @@ module.exports = {
471478
`;
472479

473480
exports[`init command should use postcss in project when selected 1`] = `
474-
"// Generated using webpack-cli http://github.com/webpack-cli
481+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
482+
475483
const path = require('path');
476484

477485
module.exports = {
@@ -529,7 +537,8 @@ Object {
529537
`;
530538

531539
exports[`init command should use sass and css with postcss in project when selected 2`] = `
532-
"// Generated using webpack-cli http://github.com/webpack-cli
540+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
541+
533542
const path = require('path');
534543

535544
module.exports = {
@@ -586,7 +595,8 @@ Object {
586595
`;
587596

588597
exports[`init command should use sass in project when selected 2`] = `
589-
"// Generated using webpack-cli http://github.com/webpack-cli
598+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
599+
590600
const path = require('path');
591601

592602
module.exports = {
@@ -642,7 +652,8 @@ Object {
642652
`;
643653

644654
exports[`init command should use sass with postcss in project when selected 2`] = `
645-
"// Generated using webpack-cli http://github.com/webpack-cli
655+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
656+
646657
const path = require('path');
647658

648659
module.exports = {
@@ -695,7 +706,8 @@ Object {
695706
`;
696707

697708
exports[`init command should use stylus in project when selected 2`] = `
698-
"// Generated using webpack-cli http://github.com/webpack-cli
709+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
710+
699711
const path = require('path');
700712

701713
module.exports = {

test/init/__snapshots__/init.test.js.snap.webpack5

Lines changed: 24 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,8 @@ Object {
4242
`;
4343

4444
exports[`init command should configure WDS as opted 2`] = `
45-
"// Generated using webpack-cli http://github.com/webpack-cli
45+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
46+
4647
const path = require('path');
4748

4849
module.exports = {
@@ -96,7 +97,8 @@ Object {
9697
`;
9798

9899
exports[`init command should configure assets modules by default 2`] = `
99-
"// Generated using webpack-cli http://github.com/webpack-cli
100+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
101+
100102
const path = require('path');
101103
const HtmlWebpackPlugin = require('html-webpack-plugin');
102104

@@ -153,7 +155,8 @@ Object {
153155
`;
154156

155157
exports[`init command should configure html-webpack-plugin as opted 2`] = `
156-
"// Generated using webpack-cli http://github.com/webpack-cli
158+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
159+
157160
const path = require('path');
158161
const HtmlWebpackPlugin = require('html-webpack-plugin');
159162

@@ -208,7 +211,8 @@ Object {
208211
`;
209212

210213
exports[`init command should generate ES6 project correctly 2`] = `
211-
"// Generated using webpack-cli http://github.com/webpack-cli
214+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
215+
212216
const path = require('path');
213217

214218
module.exports = {
@@ -324,7 +328,8 @@ Object {
324328
`;
325329

326330
exports[`init command should generate typescript project correctly 2`] = `
327-
"// Generated using webpack-cli http://github.com/webpack-cli
331+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
332+
328333
const path = require('path');
329334

330335
module.exports = {
@@ -381,7 +386,8 @@ Object {
381386
`;
382387

383388
exports[`init command should use less in project when selected 2`] = `
384-
"// Generated using webpack-cli http://github.com/webpack-cli
389+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
390+
385391
const path = require('path');
386392

387393
module.exports = {
@@ -435,7 +441,8 @@ Object {
435441
`;
436442

437443
exports[`init command should use mini-css-extract-plugin when selected 2`] = `
438-
"// Generated using webpack-cli http://github.com/webpack-cli
444+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
445+
439446
const path = require('path');
440447
const MiniCssExtractPlugin = require('mini-css-extract-plugin');
441448

@@ -471,7 +478,8 @@ module.exports = {
471478
`;
472479

473480
exports[`init command should use postcss in project when selected 1`] = `
474-
"// Generated using webpack-cli http://github.com/webpack-cli
481+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
482+
475483
const path = require('path');
476484

477485
module.exports = {
@@ -529,7 +537,8 @@ Object {
529537
`;
530538

531539
exports[`init command should use sass and css with postcss in project when selected 2`] = `
532-
"// Generated using webpack-cli http://github.com/webpack-cli
540+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
541+
533542
const path = require('path');
534543

535544
module.exports = {
@@ -586,7 +595,8 @@ Object {
586595
`;
587596

588597
exports[`init command should use sass in project when selected 2`] = `
589-
"// Generated using webpack-cli http://github.com/webpack-cli
598+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
599+
590600
const path = require('path');
591601

592602
module.exports = {
@@ -642,7 +652,8 @@ Object {
642652
`;
643653

644654
exports[`init command should use sass with postcss in project when selected 2`] = `
645-
"// Generated using webpack-cli http://github.com/webpack-cli
655+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
656+
646657
const path = require('path');
647658

648659
module.exports = {
@@ -695,7 +706,8 @@ Object {
695706
`;
696707

697708
exports[`init command should use stylus in project when selected 2`] = `
698-
"// Generated using webpack-cli http://github.com/webpack-cli
709+
"// Generated using webpack-cli https://github.com/webpack/webpack-cli
710+
699711
const path = require('path');
700712

701713
module.exports = {

0 commit comments

Comments
 (0)