@ade-syofyan/feature-map-pro 0.21.0-pro.2 → 0.21.0-pro.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.
package/lib/installer.mjs CHANGED
@@ -75,8 +75,14 @@ function engineValid(root,entry,platform) {
75
75
  verifyChecksum(fs.readFileSync(file),entry.engine_sha256);return true;
76
76
  } catch {return false;}
77
77
  }
78
+ export function tarExecutable(platform=process.platform,systemRoot=process.env.SystemRoot||process.env.SYSTEMROOT) {
79
+ if(platform!=='win32') return 'tar';
80
+ const executable=systemRoot&&path.join(systemRoot,'System32','tar.exe');
81
+ if(!executable||!fs.existsSync(executable)) throw new Error('Tar bawaan Windows tidak tersedia. Gunakan Windows 10/11 dengan tar.');
82
+ return executable;
83
+ }
78
84
  function tar(args) {
79
- const result=spawnSync('tar',args,{encoding:'utf8',maxBuffer:8*1024*1024});
85
+ const result=spawnSync(tarExecutable(),args,{encoding:'utf8',maxBuffer:8*1024*1024});
80
86
  if(result.error||result.status!==0) throw new Error('Paket tidak bisa dibaca. Pastikan tar tersedia.');
81
87
  return result.stdout;
82
88
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ade-syofyan/feature-map-pro",
3
- "version": "0.21.0-pro.2",
3
+ "version": "0.21.0-pro.3",
4
4
  "description": "Installer and launcher for licensed Feature Map Pro",
5
5
  "private": false,
6
6
  "type": "module",
package/release.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "schema_version": 1,
3
- "version": "0.21.0-pro.2",
3
+ "version": "0.21.0-pro.3",
4
4
  "artifacts": {
5
5
  "darwin-arm64": {
6
6
  "sha256": "fa90315978ee367eb169fb885d360d8e9830769752105e050eb7f95ac49b5a7d",