6 years, 10 months ago.

Problems with committing code

Background info:

I've written code with the intention of using it as a library, but it started out with a main function that I would use for testing purposes. Every time I tried to import the "library" into another program, it would get compiler errors because of the duplicate main.cpp and mbed folder. If I delete those files from the client application program, everything would run fine.

I initially couldn't find anything related to converting my program to a library, so I went back and forth between deleting main.cpp in my project, or converting the mbed source from a folder to a library, and nothing seemed to work. I then found that I just have to right click on the project and select New Library to convert my program into a library that other applications can use. However, before doing that I wanted to commit my changes.

When I click publish, it tells me:

"To commit in this program, you need to commit any changes in library "ModbusServer"

If I click Commit, then it asks me for revision notes, which I enter. When I click OK, it tells me:

"There is nothing to commit. No files have been changed in the repository."

I know this is wrong because if I look at Revisions, the changelist shows that main.cpp was added back in, and ModbusServer.lib and mbed.lib were added back in.

If I try to Publish again and tell it to Discard changes to ModbusServer, I end up in an endless loop where I can keep clicking Discard and OK over and over again.

Does anyone have any suggestions for how to solve this problem?

I would go offline (clone the repo), do changes there. Before doing that, create a repo and share a link with us, might help web team to reproduce your issue and possibly fix it.

posted by Martin Kojtal 15 Sep 2014

Thanks, Martin. I'll do that should the problem resurface. I did find that I had a user error and failed to move source files into the newly-created "library" folder, but once I did that everything committed fine. It doesn't explain the fact that re-adding main.cpp wasn't considered a change, but for the time being, everything is working.

posted by Dave M 15 Sep 2014

1 Answer

4 years, 3 months ago.

Hi, I have the same problem, did anyone found a solution ? Cécile