Skip to content

Commit aba7096

Browse files
committed
20220703B
1 parent a20efdd commit aba7096

File tree

4 files changed

+13
-13
lines changed

4 files changed

+13
-13
lines changed

hugoalh.GitHubActionsToolkit/module/artifact.psm1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ A (literal) path that denote the base root directory of the files for control fi
2020
.PARAMETER ContinueOnIssue
2121
Whether the export should continue in the event of files fail to export; If not set and issue is encountered, export will stop and queued files will not export; The partial artifact availables which include files up until the issue; If set and issue is encountered, the issue file will ignore and skip, and queued files will still export; The partial artifact availables which include everything but exclude issue files.
2222
.PARAMETER RetentionTime
23-
Duration of artifact expire by days.
23+
Duration of artifact expire, by days.
2424
.OUTPUTS
2525
[PSCustomObject] Exported artifact's metadata.
2626
#>

hugoalh.GitHubActionsToolkit/module/cache.psm1

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ Do not use Azure Blob SDK to download caches that are stored on Azure Blob Stora
2020
.PARAMETER DownloadConcurrency
2121
Number of parallel downloads (only for Azure SDK).
2222
.PARAMETER Timeout
23-
Maximum time for each download request by seconds (only for Azure SDK).
23+
Maximum time for each download request, by seconds (only for Azure SDK).
2424
.OUTPUTS
2525
[String] The key of the cache hit.
2626
#>
@@ -32,7 +32,7 @@ Function Restore-Cache {
3232
[Parameter(Mandatory = $True, ParameterSetName = 'Path', Position = 1, ValueFromPipeline = $True, ValueFromPipelineByPropertyName = $True)][SupportsWildcards()][Alias('File', 'Files', 'Paths')][String[]]$Path,
3333
[Parameter(Mandatory = $True, ParameterSetName = 'LiteralPath', ValueFromPipeline = $True, ValueFromPipelineByPropertyName = $True)][Alias('LiteralFile', 'LiteralFiles', 'LiteralPaths', 'LP', 'PSPath', 'PSPaths')][String[]]$LiteralPath,
3434
[Parameter(ValueFromPipelineByPropertyName = $True)][Alias('NoAzureSdk')][Switch]$NotUseAzureSdk,
35-
[Parameter(ValueFromPipelineByPropertyName = $True)][ValidateRange(1, 16)][Byte]$DownloadConcurrency = 0,
35+
[Parameter(ValueFromPipelineByPropertyName = $True)][ValidateRange(1, 16)][Alias('Concurrency')][Byte]$DownloadConcurrency = 0,
3636
[Parameter(ValueFromPipelineByPropertyName = $True)][ValidateRange(5, 900)][UInt16]$Timeout = 0
3737
)
3838
Begin {
@@ -90,7 +90,7 @@ Cache path.
9090
.PARAMETER LiteralPath
9191
Cache literal path.
9292
.PARAMETER UploadChunkSizes
93-
Maximum chunk size by bytes.
93+
Maximum chunk size, by KB.
9494
.PARAMETER UploadConcurrency
9595
Number of parallel uploads.
9696
.OUTPUTS
@@ -103,8 +103,8 @@ Function Save-Cache {
103103
[Parameter(Mandatory = $True, Position = 0, ValueFromPipelineByPropertyName = $True)][ValidateScript({ Return (Test-CacheKey -InputObject $_) }, ErrorMessage = '`{0}` is not a valid GitHub Actions cache key, and/or more than 512 characters!')][Alias('Name')][String]$Key,
104104
[Parameter(Mandatory = $True, ParameterSetName = 'Path', Position = 1, ValueFromPipeline = $True, ValueFromPipelineByPropertyName = $True)][SupportsWildcards()][Alias('File', 'Files', 'Paths')][String[]]$Path,
105105
[Parameter(Mandatory = $True, ParameterSetName = 'LiteralPath', ValueFromPipeline = $True, ValueFromPipelineByPropertyName = $True)][Alias('LiteralFile', 'LiteralFiles', 'LiteralPaths', 'LP', 'PSPath', 'PSPaths')][String[]]$LiteralPath,
106-
[Parameter(ValueFromPipelineByPropertyName = $True)][ValidateRange(1KB, 1GB)][UInt32]$UploadChunkSizes = 0,
107-
[Parameter(ValueFromPipelineByPropertyName = $True)][ValidateRange(1, 16)][Byte]$UploadConcurrency = 0
106+
[Parameter(ValueFromPipelineByPropertyName = $True)][ValidateRange(1, 1MB)][Alias('ChunkSize', 'ChunkSizes', 'UploadChunkSize')][UInt32]$UploadChunkSizes = 0,
107+
[Parameter(ValueFromPipelineByPropertyName = $True)][ValidateRange(1, 16)][Alias('Concurrency')][Byte]$UploadConcurrency = 0
108108
)
109109
Begin {
110110
[Boolean]$NoOperation = $False# When the requirements are not fulfill, only stop this function but not others.
@@ -124,7 +124,7 @@ Function Save-Cache {
124124
}) : $Path
125125
}
126126
If ($UploadChunkSizes -igt 0) {
127-
$InputObject.UploadChunkSizes = $UploadChunkSizes
127+
$InputObject.UploadChunkSizes = $UploadChunkSizes * 1KB
128128
}
129129
If ($UploadConcurrency -igt 0) {
130130
$InputObject.UploadConcurrency = $UploadConcurrency

hugoalh.GitHubActionsToolkit/module/step-summary.psm1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,9 @@ Image title.
8585
.PARAMETER AlternativeText
8686
Image alternative text.
8787
.PARAMETER Width
88-
Image width, by pixels.
88+
Image width, by pixels (px).
8989
.PARAMETER Height
90-
Image height, by pixels.
90+
Image height, by pixels (px).
9191
.PARAMETER NoNewLine
9292
Do not add a new line or carriage return to the content, the string representations of the input objects are concatenated to form the output, no spaces or newlines are inserted between the output strings, no newline is added after the last output string.
9393
.OUTPUTS

hugoalh.GitHubActionsToolkit/module/tool-cache.psm1

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -104,9 +104,9 @@ Find the path of a tool in the local installed tool cache.
104104
.PARAMETER Name
105105
Tool name.
106106
.PARAMETER Version
107-
Tool version, by Semantic Versioning (SemVer).
107+
Tool version, by Semantic Versioning (SemVer); Default to all versions.
108108
.PARAMETER Architecture
109-
Tool architecture.
109+
Tool architecture; Default to current machine architecture.
110110
.OUTPUTS
111111
[String] Path of a version of a tool.
112112
[String[]] Paths of all versions of a tool.
@@ -219,7 +219,7 @@ Tool name.
219219
.PARAMETER Version
220220
Tool version, by Semantic Versioning (SemVer).
221221
.PARAMETER Architecture
222-
Tool architecture.
222+
Tool architecture; Default to current machine architecture.
223223
.OUTPUTS
224224
[String] Tool cached path.
225225
#>
@@ -273,7 +273,7 @@ Tool name.
273273
.PARAMETER Version
274274
Tool version, by Semantic Versioning (SemVer).
275275
.PARAMETER Architecture
276-
Tool architecture.
276+
Tool architecture; Default to current machine architecture.
277277
.OUTPUTS
278278
[String] Tool cached path.
279279
#>

0 commit comments

Comments
 (0)