Skip to content

Commit

Permalink
fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
kearfy committed Nov 5, 2024
1 parent e3fc5ab commit 33d372c
Show file tree
Hide file tree
Showing 5 changed files with 34 additions and 33 deletions.
3 changes: 3 additions & 0 deletions fix-deps.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
echo "$(echo -n 'import { ConnectionOptions } from "./lib-src/embedded";
'; cat index.d.ts)" > index.d.ts
3 changes: 2 additions & 1 deletion index.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { ConnectionOptions } from "./lib-src/embedded.js";
import { ConnectionOptions } from "./lib-src/embedded";

/* tslint:disable */
/* eslint-disable */

Expand Down
36 changes: 18 additions & 18 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.android-arm64.node')
} else {
nativeBinding = require('surrealdb.node-android-arm64')
nativeBinding = require('@surrealdb/node-android-arm64')
}
} catch (e) {
loadError = e
Expand All @@ -49,7 +49,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.android-arm-eabi.node')
} else {
nativeBinding = require('surrealdb.node-android-arm-eabi')
nativeBinding = require('@surrealdb/node-android-arm-eabi')
}
} catch (e) {
loadError = e
Expand All @@ -69,7 +69,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.win32-x64-msvc.node')
} else {
nativeBinding = require('surrealdb.node-win32-x64-msvc')
nativeBinding = require('@surrealdb/node-win32-x64-msvc')
}
} catch (e) {
loadError = e
Expand All @@ -83,7 +83,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.win32-ia32-msvc.node')
} else {
nativeBinding = require('surrealdb.node-win32-ia32-msvc')
nativeBinding = require('@surrealdb/node-win32-ia32-msvc')
}
} catch (e) {
loadError = e
Expand All @@ -97,7 +97,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.win32-arm64-msvc.node')
} else {
nativeBinding = require('surrealdb.node-win32-arm64-msvc')
nativeBinding = require('@surrealdb/node-win32-arm64-msvc')
}
} catch (e) {
loadError = e
Expand All @@ -113,7 +113,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.darwin-universal.node')
} else {
nativeBinding = require('surrealdb.node-darwin-universal')
nativeBinding = require('@surrealdb/node-darwin-universal')
}
break
} catch {}
Expand All @@ -124,7 +124,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.darwin-x64.node')
} else {
nativeBinding = require('surrealdb.node-darwin-x64')
nativeBinding = require('@surrealdb/node-darwin-x64')
}
} catch (e) {
loadError = e
Expand All @@ -138,7 +138,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.darwin-arm64.node')
} else {
nativeBinding = require('surrealdb.node-darwin-arm64')
nativeBinding = require('@surrealdb/node-darwin-arm64')
}
} catch (e) {
loadError = e
Expand All @@ -157,7 +157,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.freebsd-x64.node')
} else {
nativeBinding = require('surrealdb.node-freebsd-x64')
nativeBinding = require('@surrealdb/node-freebsd-x64')
}
} catch (e) {
loadError = e
Expand All @@ -174,7 +174,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.linux-x64-musl.node')
} else {
nativeBinding = require('surrealdb.node-linux-x64-musl')
nativeBinding = require('@surrealdb/node-linux-x64-musl')
}
} catch (e) {
loadError = e
Expand All @@ -187,7 +187,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.linux-x64-gnu.node')
} else {
nativeBinding = require('surrealdb.node-linux-x64-gnu')
nativeBinding = require('@surrealdb/node-linux-x64-gnu')
}
} catch (e) {
loadError = e
Expand All @@ -203,7 +203,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.linux-arm64-musl.node')
} else {
nativeBinding = require('surrealdb.node-linux-arm64-musl')
nativeBinding = require('@surrealdb/node-linux-arm64-musl')
}
} catch (e) {
loadError = e
Expand All @@ -216,7 +216,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.linux-arm64-gnu.node')
} else {
nativeBinding = require('surrealdb.node-linux-arm64-gnu')
nativeBinding = require('@surrealdb/node-linux-arm64-gnu')
}
} catch (e) {
loadError = e
Expand All @@ -232,7 +232,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.linux-arm-musleabihf.node')
} else {
nativeBinding = require('surrealdb.node-linux-arm-musleabihf')
nativeBinding = require('@surrealdb/node-linux-arm-musleabihf')
}
} catch (e) {
loadError = e
Expand All @@ -245,7 +245,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.linux-arm-gnueabihf.node')
} else {
nativeBinding = require('surrealdb.node-linux-arm-gnueabihf')
nativeBinding = require('@surrealdb/node-linux-arm-gnueabihf')
}
} catch (e) {
loadError = e
Expand All @@ -261,7 +261,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.linux-riscv64-musl.node')
} else {
nativeBinding = require('surrealdb.node-linux-riscv64-musl')
nativeBinding = require('@surrealdb/node-linux-riscv64-musl')
}
} catch (e) {
loadError = e
Expand All @@ -274,7 +274,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.linux-riscv64-gnu.node')
} else {
nativeBinding = require('surrealdb.node-linux-riscv64-gnu')
nativeBinding = require('@surrealdb/node-linux-riscv64-gnu')
}
} catch (e) {
loadError = e
Expand All @@ -289,7 +289,7 @@ switch (platform) {
if (localFileExisted) {
nativeBinding = require('./surrealdb.node.linux-s390x-gnu.node')
} else {
nativeBinding = require('surrealdb.node-linux-s390x-gnu')
nativeBinding = require('@surrealdb/node-linux-s390x-gnu')
}
} catch (e) {
loadError = e
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,10 @@
"typescript": "^5.5.4"
},
"dependencies": {
"surrealdb": "^1.0.0-beta.19"
"surrealdb": "^1.0.6"
},
"peerDependencies": {
"surrealdb": "^1.0.0-beta.19"
"surrealdb": "^1.0.6"
},
"ava": {
"timeout": "3m"
Expand Down
21 changes: 9 additions & 12 deletions pnpm-lock.yaml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 33d372c

Please sign in to comment.