example:
ln -s /path /temp/path
会在 temp 下生成一个空白文件
怎么才能正常链接文件夹呢?
1
zeroDev Oct 1, 2018 via Android
ln -s /path /temp/path/
|
3
zeroDev Oct 1, 2018 via Android
你少了一个 /
|
5
zzj0311 Oct 1, 2018 via Android
权限不足的情况下就是空文件,比如在桌面创建软链~
|
7
ysc3839 Oct 1, 2018 via Android @where2go Win10 Creators Update 开始,开启了开发者模式后不需要管理员权限了。
https://blogs.windows.com/buildingapps/2016/12/02/symlinks-windows-10/ 至于最初为什么这么设计,我不知道。 |
9
dot2017 Oct 1, 2018
path is a file
|
10
where2go Oct 1, 2018
|
12
ysc3839 Oct 1, 2018 via Android
|
16
where2go Oct 1, 2018
|
17
liangzi Oct 1, 2018
试了一下我机器正常
``` ln -s /source/path/file /path/ . ln -s /source/path/file /path/rename ``` []( https://i.loli.net/2018/10/01/5bb2094d76f53.png) []( https://i.loli.net/2018/10/01/5bb2094d7afc4.png) |
19
ysc3839 Oct 1, 2018 via Android
@where2go 有可能是需要在代码中开启这个权限的。参见 SeManageVolume 以及 SetFileValidData。
|
20
leafiy OP @liangzi 以前是这样的,今天重装了 win10 就做不到了,不知是什么设置原因? win 侧 admin 和 user,wsl 侧 root 和 user 都试过了
|
22
6IbA2bj5ip3tK49j Oct 1, 2018 via iPhone 退 wsl 保平安,你永远不知道下一个坑在哪儿。
|
23
msg7086 Oct 2, 2018 @where2go #6
From Microsoft TechNet: Security Policy Settings New for Windows Vista: Symbolic links (symlinks) can expose security vulnerabilities in applications that aren't designed to handle symbolic links. Windows 7 才有的符号链接(其实是 Vista ),所以为以前操作系统设计的程序在遇到符号连接的时候可能会出现行为异常(例如将敏感数据写入原本不会写入的区域中)。 |