9 Replies Latest reply on Mar 16, 2013 4:35 PM by userc_43616

    Cloning a project


      PSoC Creator contains a mechanism for cloning the Example Projects, indeed it's the only way to open them really because they're write protected.




      But is there a way to clone one of my own projects?  I could just take a copy of the project folder, but then all of the files and folders have the same name. Ideally the cloning process would automatically rename all of the files and folders to match the name of the new project.




      Many thanks - Hugo

        • 1. Re: Cloning a project

          I would suggest you to use the "Create Workspace Bundle" feature which creates an archive of a project. This archive can be copied (expanded) into a new folder and then you may start renaming project, workspace, whatever you want.





          • 2. Re: Cloning a project

            This might be of use -








            Regards, Dana.

            • 3. Re: Cloning a project

               This is something I would think *everyone* would find a need for, namely a "save as" option, so you could incrementally build a project, get some of it working, save that as a new project, etc.  I found the following solution with a web search, and can report that it works "as advertised".  I made a little text file of the instructions, which I pop up as needed, but a "save as" option in V2.3(?) would sure be much appreciated!  Note that going the "archive" route is NOT the same thing!




              Here are the steps, as reported by jomalogil on Sat Feb 05, 2011 3:57 am

              a) open the workspace where is the original project
              b) right click over project and select copy.
              c) close workspace (File menu)
              d) open (create) a new project, but select Others-> empty workspace
              e) write the name of the "clone" project
              f) right click over workspace and select paste.
              g) rename the project.
              h) select different PN if necessary

              • 4. Re: Cloning a project

                I always use a different way to "clone" a project.


                As suggested in the link Dana supplied I use "Create Workspace bundle", choosing the minimal zipped version. Then I expand the archive into a new folder and rename workspace / project if required. Even when changing the computer where Creator runs on I do not get any errors.





                • 5. Re: Cloning a project

                  I agree that a "Save as..." menu choice should be added. Such a file maintenance option is standard on practically every piece of PC and Mac software that deals with files.



                  • 6. Re: Cloning a project



                    I'using PSoC 4.0 Update 1 (  (12/20/2016).


                    My problem when doing "Create Workspace Bundle.." is that the created Zip file does not include all *.c and *.h source files I have in the original project.


                    I have an old project that was made in Creator 3.0. Then I updated Creator to 4.0 release, so I've created a new empty project in Creator 4.0. Next, I've copied some source files from old browse project to new browse project and I've done "Add>Existing Item..." for including them to new project in Creator 4.0. After that I create some new source files to complet the my project. Compile and all is right.


                    Now I want to clone my project so I do "Create Workspace Bundle.." in my creator 4.0 project, and select "Complete". When I open the Zip generated file I can see some source files don't exist. I've noticed that files added as existing they aren't appear but files Added as new do. Which is the reason ? 





                    • 7. Re: Cloning a project

                      Did you try the option "Bundle"





                      • 8. Re: Cloning a project

                        Yes. With Bundle they are included but not in the same folder that they was in the original project.


                        They must be all of them in "..\project_name.cydsn" folder but if we see at zip file they are alocated out of cydsn folder with project_name.cywrk file. In the other hand the new source files, that were added as new in Creator 4.0 project, appears correctly in cydsn folder.


                        It really is not a problem because I copy the files to the correct site and fixed, but at least I find it strange and generates mistrust when it comes to backing up projects.



                        • 9. Re: Cloning a project

                          Finally, I opt for creating all source files as new en PSoC creator 4 and copy source text from old files to new ones. This way all source files are included in zip bundle file into their folders.