Skip to content

Commit fa14a7c

Browse files
author
kaelzhang
committed
updates template to avoid npm to rename .gitignore to .npmignore; #21
related to npm/npm#1862
1 parent 8362cc7 commit fa14a7c

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

index.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,10 @@ generator._pkgData = function (pkg) {
114114
// TODO: related to kaelzhang/node-commonjs-walker#10
115115
.replace(/\.js$/, '');
116116

117+
// npm will rename .gitignore to .npmignore:
118+
// [ref](https://github.com/npm/npm/issues/1862)
119+
pkg.gitignore = '.gitignore';
120+
117121
return pkg;
118122
};
119123

templates/default/index.html

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,12 @@
22
<head>
33
<meta charset="UTF-8">
44

5-
<script src="http://localhost:9074/mod/neuron/latest/neuron.js"></script>
5+
<script src="./neurons/neuron/latest/neuron.js"></script>
66
<script>
77
neuron.config({
8-
path: 'http://localhost:9074/mod'
8+
path: './neurons'
99
});
1010
</script>
11-
1211
</head>
1312

1413
<body>
File renamed without changes.

0 commit comments

Comments
 (0)