Skip to content

Commit

Permalink
cms@a69fb94
Browse files Browse the repository at this point in the history
Finish 4.13.0
  • Loading branch information
shinybrad committed Nov 12, 2024
1 parent 38361a0 commit afdae72
Show file tree
Hide file tree
Showing 2 changed files with 284 additions and 0 deletions.
212 changes: 212 additions & 0 deletions docs/.artifacts/cms/4.x/console-commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -1376,6 +1376,206 @@ $ php craft on
The system is now online.
```

## `pc`

Alias of project-config.

<h3 id="pc-apply">
<a href="#pc-apply" class="header-anchor">#</a>
<code>pc/apply</code>
</h3>


Applies project config file changes.

<h4 id="pc-apply-options" class="command-subheading">Options</h4>


--force
: Whether every entry change should be force-applied.


--quiet
: Whether to reduce the command output.



<h3 id="pc-diff">
<a href="#pc-diff" class="header-anchor">#</a>
<code>pc/diff</code>
</h3>


Outputs a diff of the pending project config YAML changes.

<h4 id="pc-diff-options" class="command-subheading">Options</h4>


--invert
: Whether to treat the loaded project config as the source of truth, instead of the YAML files.



<h3 id="pc-export">
<a href="#pc-export" class="header-anchor">#</a>
<code>pc/export</code>
</h3>


Exports the entire project config to a single file.

<h4 id="pc-export-parameters" class="command-subheading">Parameters</h4>

path
: The path the project config should be exported to.
Can be any of the following:

- A full file path
- A folder path (export will be saved in there with a dynamically-generated name)
- A filename (export will be saved in the working directory with the given name)
- Blank (export will be saved in the working directly with a dynamically-generated name)



<h4 id="pc-export-options" class="command-subheading">Options</h4>


--external
: Whether to pull values from the project config YAML files instead of the loaded config.


--overwrite
: Whether to overwrite an existing export file, if a specific file path is given.



<h3 id="pc-get">
<a href="#pc-get" class="header-anchor">#</a>
<code>pc/get</code>
</h3>


Outputs a project config value.

Example:
```
php craft project-config/get system.edition
```

The “path” syntax used here may be composed of directory and filenames (within your `config/project` folder), YAML object keys (including UUIDs for many Craft resources), and integers (referencing numerically-indexed arrays), joined by a dot (`.`): `path.to.nested.array.0.property`.

<h4 id="pc-get-parameters" class="command-subheading">Parameters</h4>

path
: The config item path



<h4 id="pc-get-options" class="command-subheading">Options</h4>


--external
: Whether to pull values from the project config YAML files instead of the loaded config.



<h3 id="pc-rebuild">
<a href="#pc-rebuild" class="header-anchor">#</a>
<code>pc/rebuild</code>
</h3>


Rebuilds the project config.

<h3 id="pc-remove">
<a href="#pc-remove" class="header-anchor">#</a>
<code>pc/remove</code>
</h3>


Removes a project config value.

Example:
```
php craft project-config/remove some.nested.key
```

::: danger
This should only be used when the equivalent change is not possible through the control panel or other Craft APIs. By directly modifying project config values, you are bypassing all validation and can easily destabilize configuration.
:::

As with [set](#project-config-set), removing values only updates the root `dateModified` key when using the [`--update-timestamp` flag](#project-config-set-options). If you do not include this flag, you must run `project-config/touch` before changes will be detected or applied in other environments!

<h4 id="pc-remove-parameters" class="command-subheading">Parameters</h4>

path
: The config item path



<h3 id="pc-set">
<a href="#pc-set" class="header-anchor">#</a>
<code>pc/set</code>
</h3>


Sets a project config value.

Example:
```
php craft project-config/set some.nested.key
```

See [get](#project-config-get) for the accepted key formats.

::: danger
This should only be used when the equivalent change is not possible through the control panel or other Craft APIs. By directly modifying project config values, you are bypassing all validation and can easily destabilize configuration.
:::

Values are updated in the database *and* in your local YAML files, but the root `dateModified` project config property is only touched when using the [`--update-timestamp` flag](#project-config-set-options). If you do not update the timestamp along with the value, the change may not be detected or applied in other environments!

<h4 id="pc-set-parameters" class="command-subheading">Parameters</h4>

path
: The config item path

value
: The config item value as a valid YAML string



<h4 id="pc-set-options" class="command-subheading">Options</h4>


--force
: Whether every entry change should be force-applied.


--message
: A message describing the changes.


--update-timestamp
: Whether the `dateModified` value should be updated



<h3 id="pc-touch">
<a href="#pc-touch" class="header-anchor">#</a>
<code>pc/touch</code>
</h3>


Updates the `dateModified` value in `config/project/project.yaml`, attempting to resolve a Git conflict for it.

<h3 id="pc-write">
<a href="#pc-write" class="header-anchor">#</a>
<code>pc/write</code>
</h3>


Writes out the currently-loaded project config as YAML files to the `config/project/` folder, discarding any pending YAML changes.

## `plugin`

Manages plugins.
Expand Down Expand Up @@ -2893,6 +3093,18 @@ version using the syntax `<handle>:<version>`.
until the licenses have been renewed.


--minor-only
: Whether only minor updates should be applied.


--patch-only
: Whether only patch updates should be applied.


--except
: Plugin handles to exclude


--force, -f
: Force the update if allowUpdates is disabled

Expand Down
72 changes: 72 additions & 0 deletions docs/.artifacts/cms/4.x/events.json
Original file line number Diff line number Diff line change
Expand Up @@ -3802,6 +3802,24 @@
"type": "yii\\base\\ActionEvent",
"desc": "an event raised right after executing a controller action."
},
{
"class": "craft\\console\\controllers\\PcController",
"name": "EVENT_DEFINE_ACTIONS",
"type": "craft\\events\\DefineConsoleActionsEvent",
"desc": "The event that is triggered when defining custom actions for this controller."
},
{
"class": "craft\\console\\controllers\\PcController",
"name": "EVENT_BEFORE_ACTION",
"type": "yii\\base\\ActionEvent",
"desc": "an event raised right before executing a controller action. You may set `ActionEvent::isValid` to be false to cancel the action execution."
},
{
"class": "craft\\console\\controllers\\PcController",
"name": "EVENT_AFTER_ACTION",
"type": "yii\\base\\ActionEvent",
"desc": "an event raised right after executing a controller action."
},
{
"class": "craft\\console\\controllers\\PluginController",
"name": "EVENT_DEFINE_ACTIONS",
Expand Down Expand Up @@ -24095,6 +24113,48 @@
"type": "yii\\base\\Event",
"desc": "an event raised at the end of `validate()`"
},
{
"class": "craft\\elements\\conditions\\LanguageConditionRule",
"name": "EVENT_INIT",
"type": "yii\\base\\Event",
"desc": "The event that is triggered after the model's init cycle"
},
{
"class": "craft\\elements\\conditions\\LanguageConditionRule",
"name": "EVENT_DEFINE_BEHAVIORS",
"type": "craft\\events\\DefineBehaviorsEvent",
"desc": "The event that is triggered when defining the class behaviors"
},
{
"class": "craft\\elements\\conditions\\LanguageConditionRule",
"name": "EVENT_DEFINE_RULES",
"type": "craft\\events\\DefineRulesEvent",
"desc": "The event that is triggered when defining the model rules"
},
{
"class": "craft\\elements\\conditions\\LanguageConditionRule",
"name": "EVENT_DEFINE_FIELDS",
"type": "craft\\events\\DefineFieldsEvent",
"desc": "The event that is triggered when defining the arrayable fields"
},
{
"class": "craft\\elements\\conditions\\LanguageConditionRule",
"name": "EVENT_DEFINE_EXTRA_FIELDS",
"type": "craft\\events\\DefineFieldsEvent",
"desc": "The event that is triggered when defining the extra arrayable fields"
},
{
"class": "craft\\elements\\conditions\\LanguageConditionRule",
"name": "EVENT_BEFORE_VALIDATE",
"type": "yii\\base\\ModelEvent",
"desc": "an event raised at the beginning of `validate()`. You may set `ModelEvent::isValid` to be false to stop the validation."
},
{
"class": "craft\\elements\\conditions\\LanguageConditionRule",
"name": "EVENT_AFTER_VALIDATE",
"type": "yii\\base\\Event",
"desc": "an event raised at the end of `validate()`"
},
{
"class": "craft\\elements\\conditions\\LevelConditionRule",
"name": "EVENT_INIT",
Expand Down Expand Up @@ -37188,6 +37248,12 @@
"type": "craft\\events\\DefineAddressSubdivisionsEvent",
"desc": "The event that is triggered when defining subdivisions options for an address field for a given country code, and optionally administrativeArea and locality."
},
{
"class": "craft\\services\\Addresses",
"name": "EVENT_DEFINE_ADDRESS_COUNTRIES",
"type": "craft\\events\\DefineAddressCountriesEvent",
"desc": "The event that is triggered when defining country options for an address."
},
{
"class": "craft\\services\\Assets",
"name": "EVENT_BEFORE_REPLACE_ASSET",
Expand Down Expand Up @@ -37872,6 +37938,12 @@
"type": "craft\\events\\FieldEvent",
"desc": "The event that is triggered before a field is saved."
},
{
"class": "craft\\services\\Fields",
"name": "EVENT_BEFORE_APPLY_FIELD_SAVE",
"type": "craft\\events\\ApplyFieldSaveEvent",
"desc": "The event that is triggered before a field save is applied to the database."
},
{
"class": "craft\\services\\Fields",
"name": "EVENT_AFTER_SAVE_FIELD",
Expand Down

0 comments on commit afdae72

Please sign in to comment.