Skip to content

Commit

Permalink
fix ffmpeg path for windows electron binaries (manually shipping ffmpeg)
Browse files Browse the repository at this point in the history
  • Loading branch information
benkaiser committed Jan 2, 2016
1 parent 3dd15ad commit 51004eb
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
7 changes: 7 additions & 0 deletions library_functions.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,13 @@ var async = require('async');
var SoundcloudResolver = require('soundcloud-resolver');
var ytdl = require('ytdl-core');
var youtubePlaylistInfo = require('youtube-playlist-info').playlistInfo;
var os = require('os');

// if the platform is windows, set these
if (os.platform() === 'win32') {
process.env.FFMPEG_PATH = path.join(__dirname, 'ffmpeg.exe');
process.env.FFPROBE_PATH = path.join(__dirname, 'ffprobe.exe');
}

// ffmpeg is optional, allow failure of loading
try {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"ytdl-core": "*"
},
"optionalDependencies": {
"ffmetadata": "^1.3.0",
"ffmetadata": "git+https://github.com/benkaiser/node-ffmetadata.git",
"fluent-ffmpeg": "~2.0.0-rc1"
},
"devDependencies": {
Expand Down

0 comments on commit 51004eb

Please sign in to comment.