Atom won't install packages to my oddly named User directory


#1

Hello,

I’ve tried installing atom several times but I can’t install packages. I get the following message instead: ‘C:\Users\R’ is not recognized as an internal or external command,
operable program or batch file.

My user directory is: ‘C:\Users\R&M.atom\packages’

Is the ‘&’ throwing this off somehow or what is going on here/suggested solutions?

I tried changing the user folder, but windows 10 is making that complicated so I’m asking here first.

Many many thanks,
Az


#2

missed a part of the error that says: The system cannot find the path specified.


#3

For clarification: are you able to successfully install Atom, but it errors when you try to install packages?


#4

Correct, no error on install.

Settings–>install–>type ‘tabletopsimulator-lue’–>click ‘Packages’–>message from above


#5

There is an issue for this here https://github.com/atom/atom/issues/13178. This has been fixed and will be working again in Atom 1.14.


#6

Okay, I’m pretty sure what’s going on is that apm, the program that installs packages for Atom, is not putting quotes around the path. You can test this on your own: create a folder such as C:\R&M, open a command line, and type cd C:\R&M, then cd "C:\R&M". You will observe the first command failing and the second command working as expected. In order to fix this, APM will need to be patched. I’ve dropped an issue onto the APM repo and it shouldn’t be a difficult fix.

In the mean time, you have two options. You already know the first, which is to wrestle with the slightly overbearing Windows 10 account system and try to get it to give you a new user folder name. The second is to download git if you don’t already have it (or a GUI client like GitKraken) and clone the repos of any packages you want to install into your .atom/packages folder. Once you have the code for an Atom package on your hard drive, you can navigate to that folder via the command line and issue the apm install command, which will set the package up. Then open or reload Atom.


#7

That was an absolutely perfect response. Thank you for helping me out!

I’ll not ask you to troubleshoot with me further. I feel a little out of my depth using either proposed solution. I will be able to figure it out given time though, thanks to you! Just quickly, I’m trying to evaluate how much effort it is worth. I saw your issue on the APM repo and it looks like it was quickly addressed. Do you think this will be fixed in the relatively near future (1-2 weeks) or shall I muddle through?

Thanks again for your help!


#8

It seems that it’s already been fixed and is just waiting for release. That gives you another option: to build Atom from the source code of the current dev version.

Of those options, I suggest trying out git. For what you’d be doing, it’s really simple and will teach you a fair bit about a couple of tools that are widely used in developer circles (git is extremely useful and APM is modeled after the Node.js package manager system). It also won’t mess anything up if you do something wrong. :smiley:

New versions come out at a pretty good clip, but I can’t personally say when it would be out. This is slated for 1.14.0, which will become the beta version when 1.13.0 is released, which should be pretty soon (the beta versions get automatically built and released on GitHub like the stable versions, and I haven’t had difficulties with them). @Wliu would be able to give you a release estimate.


#9

You are the best!

Thanks for all your help. With luck I’ll find the time to try the git fix :slight_smile:


#10

Trust me when I say that I could do it from a cold start in like ten minutes, accounting for download and install times. I’ll give you the step-by-step right now so that you don’t have to worry about any ambiguity if you try it.

  1. Choose whether you want to work from the command line or a GUI for managing your repos. I have both installed and they’re both valuable for me, but GitKraken provides a very nice visual interface for someone unused to how git works and you can see all of your repos from within GitKraken.
    a. Command line: Install git.
    b. GUI: Install GitKraken.
  2. Find the repo of the package you want to install. The atom.io/packages database links to the repos via the first button just below the package info. Let’s say for this example that you want to install pigments. You’d go to that page and follow the link to the repo.
  3. Clone the repo. From the GitHub repo, click on the green Clone or Download button. Click on the clipboard symbol to copy the URL.
    a. Command line: Execute cd "C:\Users\R&M\.atom\packages" and then git clone https://github.com/abe33/atom-pigments.git.
    b. GUI: ctrl-n or File -> Clone Repo to clone the repo, set the folder to C:\Users\R&M\.atom\packages and paste the URL into the lower box.
  4. Install dependencies. Not every package needs this, but most complex ones do. For this one, you need the command line. Execute cd "C:\Users\R&M\.atom\packages\pigments" and then apm install.
  • It’s possible to write a batch script and add it to the context menu, so if you want to do that, you can make a file that just says apm install, navigate to the directory in Windows Explorer, and right-click to access it.