Skip to content

Commit 4f458c0

Browse files
committed
Allow same * destination
1 parent ac3f3f8 commit 4f458c0

File tree

8 files changed

+21
-4
lines changed

8 files changed

+21
-4
lines changed

docs/index.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

esm/interpreter/_utils.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ const calculateFilesPaths = files => {
128128
else {
129129
const url = parseTemplate(source, map);
130130
const path = fillName(url, parseTemplate(dest || './', map));
131-
if (targets.has(path))
131+
if (targets.has(path) && !path.endsWith('/*'))
132132
throw new SyntaxError(`Duplicated destination: ${path}`);
133133
targets.add(path);
134134
sourceDest.push({ url, path });

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,6 @@
8888
"to-json-callback": "^0.1.1"
8989
},
9090
"worker": {
91-
"blob": "sha256-q3F8S0fpbtQrs9PkgOIbLQeYahmzu3z2eABsNHH1zMo="
91+
"blob": "sha256-y6/jxBwsS9vdnsnAT+1dSKY8MQMctwF5QUikF6che60="
9292
}
9393
}

test/issue-2240/a.zip

204 Bytes
Binary file not shown.

test/issue-2240/b.zip

204 Bytes
Binary file not shown.

test/issue-2240/index.html

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<!DOCTYPE html>
2+
<html lang="en">
3+
<head>
4+
<meta charset="UTF-8">
5+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
6+
<script type="module" src="../../dist/index.js"></script>
7+
<script type="micropython" config="settings.json">
8+
import a, b
9+
</script>
10+
</head>
11+
</html>

test/issue-2240/settings.json

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
{
2+
"files": {
3+
"a.zip": "./*",
4+
"b.zip": "./*"
5+
}
6+
}

0 commit comments

Comments
 (0)