Atom ignoring junctions (file system links)


#1

Hey guys,

short:
Here is a video of the issue, note that I add the project folder from P:… but Atom “thinks” the file is on E:…

Long:
I am forced to work in the following path:

P:\IFA3\Path\ MyStuff

for my tools to work properly. But all of my content is actually on

E:\WorkSpace\Project\ MyStuff

So I used a symlink creator to create a junction at P:\IFA3\Path that links to MyStuff that is on E. Unfortunately Atom “sees through” my little trick and shows my buffer’s path as E:… instead of P:…

I am adding content/project folders to Atom from the P: location though.

Now I NEED Atom to “think” that I am on my P drive, otherwise the tools that I launch via process-palette get the wrong directory path.

Is there a way to FORCE Atom to see Junctions “properly”?


#2

Are you opening Atom or adding the project path via the P: drive? Or the E: drive? If you need Atom to think that stuff is on your P: drive, then you should be opening the project path there.


#3

Thanks for the tip.

Does not work.

This is what happens:


#4

Noone has any clue? :frowning2: I think the video example shows the problem really well.


#5

It seems Atom resolve the link to the final destination.
As far as I know there’s no switch to alter this behavior.

Now I NEED Atom to “think” that I am on my P drive, otherwise the tools that I launch via process-palette get the wrong directory path.

As for now I believe finding another way to launch those tools may be the easiest way out. Maybe try to make a batch file that translate to correct path, and launch this batch file from command palette ?


#6

That’s too bad, I am horrible with batches/programming in general.

Thanks anyway. :slight_smile:


#7

Here’s one tidbit:

Create a batchfile with that content:

  notepad d:/%~nx1

Then suppose you call

test.bat e:/file.txt

It’ll still execute

  notepad d:/file.txt

Why ?

  • %1 is the first argument
  • %~nx1 tell to interpret %1 as a path(~) but keeping only file name(n) and extension (x)

Once you have stripped out the original path you can setup the new one as you wish