V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
V2EX  ›  fuweichin  ›  全部回复第 2 页 / 共 2 页
回复总数  21
1  2  
2020-06-01 01:35:07 +08:00
回复了 yulihao 创建的主题 程序员 意外发现个 Windows 访问 WSL 下文件的方法
楼主是否考虑修改文章内容?继续下去可能会误导一些人。

这方法不靠谱,之前在 Windows 这边用 Noptepad 改了配置文件,Linux 那边不认,还得用 nano 再改一遍。

微软开发者明确标红:
DO NOT, under ANY circumstances, access, create, and/or modify Linux files inside of your `%LOCALAPPDATA%` folder using Windows apps, tools, scripts, consoles, etc.
详见 https://devblogs.microsoft.com/commandline/do-not-change-linux-files-using-windows-apps-and-tools/

正确的姿势:
升级到 Windows 10 version 1903 或更新版本
在 WSL bash 中,运行`explorer.exe .`打开资源管理器,来访问 WSL 中的文件,文件路径如\$wsl\Ubuntu\etc\nginx\nginx.conf (暂不支持符号链接,已经反馈提议支持符号链接)
1  2  
关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   2391 人在线   最高记录 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 12ms · UTC 14:55 · PVG 22:55 · LAX 07:55 · JFK 10:55
Developed with CodeLauncher
♥ Do have faith in what you're doing.