You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## Description: Delete all DB dumps saved by "ddev pull". Since those dumps are unsanitized until they get imported to a database, it is best to delete them if you plan to leave EU soil.
5
+
## Usage: travel-mode
6
+
## Example: "ddev travel-mode"
7
+
8
+
# Prompt for the PROJECTS folder, default to one level up from the current project
9
+
GIT_ROOT=$(git rev-parse --show-toplevel)
10
+
DEFAULT_PATH=$(dirname "$GIT_ROOT")
11
+
read -p "Enter the path to the PROJECTS folder [default: $DEFAULT_PATH]: " PROJECTS
12
+
PROJECTS=${PROJECTS:-$DEFAULT_PATH}
13
+
PROJECTS=$(realpath "$PROJECTS")
14
+
15
+
# Check if the folder exists
16
+
if [ !-d"$PROJECTS" ];then
17
+
echo"The folder '$PROJECTS' does not exist. Exiting."
18
+
exit 1
19
+
fi
20
+
21
+
# Find files under .ddev/.downloads/*
22
+
echo"Listing files under .ddev/.downloads/ in $PROJECTS..."
23
+
find "$PROJECTS" -type f -path '*/.ddev/.downloads/*' -print
24
+
25
+
read -p "Type 'yes' to delete the files: " input
26
+
if [ "$input"=="yes" ];then
27
+
echo"Deleting..."
28
+
find "$PROJECTS" -type f -path '*/.ddev/.downloads/*' -delete
0 commit comments