Skip to content

Commit

Permalink
Add WeekNumberYear
Browse files Browse the repository at this point in the history
  • Loading branch information
lowply committed Jan 3, 2020
1 parent 6ac512d commit 8c0fad9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ This action opens a new issue from an issue template. It parses the template's f
- `.WeekStartDate`: Date of Monday of the week
- `.WeekEndDate`: Date of Sunday of the week
- `.WeekNumber`: ISO week number
- `.WeekNumberYear`: Year of the Thursday of the week. Matches with [ISO week number](https://en.wikipedia.org/wiki/ISO_week_date#First_week)
- `.Dates`: Array of the dates of the week (Can be used as `{{ index .Dates 1 }}` in the template)

## Template example
Expand All @@ -20,7 +21,7 @@ This action opens a new issue from an issue template. It parses the template's f
---
name: Weekly Report
about: This is an example
title: 'Report on {{ .WeekStartDate }} (Week {{ .WeekNumber }}, {{ .Year }})'
title: 'Report on {{ .WeekStartDate }} (Week {{ .WeekNumber }}, {{ .WeekNumberYear }})'
labels: report
assignees: lowply
---
Expand Down

0 comments on commit 8c0fad9

Please sign in to comment.