I run into a problem with Go when trying to tell difference between windows symbolic links and directories. I've googled and all I could find was this: https://github.com/golang/go/issues/3498#issuecomment-142810957
Which is unfortunately closed and not being worked on.
So my question is, is there any workaround? I tried to listdir the path with the symlinks but it is returning the same that it would return on an empty directory.
With python I was able to do something like this:
def test(dir):
try:
os.chdir(dir)
except Exception as e:
if "[Error 2]" in str(e):
return False
else:
return True
Is there any bash command I could use to call from go to detect it?
I'm running out of ideas :(