question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to delete output folder via Finder when tmpdir=true

See original GitHub issue

When packaging an app on OS X (v10.11.4) using the default settings for out and tmpdir, the resulting [product name]-darwin-x64 output folder cannot be deleted via Finder. When attempting to delete it, Finder asks for an admin password, but then fails with a permissions error message. However, the folder appears to be properly owned and accessible to me, and I can delete it just fine via terminal with normal user privileges.

I discovered that if I use the --tmpdir=false option, I can delete the output folder just fine, so this issue seems to be related to the fs.move call in moveApp of common.js (so maybe it’s actually a problem with fs-extra?). It’s certainly not a major issue, but I’m curious to know what’s causing it! Any ideas?

Which version of electron-packager are you using?

7.0.2

What CLI arguments are you passing? Alternatively, if you are using the API, what parameters are you passing to the packager() function?

electron-packager . product-name --platform=darwin --arch=x64 --osx-sign.identity="[signing identity]" --ignore="[regex galore]" --download.strictSSL=true --icon design/icon.icns

What version of Electron are you building with?

1.0.2

What is the host platform are you running electron-packager on?

OS X El Capitan v10.11.4 (15E65)

What target platform(s)/architecture(s) are you building for?

--platform=darwin --arch=x64

Is there a stack trace in the error message you’re seeing?

N/A

Please provide either a failing testcase or detailed steps to reproduce your problem.

  1. Package an application without specifying the out or tmpdir flags
  2. Attempt to delete the resulting output folder via Finder

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Reactions:21
  • Comments:12 (5 by maintainers)

github_iconTop GitHub Comments

6reactions
kaansoralcommented, Aug 18, 2016

This was super demotivating, thanks a lot for your analysis @giilby --tmpdir=false seems like a good solution

Whenever something like this happens on OSX, it triggers my paranoia, hope this gets solved and others don’t experience the same thing too, just wasted 45 minutes in anxiety until I found this issue

3reactions
riccardolardicommented, Feb 1, 2017

Same problem here, MacOS Sierra 10.12.3. Can only remove the folder using bruteforce sudo rm -rf [foldername]

Read more comments on GitHub >

github_iconTop Results From Across the Web

Cannot delete folder from Finder - Apple Community
It left a folder called "Audio Music Apps" in the Music folder, which I cannot delete. Anytime I try to delete it, it...
Read more >
Unable to delete file through Finder in Desktop folder
I'm opening Finder and trying to delete a file or directory in Desktop folder. Hitting cmd+backspace or Move to trash doesn't work.
Read more >
Solved: Unable to delete "My Mac" folder in Dropbox despit...
Solve issues with deleting, editing, and organizing files and folders in your Dropbox account with support from the Dropbox Community.
Read more >
In Finder and Terminal — can not delete a folder, (Error ...
Hi David - I saw that (3 links) in the long output (after running ls -@RelO), but then it never showed what they...
Read more >
Can't delete old work OneDrive folder from Mac
I need to delete my work OneDrive folders off my Macbook air. ... The OneDrive was set up to be "on demand" but...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found