mirror of
https://github.com/zadam/trilium.git
synced 2025-10-18 22:29:57 +02:00
fix(flake): bettersqlite3 dependency not build properly
This commit is contained in:
parent
831a184c2a
commit
1191421388
@ -200,7 +200,7 @@
|
||||
# '/build/source/apps/desktop/node_modules/better-sqlite3/build/node_gyp_bins'
|
||||
preBuildCommands = ''
|
||||
export npm_config_nodedir=${electron.headers}
|
||||
pnpm postinstall || true
|
||||
pnpm postinstall
|
||||
'';
|
||||
buildTask = "desktop:build";
|
||||
mainProgram = "trilium";
|
||||
|
@ -23,7 +23,7 @@ function copyNativeDependencies(projectRoot: string) {
|
||||
cpSync(sourcePath, destPath, { recursive: true, dereference: true });
|
||||
}
|
||||
|
||||
function rebuildNativeDependencies(projectRoot: string) {
|
||||
async function rebuildNativeDependencies(projectRoot: string) {
|
||||
const electronVersion = determineElectronVersion(projectRoot);
|
||||
|
||||
if (!electronVersion) {
|
||||
@ -35,7 +35,7 @@ function rebuildNativeDependencies(projectRoot: string) {
|
||||
console.log(`Rebuilding ${projectRoot} with ${electronVersion} for ${targetArch}...`);
|
||||
|
||||
const resolvedPath = resolve(projectRoot);
|
||||
rebuild({
|
||||
await rebuild({
|
||||
projectRootPath: resolvedPath,
|
||||
buildPath: resolvedPath,
|
||||
electronVersion,
|
||||
@ -64,5 +64,5 @@ function determineElectronVersion(projectRoot: string) {
|
||||
|
||||
for (const projectRoot of [ "apps/desktop", "apps/edit-docs" ]) {
|
||||
copyNativeDependencies(projectRoot);
|
||||
rebuildNativeDependencies(projectRoot);
|
||||
await rebuildNativeDependencies(projectRoot);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user