Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow working on models based on repositories having the same name #104

Open
samperd opened this issue May 31, 2019 · 6 comments
Open

Allow working on models based on repositories having the same name #104

samperd opened this issue May 31, 2019 · 6 comments
Assignees

Comments

@samperd
Copy link

samperd commented May 31, 2019

User Story

As an Archi User
I want to import multiple forks of a repository into an Archi Collaboration workspace
So that I can make edits to one fork, while monitoring and managing another fork

Current issue

If I fork a base repo (eg https://github.com/canada-ca/architecture/network/members) to my own user space (eg https://github.com/samperd/architecture) then I can not import both of these into my workspace because the following directory is found to be non-empty

C:\Users\USERNAME\AppData\Roaming\Archi4\model-repository\architecture

Implementation details

  • Could we just change the auto-naming convention for directories to add one more layer.
  • currently it looks like the following format is used

C:\Users\USERNAME\AppData\Roaming\Archi4\model-repository\REPOSITORY

  • I propose that we add a USER/GROUP level in there

C:\Users\USERNAME\AppData\Roaming\Archi4\model-repository\USER-OR-GROUP\REPOSITORY

This should mean that multiple forks will not collide

@Phillipus Phillipus transferred this issue from archimatetool/archi May 31, 2019
@jbsarrodie
Copy link
Member

@Phillipus I have the same issue/request for two reasons:

  • in some occasion I want to import the same repository twice from two different servers
  • in some occasion, I might want to import two different repositories which unfortunately have the same name

My suggestion would be to simply use a UUID for the local folder name, this would be an easy solution to avoid "name collision" (and this folder name never appears in UI as the real model name is used instead).

@Phillipus
Copy link
Member

Will investigate options in the next coArchi coDing sprint.

@Phillipus Phillipus self-assigned this Nov 12, 2019
@jbsarrodie
Copy link
Member

BTW, It would be good to allow users to create folders and move local repositories in them when needed. It used to be possible in the early (POC) version of coArchi but has been remove after.

This would allow users to better organize their local list of clones (I know some people who have more than 50 local models in their workspace).

@Phillipus
Copy link
Member

We need the organisation that we have in jArchi.

@jbsarrodie
Copy link
Member

We need the organisation that we have in jArchi.

Yes, except that the model/git repository itself cannot be renammed

@jbsarrodie
Copy link
Member

I'm copying what I wrote on #133 which duplicate this issue

When importing a remote model to the workspace while the target folder already exists, we get this kind of "Folder is not empty" error:
image

I think we should manage this in a more user friendly way.

I can see two strategies:

  1. Keep current behavior but use the FQDN or the repo instead of only the repo name. This would lead to more unique folder name and would solve the root cause.
  2. Change the behavior so that when this error is raised, we ask the user if he/she wants to cancel or continue. If he/she wants to continue, then we add some randow text at the end of the folder name to be created.

The first option seems easier to manage, but the second has the advantage to allow someone to import a model more than once. Of course this should not be done unless you have a very specific need (TBH, the only use-case I see is us trying to simulate several people working on the same model, but for this I usually manually change the folder name anyway).

@jbsarrodie jbsarrodie changed the title Add multiple forks of repositories to workspace Allow working on models based on repositories having the same name Apr 1, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants