Mklink - Cmd
If you want a link that works even if the entire folder is moved, create a relative path target. Example from inside C:\Projects\MyApp :
Have os.unlink remove junction points · Issue #62514 - GitHub
Specifically for linking directories, often used to bridge local folders. Common Use Cases cmd mklink
mklink /D "current_version" "..\Versions\v2.0"
An older type of directory link. Works only on local drives (no network). Faster than symlinks for some operations? In practice, junctions are very similar to /D symlinks, but older apps understand them better. Use /J for drive redirection (e.g., moving C:\Users ). If you want a link that works even
| If you want to... | Use this | |------------------|----------| | Make a file appear in two places without extra storage (same drive) | Hard Link ( /H ) | | Make a folder appear in another location (any local drive) | Junction ( /J ) or Symlink ( /D ) | | Make a folder appear across network drives | Symlink ( /D ) | | Make a file appear across drives or network | Symlink (no flag) | | Save space by moving large folders to another drive but keep path | Junction | | Create a link that survives original file deletion (hard link) | Hard Link | | Create a shortcut that apps cannot ignore | Any symlink or junction |
To map a configuration file from a desktop backup to your user directory, you would run: Works only on local drives (no network)
Junction points are similar to symbolic links but are limited to directories. They are more like hard links for directories. To create a junction point, use the /j option:
```cmd mklink /d C:\path\to\linkdir C:\path\to\targetdir
Any file saved into C:\MyGames\config.ini actually goes to E:\SteamLibrary\... .