@altairalabs/packc 0.0.1 → 0.0.2

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.
Files changed (2) hide show
  1. package/package.json +2 -1
  2. package/postinstall.js +13 -7
package/package.json CHANGED
@@ -1,6 +1,7 @@
1
1
  {
2
2
  "name": "@altairalabs/packc",
3
- "version": "0.0.1",
3
+ "version": "0.0.2",
4
+ "type": "module",
4
5
  "description": "PromptKit Pack Compiler - Compile and validate prompt packs for LLM applications",
5
6
  "bin": {
6
7
  "packc": "./bin/packc.js"
package/postinstall.js CHANGED
@@ -1,12 +1,18 @@
1
1
  #!/usr/bin/env node
2
2
 
3
- const https = require('node:https');
4
- const http = require('node:http');
5
- const fs = require('node:fs');
6
- const path = require('node:path');
7
- const { execSync } = require('node:child_process');
8
- const { pipeline } = require('node:stream');
9
- const { promisify } = require('node:util');
3
+ import https from 'node:https';
4
+ import http from 'node:http';
5
+ import fs from 'node:fs';
6
+ import path from 'node:path';
7
+ import { execSync } from 'node:child_process';
8
+ import { pipeline } from 'node:stream';
9
+ import { promisify } from 'node:util';
10
+ import { fileURLToPath } from 'node:url';
11
+ import { createRequire } from 'node:module';
12
+
13
+ const require = createRequire(import.meta.url);
14
+ const __filename = fileURLToPath(import.meta.url);
15
+ const __dirname = path.dirname(__filename);
10
16
 
11
17
  const streamPipeline = promisify(pipeline);
12
18