spindb 0.2.2 → 0.2.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/bin/cli.js +7 -2
- package/package.json +1 -1
package/bin/cli.js
CHANGED
|
@@ -1,10 +1,15 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
3
|
import { register } from 'tsx/esm/api'
|
|
4
|
+
import { fileURLToPath } from 'url'
|
|
5
|
+
import { dirname, resolve } from 'path'
|
|
4
6
|
|
|
5
|
-
//
|
|
7
|
+
// Get the directory where this script is located
|
|
8
|
+
const __dirname = dirname(fileURLToPath(import.meta.url))
|
|
9
|
+
|
|
10
|
+
// Resolve tsconfig path - it should be in the package root
|
|
6
11
|
register({
|
|
7
|
-
tsconfig: '
|
|
12
|
+
tsconfig: resolve(__dirname, '../tsconfig.json'),
|
|
8
13
|
})
|
|
9
14
|
|
|
10
15
|
await import('../src/bin/cli.ts')
|