irondash / cargokit

Integrate cargo build with flutter plugins and applications.
Other
61 stars 19 forks source link

fix: add `/D` argument for cd to trigger drive change when changing directory #53

Closed holyslon closed 10 months ago

holyslon commented 10 months ago

When gradle plugin runs run_build_tool.cmd it passes to script env variable %CARGOKIT_TOOL_TEMP_DIR%. Then script make cd to dir that passed inside this variable. But if this variable points to directory that located on different drive than working directory for script, cd will not work. For it to work we need to pass /D parameter to cd. I made this change localy and it helps. Right now line 11 in local my script looks like:

cd /D "%CARGOKIT_TOOL_TEMP_DIR%"

and it works.

This is PR that fix this issue.

PS: my inital issue