libdragon 12.0.2 → 12.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -66,24 +66,22 @@ const exec = async (info) => {
66
66
  const stdin = new PassThrough();
67
67
 
68
68
  /** @type {string[]} */
69
- const paramsWithConvertedPaths = (
70
- await Promise.all(
71
- parameters.map(async (item) => {
72
- if (item.startsWith('-')) {
73
- return item;
74
- }
75
- if (
76
- item.includes(path.sep) &&
77
- ((await fileExists(item)) || (await dirExists(item)))
78
- ) {
79
- return toPosixPath(
80
- path.isAbsolute(item) ? path.relative(process.cwd(), item) : item
81
- );
82
- }
69
+ const paramsWithConvertedPaths = await Promise.all(
70
+ parameters.map(async (item) => {
71
+ if (item.startsWith('-')) {
83
72
  return item;
84
- })
85
- )
86
- ).map((param) => `"${param}"`);
73
+ }
74
+ if (
75
+ item.includes(path.sep) &&
76
+ ((await fileExists(item)) || (await dirExists(item)))
77
+ ) {
78
+ return toPosixPath(
79
+ path.isAbsolute(item) ? path.relative(process.cwd(), item) : item
80
+ );
81
+ }
82
+ return item;
83
+ })
84
+ );
87
85
 
88
86
  /**
89
87
  *
@@ -59,7 +59,12 @@ const initContainer = async (libdragonInfo) => {
59
59
  '-R',
60
60
  `${uid >= 0 ? uid : ''}:${gid >= 0 ? gid : ''}`,
61
61
  '/n64_toolchain',
62
- ]
62
+ ],
63
+ {
64
+ spawnOptions: {
65
+ shell: true,
66
+ },
67
+ }
63
68
  );
64
69
  } catch (e) {
65
70
  // Dispose the invalid container, clean and exit
@@ -320,6 +320,7 @@ const dockerExec = /** @type {DockerExec} */ (
320
320
  ...options,
321
321
  spawnOptions: {
322
322
  cwd: workDir,
323
+ shell: false,
323
324
  ...options?.spawnOptions,
324
325
  },
325
326
  });
package/modules/utils.js CHANGED
@@ -40,7 +40,12 @@ const installDependencies = async (libdragonInfo) => {
40
40
  CONTAINER_TARGET_PATH + '/' + libdragonInfo.vendorDirectory,
41
41
  ...dockerHostUserParams(libdragonInfo),
42
42
  ],
43
- ['/bin/bash', './build.sh']
43
+ ['/bin/bash', './build.sh'],
44
+ {
45
+ spawnOptions: {
46
+ shell: true,
47
+ },
48
+ }
44
49
  );
45
50
  };
46
51
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "libdragon",
3
- "version": "12.0.2",
3
+ "version": "12.0.3",
4
4
  "description": "This is a docker wrapper for libdragon",
5
5
  "main": "index.js",
6
6
  "engines": {