How to duplicate a current project?

How to duplicate a current project?

211
Basic UserBasic User
211

    Feb 09, 2018#1

    One of my project files in UE 24.20.0.51 has grown too big for me. I want to break some of the open file tabs into a different project. Is there some way to do this easily in UE?

    My initial though was to find the project file, make a copy and give it a new project name. Then I can open the existing project, close the tabs I don't want open in that project, then open the copy of the project and close the tabs that are still open in the original.

    6,688587
    Grand MasterGrand Master
    6,688587

      Feb 09, 2018#2

      Your idea is very good.

      A project consists of two parts: a *.prj file containing the project settings and the *.pui file with the project user interface data, i.e. which files are currently opened, with which window dimensions, positions, caret positions, foldings, bookmarks, ... So you have to make a copy of both files with new name to duplicate the project.

      The directory containing the *.prj file should be well known by you. Depending on GUI mode the fully qualified file name is shown for example in menu Project, as tooltip on having mouse pointer positioned over project name in File View - Project, or as tooltip with mouse pointer positioned over file tab of project file on having opened the *.prj file itself which can be done by right clicking on project name in File View - Project and clicking in context menu on Edit Project File.

      The directory containing the *.pui file depends on the settings Save project information for use on multiple systems and Store project user interface (pui) files in profile directory at Advanced - Settings or Configuration - File handling - Advanced. Click on button Help after having opened this configuration dialog. The *.pui can be stored in:
      1. directory containing also the *.pui with same name as project file with just different file extension,
      2. directory containing also the *.pui with file name ProjectName.ComputerName.UserName.pui,
      3. directory %APPDATA%\IDMComp\UltraEdit\PUI with file name GUID.ProjectName.pui.
      Best regards from an UC/UE/UES for Windows user from Austria

      211
      Basic UserBasic User
      211

        Feb 09, 2018#3

        Thanks Mofi, but I just discovered an easy way to do this.

        I had that big project open and then created a new project. I clicked on "+ All open files". I then closed all the tabs I didn't need in that second project and closed it. Opened the original project again and closed the tabs that are now in the new project. Bingo! I now have that one big project broken down into two smaller projects, while keeping the name of the original project.

        6,688587
        Grand MasterGrand Master
        6,688587

          Feb 10, 2018#4

          Oh, I understand now. You are not using projects. You are using just pure workspaces. So the Project Settings dialog shows no folder, group or file. Yes, in this case the duplicate method used by you was definitely easier.
          Best regards from an UC/UE/UES for Windows user from Austria

          211
          Basic UserBasic User
          211

            Feb 12, 2018#5

            Hey Mofi - Just curious about your statement "You are not using projects.". Is not a project just a collection of tabs/open files? What am I missing here?

            6,688587
            Grand MasterGrand Master
            6,688587

              What is the difference between a project and a workspace?

              Feb 12, 2018#6

              A collection of tabs/open files is a workspace, i.e. only the *.pui file is really used and the *.prj file does not contain relevant data.

              A project is more than a workspace. A project consists of one or more folders with specific filters or groups with manually added files or at least some files as defined in Project Settings dialog. See also forum topic How to create project from an existing directory tree?

              The Find in files and Replace in files feature have the item Project files which searches/replaces in all files of a project independent on being currently opened or not. On right clicking into Function List view and left clicking on List for all project files UltraEdit searches all files of a project for function strings and display them all in function list instead of just the functions in active file.

              The tab Project on File View lists all project files as defined in Project Settings dialog independent on being opened or not. The tab Open shows just the opened files. The context menu on right clicking on an item on tab Project on File View has several commands depending on which item was clicked, the project name at top, or a project folder, or a project group, or a project file.

              On using a project with project folders/groups and files it is possible to use the Ctag feature which searches in all project files for symbols (classes, functions, macros, variables, type definitions, structures, ...) and creates a symbol database for the project which is used on having caret set on a symbol like a function and execute (by hotkey in my configuration) now the command Find symbol to jump to the line containing the definition of this function even if being in a different file not yet opened. UltraEdit opens in this case the other project file and sets caret to line of the symbol (function, macro, ...) definition. This is a feature I really don't want to miss on working with projects. The jump back to initial position is done with the command Go to previous position (executed by hotkey).

              In Project Settings dialog it is also possible to configure a project specific template file which contains the definition of smart templates for fast inserting them in a project file. That feature makes code writing much more efficient on having such a template file once defined for a project.

              In Project Settings dialog it is also possible to specify a wordfile used instead of the standard wordfiles. This feature is useful for me as I write code for different firmwares for different controllers and processors. So I do not have only a general C/C++ wordfile, but also controller/processor/compiler specific C/C++ wordfiles used for the various projects.

              And there are even more project related features which I do not want to explain here all.

              I must add that I'm using nowadays mainly UEStudio for projects as it has even more project related features than UltraEdit. But I have still some old projects setup before UEStudio was released the first time which I have never migrated to UEStudio and on which I still work from time to time with UltraEdit when it is necessary to make a code change in the old firmwares managed with this old projects.

              I use projects for C/C++ (embedded firmwares and Windows GUI/console applications) and websites (HTML, CSS, JavaScript).

              So a project is really much more than a workspace.
              Best regards from an UC/UE/UES for Windows user from Austria

              211
              Basic UserBasic User
              211

                Re: What is the difference between a project and a workspace?

                Feb 14, 2018#7

                Thanks for all the detail info Mofi. Been reading up on projects and see that I haven't even scratched the surface.