Skip to content

site:set

Set a site alias that will persist for the current session.

Stores the site alias being used in the current session in a temporary file. Use @dev to set current session to use the @dev alias. Use - to go back to the previously-set site (like cd -). Without an argument, any existing site becomes unset.

Help topics:

Examples

  • site:set @dev
  • site:set user@server/path/to/drupal#sitename
  • site:set /path/to/drupal#sitename
  • site:set -
  • site:set

Arguments

  • [site]. Site specification to use, or - for previous site. Omit this argument to unset.

Global Options

  • -v|vv|vvv, --verbose. Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug
  • -y, --yes. Auto-accept the default for all user prompts. Equivalent to --no-interaction.
  • -l, --uri=URI. A base URL for building links and selecting a multi-site. Defaults to https://default.
  • To see all global options, run drush core:global-options.

Aliases

  • use
  • site-set

Legend

  • An argument or option with square brackets is optional.
  • Any default value is listed at end of arg/option description.
  • An ellipsis indicates that an argument accepts multiple values separated by a space.