Skip to content

Commit

Permalink
add ffmpeg support (#116)
Browse files Browse the repository at this point in the history
* add ffmpeg support

* add ffmpeg support
  • Loading branch information
gengjiawen authored and tabrindle committed Sep 18, 2019
1 parent 418b58d commit 037a9dd
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 1 deletion.
5 changes: 5 additions & 0 deletions __tests__/utils.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,11 @@ const cases = {
11.0.10240.17443`,
version: '11.0.10240.17443',
},
ffmpeg: {
string: `ffmpeg version 4.2 Copyright (c) 2000-2019 the FFmpeg developers
built with gcc 9.1.1 (GCC) 20190807`,
version: '4.2'
},
go: {
string: 'go version go1.9.3 darwin/amd64',
version: '1.9.3',
Expand Down
1 change: 1 addition & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ install:
test_script:
- node --version
- npm --version
- choco install ffmpeg
- choco install r.project -version 3.6.0
- set RPATH=C:\Program Files\R\R-3.6.0\bin\x64
- set PATH=%RPATH%;%PATH%
Expand Down
8 changes: 8 additions & 0 deletions src/helpers/utilities.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,4 +80,12 @@ module.exports = {
}
return Promise.resolve(['Subversion', 'N/A']);
},

getFFmpegInfo: () => {
utils.log('trace', 'getFFmpegInfo');
return Promise.all([
utils.run('ffmpeg -version').then(utils.findVersion),
utils.which('ffmpeg'),
]).then(v => utils.determineFound('FFmpeg', v[0], v[1]));
},
};
2 changes: 1 addition & 1 deletion src/presets.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ module.exports = {
'RubyGems',
'Yum',
],
Utilities: ['CMake', 'Make', 'GCC', 'Git', 'Clang', 'Mercurial', 'Subversion'],
Utilities: ['CMake', 'Make', 'GCC', 'Git', 'Clang', 'Mercurial', 'Subversion', 'FFmpeg'],
Servers: ['Apache', 'Nginx'],
Virtualization: ['Docker', 'Parallels', 'VirtualBox', 'VMware Fusion'],
SDKs: ['iOS SDK', 'Android SDK'],
Expand Down

0 comments on commit 037a9dd

Please sign in to comment.