Last active
June 15, 2022 08:46
-
-
Save ha7ilm/afeeddb8b639e0cfbb5ee1076b0a0fb5 to your computer and use it in GitHub Desktop.
How to get the absolute path of the root directory of the current git repo in MATLAB
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[~,gcr]=system("git rev-parse --show-toplevel"); gcr=strsplit(gcr,newline); gcr=[gcr{1} filesep]; %root of repo |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment