mirror of
https://github.com/Foundry376/Mailspring.git
synced 2025-01-06 08:08:10 +08:00
fix(build): fix lstatSync throwing
This commit is contained in:
parent
60d2c24693
commit
cc124be849
1 changed files with 4 additions and 3 deletions
|
@ -18,9 +18,10 @@ module.exports = (grunt) ->
|
||||||
from = path.join(rootDir, 'packages', plugin)
|
from = path.join(rootDir, 'packages', plugin)
|
||||||
to = path.join(path.resolve('internal_packages'), plugin)
|
to = path.join(path.resolve('internal_packages'), plugin)
|
||||||
|
|
||||||
if fs.lstatSync(to)
|
try
|
||||||
grunt.log.writeln "Removing old symlink at #{to}"
|
if fs.lstatSync(to)
|
||||||
fs.unlinkSync(to)
|
grunt.log.writeln "Removing old symlink at #{to}"
|
||||||
|
fs.unlinkSync(to)
|
||||||
|
|
||||||
grunt.log.writeln "Adding '#{plugin}' to internal_packages"
|
grunt.log.writeln "Adding '#{plugin}' to internal_packages"
|
||||||
fs.symlinkSync(from, to, 'dir')
|
fs.symlinkSync(from, to, 'dir')
|
||||||
|
|
Loading…
Reference in a new issue