Skip to content

Commit

Permalink
revert
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexSkrypnyk committed Feb 18, 2024
1 parent d1f0881 commit 263a4d5
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 14 deletions.
6 changes: 3 additions & 3 deletions .ahoy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ commands:
ahoy composer install --prefer-dist && \
(docker compose exec cli mkdir -p .data && docker compose cp -L .data/db.sql cli:/app/.data/db.sql || true) && \
ahoy provision && \
DREVOPS_SHOW_LOGIN_LINK=1 ahoy info
DREVOPS_DRUPAL_SHOW_LOGIN_LINK=1 ahoy info
info:
usage: Show information about this project.
Expand Down Expand Up @@ -154,7 +154,7 @@ commands:
usage: "Remove containers, all build files. Use with `hard` to reset repository to the last commit."
cmd: |
ahoy confirm "All containers and build files will be removed. Proceed?" &&
AHOY_CONFIRM=y ahoy down && ./scripts/drevops/reset.sh "$@"
AHOY_CONFIRM_RESPONSE=y ahoy down && ./scripts/drevops/reset.sh "$@"
fei:
usage: Install front-end assets.
Expand Down Expand Up @@ -258,7 +258,7 @@ commands:
confirm:
cmd: |
if [ -z "$AHOY_CONFIRM" ]; then
read -r -p ">> $1 [y/N] " AHOY_CONFIRM
read -r -p ">> $1 [y/N] " AHOY_CONFIRM_RESPONSE
[ "$AHOY_CONFIRM" = "y" ] || [ "$AHOY_CONFIRM" = true ] || ( echo "The operation was canceled." && exit 1 )
else
echo ">> $1 [y/N] $AHOY_CONFIRM" \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ DREVOPS_DEBUG=
DREVOPS_DOCKER_VERBOSE=

# Set to `y` to suppress Ahoy prompts.
AHOY_CONFIRM=
AHOY_CONFIRM_RESPONSE=

# When Ahoy prompts are suppressed ($AHOY_CONFIRM is 1), the command
# When Ahoy prompts are suppressed ($AHOY_CONFIRM_RESPONSE is 1), the command
# will wait for 3 seconds before proceeding.
# Set this variable to "1" to skip the wait.
AHOY_CONFIRM_WAIT_SKIP=1
2 changes: 1 addition & 1 deletion .drevops/docs/content/contributing/maintenance/tests.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Some tests use test fixtures such as Drupal database snapshots.
echo "DRUPAL_PROFILE=standard">>.env.local
echo "DREVOPS_PROVISION_USE_PROFILE=1">>.env.local
rm .data/db.sql
AHOY_CONFIRM=1 ahoy build
AHOY_CONFIRM_RESPONSE=1 ahoy build
```
2. Check that everything looks correctly on the site.
3. Export DB
Expand Down
6 changes: 3 additions & 3 deletions .drevops/docs/content/workflows/variables.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Environment variables allow to configure workflows.

## Variables list

### `AHOY_CONFIRM`
### `AHOY_CONFIRM_RESPONSE`

Set to `y` to suppress Ahoy prompts.

Expand All @@ -22,7 +22,7 @@ Defined in: `.env.local.default`

### `AHOY_CONFIRM_WAIT_SKIP`

When Ahoy prompts are suppressed ([`$AHOY_CONFIRM`](#AHOY_CONFIRM) is `1`), the command<br />will wait for `3` seconds before proceeding.<br />Set this variable to "`1`" to skip the wait.
When Ahoy prompts are suppressed ([`$AHOY_CONFIRM`](#AHOY_CONFIRM_RESPONSE) is `1`), the command<br />will wait for `3` seconds before proceeding.<br />Set this variable to "`1`" to skip the wait.

Default value: `1`

Expand Down Expand Up @@ -1281,7 +1281,7 @@ Default value: `UNDEFINED`

Defined in: `ACQUIA ENVIRONMENT`

### `DREVOPS_SHOW_LOGIN_LINK`
### `DREVOPS_DRUPAL_SHOW_LOGIN_LINK`

Show one-time login link.

Expand Down
2 changes: 1 addition & 1 deletion .drevops/tests/bats/_helper.bash
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ setup() {
unset DOCKER_PASS

# Disable interactive prompts during tests.
export AHOY_CONFIRM=y
export AHOY_CONFIRM_RESPONSE=y
# Disable waiting when interactive prompts are disabled durin tests.
export AHOY_CONFIRM_WAIT_SKIP=1

Expand Down
4 changes: 2 additions & 2 deletions .env.local.default
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
# @see https://docs.drevops.com/workflows/variables

# Suppress Ahoy prompts.
# AHOY_CONFIRM=y
# AHOY_CONFIRM_RESPONSE=y

# When Ahoy prompts are suppressed (AHOY_CONFIRM is 1), the command
# When Ahoy prompts are suppressed (AHOY_CONFIRM_RESPONSE is 1), the command
# will wait for 3 seconds before proceeding.
# Set this variable to "1" to skip the wait.
# AHOY_CONFIRM_WAIT_SKIP=1
Expand Down
4 changes: 2 additions & 2 deletions scripts/drevops/info.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ set -eu
DREVOPS_WEBROOT="${DREVOPS_WEBROOT:-web}"

# Show one-time login link.
DREVOPS_SHOW_LOGIN_LINK="${DREVOPS_SHOW_LOGIN_LINK:-}"
DREVOPS_DRUPAL_SHOW_LOGIN_LINK="${DREVOPS_DRUPAL_SHOW_LOGIN_LINK:-}"

# ------------------------------------------------------------------------------

Expand Down Expand Up @@ -46,7 +46,7 @@ if [ -n "${DREVOPS_HOST_SOLR_PORT:-}" ]; then
fi
note "Mailhog URL : http://mailhog.docker.amazee.io/"
note "Xdebug : $(php -v | grep -q Xdebug && echo "Enabled ('ahoy up cli' to disable)" || echo "Disabled ('ahoy debug' to enable)")"
if [ "${DREVOPS_SHOW_LOGIN_LINK}" = "1" ] || [ -n "${1:-}" ]; then
if [ "${DREVOPS_DRUPAL_SHOW_LOGIN_LINK}" = "1" ] || [ -n "${1:-}" ]; then
echo -n " Site login link : "
./scripts/drevops/login.sh
else
Expand Down

0 comments on commit 263a4d5

Please sign in to comment.