Visual Studio ignores *.jfm entry in the gitIgnore file

Viewed 6070

I'm having a problem with Visual Studio 2013 locking a .jfm file. I am unable to save project changes to the local git repository when the project is open.

The error looks like this when clicking on the Commit button in the Team Explorer -> Changes panel:

"An error occurred. Detailed message: Could not open 'C:/Uers/Username/Documents/Visual Studio 2013/Projects/ProjectName/ProjectNameSQL/ProjectNameSQL.jfm': The process cannot access the file because it is being used by another process."

For example, when I make a change to the default.aspx in the project and look for changes in the Changes panel, only the default.aspx.designer.vb and default.asp.vb files show that changes have been made. only after closing the solution do I see a third file, default.aspx, appear in the Included Changes list of files.

I have already added .jfm to .gitignore and cleared the cache as noted in a previous solution described in this thread.

I am using the visualstudio.com git repository to sync changes and have manually edited the .gitignore file there as well.

How would I fix this error?

2 Answers

I fixed this by

  • Add *.jfm as a line to the local .gitignore
  • Close the solution (but stay connected in Team Explorer)
  • Delete the .jfm file in file explorer
  • Commit the .jfm deletion and the .gitignore edit
  • Reopen the solution and rebuild
  • Should see that there are no .jfm changes
Related