Author Topic: Why are there duplicate files in the .vpj file?  (Read 1786 times)

timur

  • Senior Community Member
  • Posts: 204
  • Hero Points: 3
Why are there duplicate files in the .vpj file?
« on: September 26, 2019, 05:13:49 PM »
Hundreds of files in my projects are duplicated.  For example:

         <F N="../sw/dev/gpu_drv/chips_a/pmu_sw/prod_app/boardobj/nv/boardobj.c"/>
         <F N="../sw/dev/gpu_drv/chips_a/pmu_sw/prod_app/boardobj/nv/boardobj.c"/>
         <F N="../sw/dev/gpu_drv/chips_a/pmu_sw/prod_app/boardobj/nv/boardobj_interface.c"/>
         <F N="../sw/dev/gpu_drv/chips_a/pmu_sw/prod_app/boardobj/nv/boardobj_interface.c"/>
         <F N="../sw/dev/gpu_drv/chips_a/pmu_sw/prod_app/boardobj/nv/boardobj_vtable.c"/>
         <F N="../sw/dev/gpu_drv/chips_a/pmu_sw/prod_app/boardobj/nv/boardobj_vtable.c"/>

How did this happen, and how can I fix it?

Lee

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1299
  • Hero Points: 130
Re: Why are there duplicate files in the .vpj file?
« Reply #1 on: September 26, 2019, 05:21:19 PM »
It's not supposed to happen, but I do recall a release where that did happen due to a bug that was introduced.  That was several versions ago, and was patched in a later release.   It depends when and how the project was created.  I don't think there is anything built-in to handle existing dupes, but I can check. If I recall, I may have had a custom macro somewhere that helped out customers that had this issue.

UPDATE: From 2016, check this message, I did write a custom macro to assist with duplicates caused in error: https://community.slickedit.com/index.php/topic,12164.msg52519.html#msg52519
« Last Edit: September 26, 2019, 05:29:58 PM by Lee »

timur

  • Senior Community Member
  • Posts: 204
  • Hero Points: 3
Re: Why are there duplicate files in the .vpj file?
« Reply #2 on: September 26, 2019, 06:24:47 PM »
I'm using SlickEdit Pro 2018 (v23.0.1.0 64-bit), so it should not happen to me.

Lee

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 1299
  • Hero Points: 130
Re: Why are there duplicate files in the .vpj file?
« Reply #3 on: September 26, 2019, 06:30:40 PM »
When was the project created? Can you determine if it happened during creation or during a modification, if the file was in a source control you may be able to determine from history.  Also what platform are you running on?

timur

  • Senior Community Member
  • Posts: 204
  • Hero Points: 3
Re: Why are there duplicate files in the .vpj file?
« Reply #4 on: September 26, 2019, 06:42:14 PM »
It's not a new project, so it's gone through some revisions (files added and deleted).  I can't say how the problem occurred.  However, I do believe that Slickedit should automatically remove duplicates whenever it updates the project file.

This is on Linux.  I use this shell command to clean it up:

Code: [Select]
cat project.vpj | uniq | sponge project.vpj