Azzera filtri
Azzera filtri

How can i run the bash shell script in matlab

84 visualizzazioni (ultimi 30 giorni)
Farik John
Farik John il 29 Gen 2016
Risposto: DanielFromIllinois il 14 Mar 2022
I have the bash file in where there is something like below.
wget \
--output-document=data/imagenet-vgg-verydeep-16.mat --continue
How can i run this script file?

Risposte (2)

Geoff Hayes
Geoff Hayes il 29 Gen 2016
  6 Commenti
Farik John
Farik John il 2 Feb 2016
Thanks Geoff and Walter. I managed to find the right command to run it as below. system('c:\cygwin64\bin\bash "d:\MyProject\"');
Hi @Farik John, I'm trying to run shell script from matlab in windows. When I use system('D:\MyProject\'); command, it is directing to the shell script file in notepad++ rather than running the commands.
I tried using "system('c:\cygwin64\bin\bash "d:\MyProject\"');" but this is throwing error saying "Not a directory". Please let me know how can we run shell script from matlab.
I value your input. Thanks in advance.

Accedi per commentare.

DanielFromIllinois il 14 Mar 2022
If you're running this from Windows (not mac or linux) I got this to work by doing:
The above assumes that is in your current directory within MATLAB. You could provide an absolute path like:
system('C:\Apps\Git\git-bash.exe C:\Users\UserName\home\scripts\')


Scopri di più su Introduction to Installation and Licensing in Help Center e File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by