PHPackages                             wp-packagist/wp-cli-global-config-command - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [CLI &amp; Console](/categories/cli)
4. /
5. wp-packagist/wp-cli-global-config-command

ActiveWp-cli-package[CLI &amp; Console](/categories/cli)

wp-packagist/wp-cli-global-config-command
=========================================

WP-CLI Global Configuration Command.

v1.0.4(6y ago)2144MITPHPPHP ^5.5 || ^7.0CI failing

Since Aug 1Pushed 4y ago1 watchersCompare

[ Source](https://github.com/wp-packagist/wp-cli-global-config-command)[ Packagist](https://packagist.org/packages/wp-packagist/wp-cli-global-config-command)[ Docs](https://github.com/wp-packagist/wp-cli-global-config-command)[ RSS](/packages/wp-packagist-wp-cli-global-config-command/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (1)Dependencies (3)Versions (5)Used By (0)

WP-CLI Global Configuration Command
===================================

[](#wp-cli-global-configuration-command)

[![Build Status](https://camo.githubusercontent.com/319c9e5ad24cb91bb9758e58769e7df7e9d3c8926b31941bc081eea5af82b266/68747470733a2f2f7472617669732d63692e636f6d2f77702d7061636b61676973742f77702d636c692d676c6f62616c2d636f6e6669672d636f6d6d616e642e7376673f6272616e63683d6d6173746572)](https://travis-ci.com/wp-packagist/wp-cli-global-config-command) [![GitHub](https://camo.githubusercontent.com/6684876a0d97992935706899dde64e0e5e295ad85757f6c4205523f2ee629d31/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f77702d7061636b61676973742f77702d636c692d676c6f62616c2d636f6e6669672d636f6d6d616e64)](https://camo.githubusercontent.com/6684876a0d97992935706899dde64e0e5e295ad85757f6c4205523f2ee629d31/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f77702d7061636b61676973742f77702d636c692d676c6f62616c2d636f6e6669672d636f6d6d616e64) [![Packagist Version](https://camo.githubusercontent.com/07048cd0d5a1bee69d29a34e8f76b931de507915d02e2b55642b316ce018d868/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f77702d7061636b61676973742f77702d636c692d676c6f62616c2d636f6e6669672d636f6d6d616e64)](https://camo.githubusercontent.com/07048cd0d5a1bee69d29a34e8f76b931de507915d02e2b55642b316ce018d868/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f77702d7061636b61676973742f77702d636c692d676c6f62616c2d636f6e6669672d636f6d6d616e64)

WP-CLI has a series of global parameters (e.g. --path= and --user=) which work with all commands.

This config saved in `config.yml` or `wp-cli.yml` files. [\[WP-CLI Document\]](https://make.wordpress.org/cli/handbook/config/).

With this package, you can easily add, delete or edit WP-CLI global parameters in the command line and you no longer need to edit the source settings file.

[![WP-CLI logo](https://raw.githubusercontent.com/wp-packagist/wp-cli-global-config-command/master/wp-cli-logo.png)](https://raw.githubusercontent.com/wp-packagist/wp-cli-global-config-command/master/wp-cli-logo.png)

Table of Contents
-----------------

[](#table-of-contents)

- [Installation](#installation)
- [Structure](#structure)
- [Commands](#commands)
    - [Show list](#show-list)
    - [Set New Config](#set-new-config)
        - [Set new config with the boolean value](#set-new-config-with-the-boolean-value)
        - [Set new config with the number value](#set-new-config-with-the-number-value)
        - [Set new config with the array value](#set-new-config-with-the-array-value)
        - [Set new config with the null value](#set-new-config-with-the-null-value)
        - [Set new config with empty value](#set-new-config-with-empty-value)
    - [Set new config with nested array key](#set-new-config-with-nested-array-key)
    - [Get Config Value](#get-config-value)
    - [Remove Config Value](#remove-config-value)
    - [Reset Configuration](#reset-configuration)
- [Author](#author)
- [Contributing](#contributing)

Installation
------------

[](#installation)

You can install this package with:

```
wp package install wp-packagist/wp-cli-global-config-command
```

> Installing this package requires WP-CLI v2 or greater. Update to the latest stable release with `wp cli update`.

Structure
---------

[](#structure)

```
NAME

  wp global-config

DESCRIPTION

  Global Configuration.

SYNOPSIS

  wp global-config

SUBCOMMANDS

  get         Show Custom Config.
  list        Show Configuration list.
  remove      Remove Config Parameter.
  reset       Reset Configuration.
  set         Set new config.

```

For All commands in this package, you can use `--local` flag for process in a local config file current working directory \[wp-cli.local.yml\].

Commands
--------

[](#commands)

List of WP-CLI global config Commands:

### Show list

[](#show-list)

For show list all global parameters:

```
wp global-config list
```

also for show list of all global config in the current directory:

```
wp global-config list --local
```

### Set New Config

[](#set-new-config)

Structure:

```
wp global-config set   [--local]
```

For example, set new path:

```
wp global-config set path ~/wp-cli/site
```

##### Set new config with the boolean value

[](#set-new-config-with-the-boolean-value)

```
wp global-config set color false
```

##### Set new config with the number value

[](#set-new-config-with-the-number-value)

```
wp global-config set my-custom-number 100
```

##### Set new config with the array value

[](#set-new-config-with-the-array-value)

use JSON Format.

```
wp global-config set disabled_commands '["db drop","plugin install"]'
```

##### Set new config with the null value

[](#set-new-config-with-the-null-value)

```
wp global-config set db_pass null
```

##### Set new config with space in key

[](#set-new-config-with-space-in-key)

```
wp global-config set "config create" new_value
```

##### Set new config with empty value

[](#set-new-config-with-empty-value)

```
wp global-config set db_pass ''
```

### Set new config with nested array key

[](#set-new-config-with-nested-array-key)

you can use `:` caharacter per level.

```
wp global-config set @staging:user
```

example 2:

```
wp global-config set @staging:user:ID 32
```

example 3:

disable plugin install command only in the current directory project.

```
wp global-config set disabled_commands '["plugin install"]' --local
```

### Get Config Value

[](#get-config-value)

Structure:

```
wp global-config get  [--local]
```

For example:

```
wp global-config get port
```

or for local config:

```
wp global-config get url --local
```

### Remove Config Value

[](#remove-config-value)

Structure:

```
wp global-config remove
```

for example:

```
wp global-config remove path
```

```
wp global-config remove color --local
```

You can also nested key name in this command.

```
wp global-config remove key_1:key_2_child
```

### Reset Configuration

[](#reset-configuration)

```
wp global-config reset
```

For local current directory config:

```
wp global-config reset --local
```

Author
------

[](#author)

- [Mehrshad Darzi](https://www.linkedin.com/in/mehrshaddarzi/) | PHP Full Stack and WordPress Expert

Contributing
------------

[](#contributing)

We appreciate you taking the initiative to contribute to this project.

Contributing isn’t limited to just code. We encourage you to contribute in the way that best fits your abilities, by writing tutorials, giving a demo at your local meetup, helping other users with their support questions, or revising our documentation.

### Reporting a bug

[](#reporting-a-bug)

Think you’ve found a bug? We’d love for you to help us get it fixed. Before you create a new issue, you should [search existing issues](https://github.com/wp-packagist/wp-cli-global-config-command/issues?q=label%3Abug%20) to see if there’s an existing resolution to it, or if it’s already been fixed in a newer version.

### Creating a pull request

[](#creating-a-pull-request)

Want to contribute a new feature? Please first [open a new issue](https://github.com/wp-packagist/wp-cli-global-config-command/issues/new) to discuss whether the feature is a good fit for the project.

Once you've decided to commit the time to seeing your pull request through, please follow our guidelines for creating a pull request to make sure it's a pleasant experience:

1. Create a feature branch for each contribution.
2. Submit your pull request early for feedback.
3. Follow [PSR-2 Coding Standards](http://www.php-fig.org/psr/psr-2/).

###  Health Score

27

—

LowBetter than 47% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity13

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~70 days

Total

4

Last Release

2315d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/949491?v=4)[Mehrshad Darzi](/maintainers/mehrshaddarzi)[@mehrshaddarzi](https://github.com/mehrshaddarzi)

---

Top Contributors

[![mehrshaddarzi](https://avatars.githubusercontent.com/u/949491?v=4)](https://github.com/mehrshaddarzi "mehrshaddarzi (35 commits)")

---

Tags

commandcommand-linecommand-line-toolwordpresswordpress-developmentwp-cliwp-cli-commandwp-cli-configwp-cli-packagecliwordpresswp-cli

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/wp-packagist-wp-cli-global-config-command/health.svg)

```
[![Health](https://phpackages.com/badges/wp-packagist-wp-cli-global-config-command/health.svg)](https://phpackages.com/packages/wp-packagist-wp-cli-global-config-command)
```

###  Alternatives

[wp-cli/wp-cli

WP-CLI framework

5.1k18.5M401](/packages/wp-cli-wp-cli)[wp-cli/wp-cli-bundle

WP-CLI bundle package with default commands.

906.9M154](/packages/wp-cli-wp-cli-bundle)[wearerequired/wp-cli-clear-opcache

Use WP-CLI to clear the OPcache for a site via HTTP.

1736.4k](/packages/wearerequired-wp-cli-clear-opcache)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
