about summary refs log tree commit diff
path: root/pkgs/by-name/vd/vdhcoapp/ffmpeg-filepicker.patch
blob: f6fb777e186e9640afc65c01049f11759e735701 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
diff --git a/src/converter.js b/src/converter.js
index af7b4c3..20da407 100644
--- a/src/converter.js
+++ b/src/converter.js
@@ -1,4 +1,4 @@
-import open from 'open';
+const open = import('open');
 
 const os = require("os");
 const path = require('path');
@@ -9,9 +9,9 @@ const rpc = require('./weh-rpc');
 
 const exec_dir = path.dirname(process.execPath);
 
-const ffmpeg = findExecutableFullPath("ffmpeg", exec_dir);
-const ffprobe = findExecutableFullPath("ffprobe", exec_dir);
-const filepicker = findExecutableFullPath("filepicker", exec_dir);
+const ffmpeg = "@ffmpeg@/bin/ffmpeg";
+const ffprobe = "@ffmpeg@/bin/ffprobe";
+const filepicker = "@filepicker@";
 
 if (!fileExistsSync(ffmpeg)) {
   logger.error("ffmpeg not found. Install ffmpeg and make sure it's in your path.");
diff --git a/src/main.js b/src/main.js
index 47b92de..e2e9402 100644
--- a/src/main.js
+++ b/src/main.js
@@ -1,4 +1,4 @@
-const config = require('config.json');
+const config = require('./config.json');
 const converter = require('./converter');
 const os = require("os");
 
diff --git a/src/native-autoinstall.js b/src/native-autoinstall.js
index 556a22b..c729568 100644
--- a/src/native-autoinstall.js
+++ b/src/native-autoinstall.js
@@ -1,7 +1,7 @@
 const os = require("os");
 const path = require("path");
 const { spawn, exec } = require('child_process');
-const config = require('config.json');
+const config = require('./config.json');
 
 let fs;
 if (process.versions.node.startsWith("10")) {