Commit ff97ef8
authored
🚀 [Feature]: Add Get-Greeting function (#11)
Adds a new `Get-Greeting` function that returns a greeting message based
on the time of day. This provides a simple utility for generating
contextual greetings in scripts and modules.
- Related to PSModule/Process-PSModule#263 (testing PR-based release
notes)
## New Function
The `Get-Greeting` function accepts an optional `-TimeOfDay` parameter
with values `Morning`, `Afternoon`, or `Evening`, defaulting to
`Morning`.
```powershell
# Returns "Good Morning!"
Get-Greeting
# Returns "Good Evening!"
Get-Greeting -TimeOfDay 'Evening'
```
## Tests
Added tests to verify the function works correctly with the default
parameter and explicit time of day values.1 parent 55de693 commit ff97ef8
3 files changed
Lines changed: 32 additions & 1 deletion
File tree
- .github/workflows
- src/functions/public
- tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
30 | | - | |
| 30 | + | |
31 | 31 | | |
32 | 32 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
13 | 13 | | |
14 | 14 | | |
15 | 15 | | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
16 | 24 | | |
0 commit comments