ls: Windows - ls -l does not play well with Linux style mounting or cross drive junctions
Open
Nobody has claimed this yet.
U - ls
wontfix
- Dominant language
- Rust
- Stars
- 24.1k
- Forks
- 2k
- Avg merge
- 1d 5h
- Merged PRs (30d)
- 365
Description
When using "Linux style mounting" for drives in windows instead as a letter drive (C: D: E:) mounting ls -l does not understand what to do. This also goes for junctions pointing to letter drives roots.
Administrator in B-Station in ~
PS > ls -l .\Programs\
---------- 1 somebody somegroup 0 Nov 18 2021 ''\''.\Programs\'\''' -> 'C:\Programs'
Administrator in B-Station in ~
PS > cd .\Programs\
Administrator in B-Station in ~\Programs
PS > ls -l
---------- 1 somebody somegroup 0 Nov 18 2021 . -> 'C:\Programs'
Administrator in B-Station in ~\Programs
PS > ls
.icon Bin Lib Src Startup SteamApps
Administrator in B-Station in ~\Programs
PS > cd /
Administrator in B-Station in C:
PS > ls -l C:\Programs\
---------- 1 somebody somegroup 0 Nov 18 2021 ''\''C:\Programs\'\''' -> 'Volume{172295dd-7000-4af9-9d24-d2b7d9445fe9}\'
Administrator in B-Station in C:
PS > cd .\Programs\
Administrator in B-Station in C:\Programs
PS > ls
.icon Bin Lib Src Startup SteamApps
Administrator in B-Station in C:\Programs
PS > ls -l
---------- 1 somebody somegroup 0 Nov 18 2021 . -> 'Volume{172295dd-7000-4af9-9d24-d2b7d9445fe9}\'
Administrator in B-Station in C:\Programs
PS > cd
Administrator in B-Station in ~
PS > ls -l .\Repositories\
---------- 1 somebody somegroup 0 Nov 18 2021 ''\''.\Repositories\'\''' -> 'D:\'
Administrator in B-Station in ~
PS > cd .\Repositories\
Administrator in B-Station in ~\Repositories
PS > ls
Arma3 BlackOrder OzilusOs SpaceEngineers dotfiles win-upgrade
Arma3Mission DiskImages PhoneRootProject Tools dotfiles.code-workspace
Arma3Resorces GameConsept Python arma3-scoop-bucket hoidev
ArmaRAddons HoI4 RimWorld arma3FixBinMake.reg jmonkeyengine
ArmaRResorces JS Rust armadev secure
Baurotrama Other ShadowMisc armake2 wdotfiles
Administrator in B-Station in ~\Repositories
PS > ls -l
---------- 1 somebody somegroup 0 Nov 18 2021 . -> 'D:\'
Administrator in B-Station in ~\Repositories
Screenshots of terminals below
"Linux style" mount point

Junction to letter drive

Setup
PS > pwsh
PowerShell 7.2.4
Copyright (c) Microsoft Corporation.
https://aka.ms/powershell
Type 'help' to get help.
PS > starship
starship 1.6.3
Starship Contributors
The cross-shell prompt for astronauts. ☄🌌️
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the reported ls -l output on Windows using a Linux-style drive mount and a junction targeting a drive root. Compare the displayed link targets with the paths returned by ls without -l; done means ls -l represents both mount points and cross-drive junctions without the shown malformed names or targets.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- cli, operating-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100