MATLAB running old versions of .m files even after pulling from GitHub (2018a)

6 ビュー (過去 30 日間)
Serena Ghantous Lotreck
Serena Ghantous Lotreck 2020 年 2 月 21 日
回答済み: Sai Bhargav Avula 2020 年 3 月 26 日
I'm running MATLAB on a remote server. I want to eventually be able to run my main .m script on the command line without having to use interactive mode; however, I'm currenlty having this problem both interactively and non-interactively.
I originally wrote this code on my local machine, pushed it to my GitHub remote repository, and cloned that repo onto my remote server. I originally had a bug in one of my functions, and had forgotten a ; in another, so was getting a print out I didn't want (both of these functions are in separate .m files). However, when I fixed (and tested, they are fixed) these issues locally, pushed, and then pulled on the remote server, the files in my repo are updated (have checked in vim and in MATLAB interactive mode), but the code still prints out what I don't want it to print out, and throws the same error. If I try pulling again, I get the message that everything is up-to-date (and it is, from what I can tell).
What on earth is happening and how can I fix it??
  1 件のコメント
Walter Roberson
Walter Roberson 2020 年 2 月 21 日
I suggest using which() to track down the file matlab is using.

サインインしてコメントする。

回答 (1 件)

Sai Bhargav Avula
Sai Bhargav Avula 2020 年 3 月 26 日
Hi,
Adding to Mr. Walter, you can also compare the codes and check if it is actually pushed to the repo. And check for the green dot next to the file in the current folder window(in your local machine where you wrote the changes) it means it is update with the repo if it is a blue square it means you didn't push the files to the repo.
Hope this helps!

カテゴリ

Help Center および File ExchangeEnvironment and Settings についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by