state:set¶
Set a state value.
Examples¶
state:set system.maintenance_mode 1 --input-format=integerstate:set system.cron_last 1406682882 --input-format=integerstate:set php -r "print json_encode(array('drupal', 'simpletest'));" | drush state:set --input-format=json foo.name -state:set twig_debug TRUEstate:set twig_autoreload TRUEstate:set twig_cache_disable TRUEstate:set disable_rendered_output_cache_bins TRUE
Arguments¶
- key. The state key, for example system.cron_last.
- value. The value to assign to the state key. Use - to read from stdin.
Options¶
- --input-format=INPUT-FORMAT. Type for the value: auto, string, integer, float, boolean, json or yaml. Auto detects numbers and TRUE/FALSE. [default: auto]
Global Options¶
- -h, --help. Display help for the given command. When no command is given display help for the list command
- --silent. Do not output any message
- -q, --quiet. Only errors are displayed. All other output is suppressed
- -v|vv|vvv, --verbose. Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug
- -V, --version. Display this application version
- --ansi. Force (or disable --no-ansi) ANSI output
- --no-ansi. Negate the --ansi option.
- -n, --no-interaction. Do not ask any interactive question
- --url=URL. A base URL (e.g. example.com). Used for building links, selecting a multi-site, etc.
- -e, --env=ENV. The Environment name. [default: prod]
- --no-debug. Switches off debug mode.
Aliases¶
- sset
- state-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.