Open dafeder opened 2 years ago
Because of the way ddev delights in demolishing your project directory if you say ddev composer create
(which we do), I can either figure out how and what to backup before we do this, or we can just warn the user and abort if there's anything in the directory that might get destroyed.
Let's postpone here and work on https://github.com/GetDKAN/dkan-ddev-addon/issues/9 instead, which addresses the issue of not demolishing anything during dkan-init.
After that we can swing back through this issue and ensure that we can specify a branch for moduledev.
Un-postponing in support of WCMS-11097
https://github.com/GetDKAN/dkan-ddev-addon/blob/e092657465b1752103d66bc91dbb49590718e58a/commands/host/dkan-init#L47
Check if /dkan already exists. If it does, don't run git clone.
Also, we should detect the version constraint from the git repo. See
https://github.com/GetDKAN/dkan-tools/blob/master/src/Command/InitCommands.php#L243
for how this was done in dkan-tools