fix(linux): Resolve linux launch issue due to missing require

This commit is contained in:
Ben Gotow 2015-07-02 19:15:46 +02:00
parent ef960b21c8
commit 9542d1179e

View file

@ -121,6 +121,7 @@ class DatabaseManager
dblite.bin = "#{vendor}/sqlite3-win32.exe"
resolve(dblite)
else if process.platform is 'linux'
{exec} = require 'child_process'
exec "uname -a", (err, stdout, stderr) ->
arch = if stdout.toString().indexOf('x86_64') is -1 then "32" else "64"
dblite.bin = "#{vendor}/sqlite3-linux-#{arch}"