-
Notifications
You must be signed in to change notification settings - Fork 45
Description
As a IDEasy user, I want to be able to push out a new (required) repositories to my teams with a simple push to my settings git repo so that everybody in my team can automatically get this new repositories cloned.
Further, I still want developers to have freedom and flexibility, so if for whatever reason they think that they do not need a specific repository, they are not fooled by IDEasy that recreates and clones the same repo after the user deleted it.
Therefore, we plan to introduce to track the repository status in local file(s) (e.g. $IDE_HOME/.repository/«repository») so we know that we have done our job of cloning the according repository on behalf of $IDE_HOME/settings/repositories/«repository».properties.
This way IDEasy can check after ide update if a $IDE_HOME/settings/repositories/«repository».properties exists with active=true that does not have a corresponding $IDE_HOME/.repository/«repository». In such case, the repository will be cloned on behalf of ide update.
Now after that the user could decide to remove $IDE_HOME/workspaces/«workspace»/«repository» manually and ide update will know that is was already cloned before so it will not re-create it.
It needs to be clarified if ide create «project-name» --skip-repositories ... will automatically mark all active repositories as "cloned" even though they are not. I would currently vote against it but this should still be discussed. Also we should consider supporting ide update --skip-repositories.
Instead of individual status files we also might maintain just a single status file $IDE_HOME/.repositories.json instead.
In both cases, we should track the timestamp when the repository was cloned and also in case of an error from git clone also the error message.
But in case of an error, we need to check if git actually created the repository at all.
If the error was e.g. that the user did not have permission to clone or was unauthenticated and failed 3 times to properly enter his password, we should most probably not consider the repository to be cloned at all in our status so it will be retried in the next ide update command.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status