Skip to content
Snippets Groups Projects
Commit 6b939f9b authored by jurgenhaas's avatar jurgenhaas
Browse files

Move the optional .init_site.json to /tmp/init_site.json in order to keep it...

Move the optional .init_site.json to /tmp/init_site.json in order to keep it available even after truncating current directory
parent 3af26349
No related branches found
No related tags found
No related merge requests found
......@@ -24,6 +24,9 @@ function restoreEnvFile {
}
function create {
if [[ -f ".init_site.json" ]]; then
mv .init_site.json /tmp/init_site.json
fi
truncateCurrentDirectory
if [[ -n ${REPOSITORY} ]]; then
composer create-project ${PROJECT} . --no-interaction --repository ${REPOSITORY}
......@@ -40,8 +43,9 @@ function create {
# Init site config values
if [[ -f "drush/Commands/dev_modules/dev_modules.info.yml" ]]; then
if [[ -f ".init_site.json" ]]; then
drush site:init ../.init_site.json
if [[ -f "/tmp/init_site.json" ]]; then
drush site:init /tmp/init_site.json
rm /tmp/init_site.json
fi
fi
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment