This commit is contained in:
Wes Haggard 2021-06-11 15:47:55 -07:00 коммит произвёл GitHub
Родитель f151e023b6
Коммит 0ec54c2cdb
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
9 изменённых файлов: 16 добавлений и 21 удалений

Просмотреть файл

@ -62,20 +62,15 @@ else {
### Update template files with date
foreach ($file in (Get-ChildItem $releaseFolder/$releaseFileName)) {
$fileContent = Get-Content $file
$fileContent = Get-Content $file -Raw
$fileContent = $fileContent | ForEach-Object {
if ($_ -match "%%(?<format>.*?)%%") {
try {
$_ -replace $matches[0], $releaseDate.ToString($matches["format"])
}
catch {
Write-Host ("Date format " + $matches["format"] + " in file $file is invalid.")
}
} else {
$_
}
$dateFormats = [regex]::Matches($fileContent, "%%(?<format>.*?)%%")
foreach ($dateFormatMatch in $dateFormats)
{
$fileContent = $fileContent -replace $dateFormatMatch.Groups[0], $releaseDate.ToString($dateFormatMatch.Groups["format"])
}
$fileContent | Set-Content $file
$fileContent | Set-Content $file -NoNewline
}
}

Просмотреть файл

@ -5,4 +5,4 @@ tags: dotnet azure
sidebar: releases_sidebar
repository: azure/azure-sdk-for-net
---
{% include releases/notes/common.md language="dotnet" data="%%yyyy-MM%%" date="%%MMMM yyyy%%" %}
{% include releases/notes/common.md language="dotnet" date="%%yyyy-MM%%" displayDate="%%MMMM yyyy%%" %}

Просмотреть файл

@ -5,4 +5,4 @@ tags: java azure
sidebar: releases_sidebar
repository: azure/azure-sdk-for-java
---
{% include releases/notes/common.md language="java" data="%%yyyy-MM%%" date="%%MMMM yyyy%%" %}
{% include releases/notes/common.md language="java" date="%%yyyy-MM%%" displayDate="%%MMMM yyyy%%" %}

Просмотреть файл

@ -5,4 +5,4 @@ tags: javascript typescript azure
sidebar: releases_sidebar
repository: azure/azure-sdk-for-js
---
{% include releases/notes/common.md language="js" data="%%yyyy-MM%%" date="%%MMMM yyyy%%" %}
{% include releases/notes/common.md language="js" date="%%yyyy-MM%%" displayDate="%%MMMM yyyy%%" %}

Просмотреть файл

@ -5,4 +5,4 @@ tags: python azure
sidebar: releases_sidebar
repository: azure/azure-sdk-for-python
---
{% include releases/notes/common.md language="python" data="%%yyyy-MM%%" date="%%MMMM yyyy%%" %}
{% include releases/notes/common.md language="python" date="%%yyyy-MM%%" displayDate="%%MMMM yyyy%%" %}

Просмотреть файл

@ -5,4 +5,4 @@ tags: dotnet azure
sidebar: releases_sidebar
repository: azure/azure-sdk-for-net
---
{% include releases/notes/common.md language="dotnet" data="2021-06" date="June 2021" %}
{% include releases/notes/common.md language="dotnet" date="2021-06" displayDate="June 2021" %}

Просмотреть файл

@ -5,4 +5,4 @@ tags: java azure
sidebar: releases_sidebar
repository: azure/azure-sdk-for-java
---
{% include releases/notes/common.md language="java" data="2021-06" date="%%MMMM yyyy%%" %}
{% include releases/notes/common.md language="java" date="2021-06" displayDate="June 2021" %}

Просмотреть файл

@ -5,4 +5,4 @@ tags: javascript typescript azure
sidebar: releases_sidebar
repository: azure/azure-sdk-for-js
---
{% include releases/notes/common.md language="js" data="2021-06" date="%%MMMM yyyy%%" %}
{% include releases/notes/common.md language="js" date="2021-06" displayDate="June 2021" %}

Просмотреть файл

@ -5,4 +5,4 @@ tags: python azure
sidebar: releases_sidebar
repository: azure/azure-sdk-for-python
---
{% include releases/notes/common.md language="python" data="2021-06" date="%%MMMM yyyy%%" %}
{% include releases/notes/common.md language="python" date="2021-06" displayDate="June 2021" %}