[pulsar-next] `pulsar-next` command on Windows doesn't set the right `ATOM_HOME`
Thanks in advance for your bug report!
- [x] Have you reproduced issue in safe mode?
- [x] Have you used the debugging guide to try to resolve the issue?
- [x] Have you checked our FAQs to make sure your question isn't answered there?
- [x] Have you checked to make sure your issue does not already exist?
- [x] Have you checked you are on the latest release of Pulsar?
What happened?
Not sure why yet, but (after a recent bug fix that prevented the app from launching at all) running pulsar-next doesn't set ATOM_HOME correctly.
The idea is that ATOM_HOME should be resolved first by explicit environment variable (so the user can override it), then by defaulting to the home directory on a particular OS plus either pulsar or pulsar-next, depending on the release channel. So either a variable isn't getting set by pulsar-next.cmd or it's not getting properly inherited by the shell.
By contrast, launching PulsarNext from the GUI seems to set the correct ATOM_HOME.
Pulsar version
PulsarNext 1.124.0
Which OS does this happen on?
🪟 Windows
OS details
(any)
Which CPU architecture are you running this on?
None
What steps are needed to reproduce this?
- Manually set the correct
PATHentry forpulsar-next[installation-location]\resources - Open a new shell
- Run
pulsar-next - Check your
ATOM_HOMEvia one of several approaches:atom.configDirPathin a dev tools console, or open Settings and then click on the “Open Config Folder” button in the sidebar - Observe how it's pointing to your
.pulsarfolder instead of your.pulsar-nextfolder
Additional Information:
No response
Looking back through my commits on the PulsarNext branch, I see that https://github.com/pulsar-edit/pulsar/commit/d9ef212837192666f6400eba2b06c144fc08f559 was supposed to simplify all of this by using the version number as the source of truth: on PulsarNext builds it should end in -next, and that should trigger the logic that chooses .pulsar-next instead of .pulsar for ATOM_HOME.
So either this logic is somehow not “sticking” on Windows, or (more likely, IMO) some other piece of machinery is setting a default ATOM_HOME on Windows before this code acts (which would explain why overriding ATOM_HOME still works fine).