Author Topic: Workspace file restore issue  (Read 253 times)

Dennis

  • Senior Community Member
  • Posts: 3983
  • Hero Points: 517
Workspace file restore issue
« on: June 28, 2024, 04:42:18 PM »
I had to move a workspace / project file to a different location.  I manually updated the paths in the project file.

However, when I opened the workspace, it tried to re-open the files from file history, whose paths were wrong.  For each file that failed to open, it opened an extra instance of a file that did not move.  See the document tabs to understand what I mean.


Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 6919
  • Hero Points: 531
Re: Workspace file restore issue
« Reply #1 on: June 28, 2024, 10:51:45 PM »
I wasn't able to reproduce this.

As a test, I opened the "Sample Workspaces">cpp  workspace. Manually opened the cpp.cpp source file so it got put in the File History. Closed the workspace. Copied "ucpp" directory to "ucpp2". Then opened the new ucpp2/cpp.vpw sample workspace and the File History and Workspace Auto Restore both relocated the files and only one file was opened with Workspace Auto Restore. I'm not sure why this was wonky for you.

Dennis

  • Senior Community Member
  • Posts: 3983
  • Hero Points: 517
Re: Workspace file restore issue
« Reply #2 on: July 01, 2024, 12:51:26 PM »
Code: [Select]
HOME >
    projectFiles >
       proj.vpj, proj.vpw
    SourceFiles >
        a.cpp, b.cpp, c.cpp, d.cpp

Open all four files and /usr/include/stdio.h.  Close the editor.  Rename "SourceFiles" to "SrcFiles".  Then reopen.

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 6919
  • Hero Points: 531
Re: Workspace file restore issue
« Reply #3 on: July 01, 2024, 02:47:23 PM »
I'm not surprised this fails. The relative location of the source files changed. Commands to clear file history and close open files for files that don't exist would be handy.

Dennis

  • Senior Community Member
  • Posts: 3983
  • Hero Points: 517
Re: Workspace file restore issue
« Reply #4 on: July 02, 2024, 04:38:32 PM »
To be clear.  I don't expect the files to be magically re-opened, just fail out cleaner instead of opening 5 tabs with stdio.h