Description
This is a rewrite of #2 with some updates
Right now we only have the ability to clone into the same folder. But we want to be able to clone into a sub-folder if possible.
Extend the configuration for a repo to allow for the option clone-path: <folder-path>
for any repo we define
If this is set then we should attempt to clone the git repo into this folder. But there is two different cases here.
The first is that we might want to clone one git repo into the already cloned repo of another repo. So lets say we have the repo pykwalify/
that we already have cloned to disk. We want to clone another repo redis-py-cluster
into the folder path pykwalify/redis-cluster/
instead of the root folder we stand in. The problem here is that we must have some kind of dependency resolution where we must say what order repos should be processed in to allow for this as we can't create a random folder, clone redis-py-cluster
into it first, then clone and overwrite pykwalify/
on the same folder. Add ontop of this that our configuration file is a nested dict that do not guarantee or preserv insert order always so we can't guarantee that we will always process pykwalify before redis-py-cluster for instance.
If we go down dependency order lane, keep it as simple as possible, depnedencies must be defined where one repo "depends on" another repo, the tool will just re-order the execution order to fullfill the dependencies, then execute the commands in that order.
The second alternative we have is that we just ignore any dependencies and we hope that subgit just executes things in the correct order. This might cause issues and problems if we only let this to chanse. The upside is that this is way simpler to implement and we might just impelment the feature and add in dependency handling later on to move the tool forward.
Non-allowed characters or paths should be /../ anywhere in the path, working outside initialized folder shouldn't be allowed.
We also might need to sort out how we deal with moving an already exported folder if we move things around. This might mean that we need to implement state tracking of already done commands. This will need to be investigated further.