-
Notifications
You must be signed in to change notification settings - Fork 4.1k
/
setup-local-env.sh
executable file
·39 lines (28 loc) · 1.24 KB
/
setup-local-env.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#!/bin/bash
# Exit if any command fails
set -e
# Set up environment variables
. "$(dirname "$0")/bootstrap-env.sh"
# Include useful functions
. "$(dirname "$0")/includes.sh"
# Change to the expected directory
cd "$(dirname "$0")/.."
# Check Node and NVM are installed
. "$(dirname "$0")/install-node-nvm.sh"
# Check Docker is installed and running
. "$(dirname "$0")/install-docker.sh"
! read -d '' GUTENBERG <<"EOT"
,⁻⁻⁻· . |
| ،⁓’. . |--- ,---. ,---. |---. ,---. ,---. ,---.
| | | | | |---' | | | | |---' | | |
`---' `---' `---’ `---’ ' ` `---' `---’ ` `---|
`---'
EOT
CURRENT_URL=$(docker-compose $DOCKER_COMPOSE_FILE_OPTIONS run -T --rm cli option get siteurl)
echo -e "\nWelcome to...\n"
echo -e "\033[95m$GUTENBERG\033[0m"
# Give the user more context to what they should do next: Build Gutenberg and start testing!
echo -e "\nRun $(action_format "npm run dev") to build the latest Gutenberg packages,"
echo -e "then open $(action_format "$CURRENT_URL") to get started!"
echo -e "\n\nAccess the above install using the following credentials:"
echo -e "Default username: $(action_format "admin"), password: $(action_format "password")"