Skip to content

Commit

Permalink
Fix Asar path for gifsicle (wulkano#912)
Browse files Browse the repository at this point in the history
  • Loading branch information
karaggeorge authored and sindresorhus committed Aug 18, 2020
1 parent 45591b5 commit aa8ddaf
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion main/convert.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ const {track} = require('./common/analytics');
const {EditServiceContext} = require('./service-context');
const settings = require('./common/settings');

const gifsiclePath = util.fixPathForAsarUnpack(gifsicle);
const ffmpegPath = util.fixPathForAsarUnpack(ffmpeg.path);
const timeRegex = /time=\s*(\d\d:\d\d:\d\d.\d\d)/gm;
const speedRegex = /speed=\s*(-?\d+(,\d+)*(\.\d+(e\d+)?)?)/gm;
Expand All @@ -28,7 +29,7 @@ const areDimensionsEven = ({width, height}) => width % 2 === 0 && height % 2 ===
const getRunFunction = (shouldTrack, mode = 'convert') => (outputPath, options, args) => {
const modes = new Map([
['convert', ffmpegPath],
['compress', gifsicle]
['compress', gifsiclePath]
]);
const program = modes.get(mode);

Expand Down

0 comments on commit aa8ddaf

Please sign in to comment.