function drush_set_context

8.0.x context.inc drush_set_context($context, $value)
6.x context.inc drush_set_context($context, $value)
7.x context.inc drush_set_context($context, $value)
3.x context.inc drush_set_context($context, $value)
4.x context.inc drush_set_context($context, $value)
5.x context.inc drush_set_context($context, $value)
master context.inc drush_set_context($context, $value)

Set a specific context.

Parameters

context: Any of the default defined contexts.

value: The value to store in the context

Return value

An associative array of the settings specified in the request context.

67 calls to drush_set_context()
commandUnitCase::testCommandVersionSpecific in tests/commandUnitTest.php
Assure that matching version-specific command files are loaded and others are ignored.
DrupalBoot::bootstrap_do_drupal_site in lib/Drush/Boot/DrupalBoot.php
Called by bootstrap_drupal_site to do the main work of the drush drupal site bootstrap.
DrupalBoot::bootstrap_drupal_login in lib/Drush/Boot/DrupalBoot.php
Log into the bootstrapped Drupal site with a specific username or user id.
DrupalBoot::bootstrap_drupal_root in lib/Drush/Boot/DrupalBoot.php
Bootstrap Drush with a valid Drupal Directory.
DrupalBoot::bootstrap_drupal_site_validate in lib/Drush/Boot/DrupalBoot.php
VALIDATE the DRUSH_BOOTSTRAP_DRUPAL_SITE phase.

... See full list

File

includes/context.inc, line 296
The Drush context API implementation.

Code

function drush_set_context($context, $value) {
  $cache = &drush_get_context($context);
  $cache = $value;
  return $value;
}