mirror of
https://github.com/fleschutz/PowerShell.git
synced 2024-10-06 01:51:59 +02:00
Rename to list-calendar.ps1
This commit is contained in:
parent
8876c5c003
commit
3a23ab483f
@ -1,24 +1,24 @@
|
|||||||
<#
|
<#
|
||||||
.SYNOPSIS
|
.SYNOPSIS
|
||||||
Writes out a calendar
|
Lists the calendar
|
||||||
.DESCRIPTION
|
.DESCRIPTION
|
||||||
Writes out calendar elements, either a single month or an entire year.
|
Lists calendar elements, either a single month or an entire year.
|
||||||
.PARAMETER Month
|
.PARAMETER Month
|
||||||
If specified, will limit output to a single month with this numeral value.
|
If specified, will limit output to a single month with this numeral value.
|
||||||
.PARAMETER Year
|
.PARAMETER Year
|
||||||
If specified, will output an entire year.
|
If specified, will output an entire year.
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
PS> ./write-calendar
|
PS> ./list-calendar
|
||||||
Outputs the current month.
|
Lists the calendar for current month.
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
PS> ./write-calendar 2013
|
PS> ./list-calendar 2013
|
||||||
Outputs the calendar for 2013.
|
Lists the calendar for 2013.
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
PS> ./write-calendar 04 2011
|
PS> ./list-calendar 04 2011
|
||||||
Outputs the calendar for April, 2011.
|
Lists the calendar for April, 2011.
|
||||||
.EXAMPLE
|
.EXAMPLE
|
||||||
PS> ./write-calendar 7
|
PS> ./list-calendar 7
|
||||||
Outputs the calendar for July of this year.
|
Lists the calendar for July of this year.
|
||||||
.LINK
|
.LINK
|
||||||
https://github.com/fleschutz/PowerShell
|
https://github.com/fleschutz/PowerShell
|
||||||
.NOTES
|
.NOTES
|
||||||
@ -139,10 +139,8 @@ function Find-LastWeekDay ($year, $month, $dayOfWeek) {
|
|||||||
if ($dayCounter.DayOfWeek -eq $dayOfWeek) {
|
if ($dayCounter.DayOfWeek -eq $dayOfWeek) {
|
||||||
$result = $dayCounter
|
$result = $dayCounter
|
||||||
}
|
}
|
||||||
|
|
||||||
$dayCounter = $dayCounter.AddDays(1)
|
$dayCounter = $dayCounter.AddDays(1)
|
||||||
}
|
}
|
||||||
|
|
||||||
return $result
|
return $result
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user