1 Star 0 Fork 226

飘逸者/bookjs-eazy

forked from nop/bookjs-eazy 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
wslpath.bat 751 Bytes
一键复制 编辑 原始数据 按行查看 历史
nop 提交于 2022-04-18 23:25 . init
:: 取个怪异的名字加"__",尽量不干扰全局的变量
:: 使用方式: call wslpath.bat [WINDOW路径] [保存的变量名]
:: call wslpath.bat . MOUNT_PATH
:: call wslpath.bat "C:\Program Files\Docker" MOUNT_PATH
::
:: MIT License
:: @https://gitee.com/wuxue107/wslpath.bat
::
:: SETLOCAL
set __SET_PARAM_NAME=%2
set __FULL_PATH=%~f1
set __FILE_PATH=%__FULL_PATH:~2%
set __FILE_PATH=%__FILE_PATH:\=/%
set __DEVICE_NAME=%~d1
set __DEVICE_NAME=%__DEVICE_NAME::=%
for %%i in (a b c d e f g h i j k l m n o p q r s t u v w x y z) do call set __DEVICE_NAME=%%__DEVICE_NAME:%%i=%%i%%
:: ENDLOCAL
if "%__SET_PARAM_NAME%" == "" (
echo /%__DEVICE_NAME%%__FILE_PATH%
) else (
set %__SET_PARAM_NAME%=/%__DEVICE_NAME%%__FILE_PATH%
)
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/piaoyizhe666666/bookjs-eazy.git
git@gitee.com:piaoyizhe666666/bookjs-eazy.git
piaoyizhe666666
bookjs-eazy
bookjs-eazy
master

搜索帮助

0d507c66 1850385 C8b1a773 1850385