How to change MATLAB's sh.exe path?

10 次查看(过去 30 天)
Hello,
I am using a repo that has Git LFS installed and set to track .mat files. I when I try to compare a large .mat file to its ancestor or a previous revision using MATLAB's source control interface I get the following error.
"Error cannot run git-lfs smudge -- largeData.mat. Unable to locate sh.exe at C:\Program Files\Git\bin\sh.exe or on the system path.. Unable to locate sh.exe at C:\Program Files\Git\bin\sh.exe"
My sh.exe is installed at C:\Apps\Git\bin ...
I cant figure out how to tell MATLAB to look there instead. Any thoughts? I'd prefer not to have to touch my system environment variables as I'd need to get IT involved on my corporate machine.
Also just to know. This only happens when I run this in a repo with git lfs installed. I dont get the error when I try the same steps without git lfs.
You can reproduce this by generating a repo with git LFS installed on it and track the .mat files.

采纳的回答

DanielFromIllinois
DanielFromIllinois 2023-5-17
I ended up figuring out a solution to my own issue but it does require administrative permissions to do it. As I suspected.
The solution was to add the path to the installation of sh.exe system path.
If anyone finds a solution that doesnt involve changing your system path please post it!

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Source Control 的更多信息

产品


版本

R2022a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by