Azure / Azure/bicep

Support getting ISO week date, week of year

Open
#13,527 0 comments 0 reactions 0 assignees View on GitHub
enhancement Needs: Upvote new function
Dominant language
Bicep
Stars
3.6k
Forks
830
Avg merge
1d 2h
Merged PRs (30d)
79

Description

There are some simple date functions available in Bicep: https://learn.microsoft.com/en-us/azure/azure-resource-manager/bicep/bicep-functions-date

With https://learn.microsoft.com/en-us/dotnet/api/system.globalization.isoweek?view=net-8.0, we can get the standardized week day formats in c#, without having to bother with localization.

Useful in
- a sandbox environment where soft delete resources (like key vaults) are cleaned up automatically (but not purged), thus needing a resource name with reliable increment postfix which doesn't change too often, but have to be unique enough to not collide with existing soft deleted resources (thus weeknumbers are perfect, at least in my case)
- tagging strategy
- description fields

Contributor guide

Open the contributing guide

Research direction

Start by reviewing Bicep's existing date functions and the linked .NET ISOWeek API to compare the requested standardized week-date and week-of-year behavior. Define the expected results and edge cases from ISO week-date rules, then verify that the new capability is documented and covered by appropriate tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure
Domain
cloud, infrastructure
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.