You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Move psake-config doc to Advanced Techniques and clarify scope
- Moved from tutorial-basics to tutorial-advanced since this is an
uncommon, advanced topic
- Added note that most projects don't need a config file
- Added "Partial Overrides" section explaining that missing properties
keep their defaults
- Fixed cross-reference links
https://claude.ai/code/session_0184Z4DLZ8Db72rkpca4kQwP
Copy file name to clipboardExpand all lines: docs/tutorial-advanced/custom-logging.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# Custom Logging
2
2
3
-
psake routes all internal messages through configurable output handlers. You can override these handlers in your [`psake-config.ps1`](../tutorial-basics/psake-config.md) file to integrate with your own logging system.
3
+
psake routes all internal messages through configurable output handlers. You can override these handlers in your [`psake-config.ps1`](./psake-config.md) file to integrate with your own logging system.
Copy file name to clipboardExpand all lines: docs/tutorial-advanced/psake-config.md
+12-4Lines changed: 12 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,6 +2,10 @@
2
2
3
3
psake loads a `psake-config.ps1` file at the start of every build to set default values for your build environment. You can use this file to change psake's default build file name, framework version, task name format, output handlers, and more.
4
4
5
+
:::note
6
+
Most projects do not need a `psake-config.ps1` file. psake's built-in defaults work well for the majority of use cases. Only create one if you need to change a specific default.
7
+
:::
8
+
5
9
## How psake Finds the Config File
6
10
7
11
psake searches for `psake-config.ps1` in two locations, in order:
@@ -13,6 +17,10 @@ The first file found wins. If neither location contains a config file, psake use
13
17
14
18
This means you can place a `psake-config.ps1` next to your `psakefile.ps1` to customize settings per-project, or place one alongside the psake module for machine-wide defaults.
15
19
20
+
## Partial Overrides
21
+
22
+
Your config file does not need to set every property. psake initializes all properties to their defaults before loading your config file, so any property you omit keeps its default value. You only need to set the properties you want to change.
23
+
16
24
## Configuration Properties
17
25
18
26
Inside `psake-config.ps1`, you set properties on the `$config` variable. Here is every available property:
psake routes all internal messages through configurable output handlers. For a full guide on customizing logging, see [Custom Logging](../tutorial-advanced/custom-logging.md).
83
+
psake routes all internal messages through configurable output handlers. For a full guide on customizing logging, see [Custom Logging](./custom-logging.md).
0 commit comments