0

whenever I'm running commands like firebase login, firebase init the error at command prompt appears that

C:\Users\UserName\AppData\Roaming\npm\node_modules\firebase-tools\node_modules\configstore\index.js:69 throw err;

and

Error: EEXIST: file already exists, mkdir 'C:\Users\UserName.config\configstore'

Ryan
  • 1,988
  • 4
  • 21
  • 34
blackHawk
  • 6,047
  • 13
  • 57
  • 100

1 Answers1

1

I would suspect that some other application or tool is also using using the configstore folder to store their files, and the configstore module that the firebase-tools is using is throwing an error because it tried to recreate the folder when it was already there. An exception being thrown that they did not handle correctly.

This happens a lot and personally is a huge annoyance to me. I do not understand why they use such a generic file name to store their config with the chance that another program will do the same.

Anyways, all my complaints aside, try opening up some of the files in that configstore folder in a text editor and see if you can see what other program is using them. If it is something you don't use anymore, simply remove it. If it is, then you might have a bigger problem. If that's the case, you would have to either pick which program/tool to use, or find a way to change where it looks for it's configuration files. I personally know for sure that bower uses this same exact directory for it's config files.

Hope this helps. It's a frustrating thing when two applications collide over something so easily preventable.

Ryan
  • 1,988
  • 4
  • 21
  • 34
  • I just removed that whole folder, it had bower as you said and typings.json something – blackHawk Sep 26 '16 at 20:15
  • Did that stop the error and allow you to run your code? – Ryan Sep 26 '16 at 20:17
  • Yes its working fine. Before this problem i was facing eperm error i did nothing just saw what read and write permissions, and it solved automatically, why is it happens – blackHawk Sep 26 '16 at 20:17
  • Are you using the current version of firebase? – Ryan Sep 26 '16 at 20:18
  • Yes current version – blackHawk Sep 26 '16 at 20:19
  • I can't say exactly. If you still have issues like this I would try backing up your project, then try removing all the firebase installs and try reinstalling them, either manually or with your package manager. – Ryan Sep 26 '16 at 20:21
  • Let us [continue this discussion in chat](http://chat.stackoverflow.com/rooms/124244/discussion-between-ryan-and-blackhawk). – Ryan Sep 26 '16 at 20:22
  • Save it for another time – blackHawk Sep 26 '16 at 20:24
  • Not a problem! I hope you get the rest figured out (: – Ryan Sep 26 '16 at 20:25
  • Its above mid night here. Sleepy – blackHawk Sep 26 '16 at 20:26
  • I faced this error when I ran firebase in a docker container and exported the data to a docker volume! It wouldn't work simply because docker already created the folder. I provided a sub-directory within the docker volume folder and it worked like a charm! I've been trying to resolve this for more than 2 weeks now! – Andrew Nessin Jun 14 '22 at 03:33