Book a Demo

Author Topic: Relocating version controlled packages within EA  (Read 3764 times)

Matt Dawson

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Relocating version controlled packages within EA
« on: February 02, 2010, 11:17:33 am »
Hi All,

I'm currently running EA 7.5 (#849) and was hoping someone could help me work out how to relocate version controlled EA packages, preferably without losing the SVN log history in the process.  

My problem is that I have some package XML files in my working copy like so:
   %WC%\MyPackage.xml
and I now need them to be relocated like this:
   %WC%\MyWorkArea\MyPackage.xml
I've tried various ways to do this, but the part where I'm having issues is re-establishing the link between the package in the EA Browser and the XML (XMI) file in the working copy.  Every time it informs me I'm about to save over the relocated XML file when what I really want it to do is refresh the content from that location.  The user guide makes some reference to disconnecting/reconnecting the package but I didn't spot any explanation of how to reconnect the file.  I've also considered just exporting then importing the XMI but I'm sure this will lose the SVN log history so I'd rather keep this as a fallback position.

The SVN side is of the equation is under control.  I'm quite comfortable with using the TortoiseSVN's repo-browser, SVN Update, etc to relocate the xml package between sub-directories within the working copy/repository.  If anyone has suggestions on how to reconnect the package (in the EA Browser) to the relocated package in the SVN working copy I'd really appreciate it.

Thanks,
Matt

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Relocating version controlled packages within
« Reply #1 on: February 02, 2010, 06:05:14 pm »
Matt,

It's actually quite simple.
Go into the Version Control configuration and change the path of the config to include \MyWorkArea.
(alternatively you can just change the local path, or the paths.txt file in you profile.)

Geert

Matt Dawson

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Re: Relocating version controlled packages within
« Reply #2 on: February 02, 2010, 08:14:35 pm »
Hi Geert,

Thanks for helping out!

Quote
Matt,
Go into the Version Control configuration and change the path of the config to include \MyWorkArea.
(alternatively you can just change the local path, or the paths.txt file in you profile.)
If I understand this correctly, the suggestions will change the location where all XMI files are expected to reside.  Correct?

In the interests of simplifying the example I left out some details that seemed immaterial (obviously went a little bit too far there...).  I'm working one project within an enterprise repository and am expected to fit within certain conventions.  One of those is that I need to load one package from the root level of the repository, and my packages need to be added two or more directories below that.  To extend the earlier example it would look like this:
Current XMI layout in Working Copy:
      %WC%\EnterprisePackage.xml
      %WC%\MyPackage.xml
would need to change to this:
      %WC%\EnterprisePackage.xml
      %WC%\MyWorkArea\MyPackage.xml

As I understand it that would be a bit hard to implement using above, unless I use the PATH option and even that would be a little messy because anyone wanting to view the models I commit would need to have the same PC configuration as well.

So what I'm looking for is a way to access the whole contents of the current SVN working copy, while allowing certain packages within it to have their XMI files relocated via SVN file moves, and then reconnect the package in the project browser with the XMI file's new location within the SVN working copy.  Is this possible without exporting/importing?

Thanks,
Matt

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Relocating version controlled packages within
« Reply #3 on: February 02, 2010, 08:47:03 pm »
Matt,

That is indeed a bit more difficult.
What you could try is to create a new Version Control configuration that you use for the moved files, but I'm not sure how that will work out.
Another (dirty) option to to edit the file location directly in the database.
I think you should find the location in the t_package table somewhere.

Geert

Felix

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
    • View Profile
Re: Relocating version controlled packages within
« Reply #4 on: February 15, 2010, 11:56:45 pm »
Hi!

How do you edit the eap file directly?
I heard it is a database, so do you need something like MS Access for that?

Felix

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Relocating version controlled packages within
« Reply #5 on: February 16, 2010, 01:10:39 am »
A local eap file is nothing more then a renamed MS Access file.
You can edit it with MS Access or via an SQL tool that can connecto to access files (or odbc)

Geert