mirror of
https://github.com/actions/runner-images.git
synced 2025-12-13 12:48:18 +00:00
Add missed Rust tools to the documentation for Win (#2401)
* Add documentation for rust tools * Rename helpers * Remove duplicates
This commit is contained in:
@@ -42,6 +42,31 @@ function Get-RustVersion {
|
||||
return $rustVersion
|
||||
}
|
||||
|
||||
function Get-RustupVersion {
|
||||
$version = [regex]::matches($(rustup --version), "\d+\.\d+\.\d+").Value
|
||||
return $version
|
||||
}
|
||||
|
||||
function Get-RustCargoVersion {
|
||||
$version = [regex]::matches($(cargo --version), "\d+\.\d+\.\d+").Value
|
||||
return $version
|
||||
}
|
||||
|
||||
function Get-RustdocVersion {
|
||||
$version = [regex]::matches($(rustdoc --version), "\d+\.\d+\.\d+").Value
|
||||
return $version
|
||||
}
|
||||
|
||||
function Get-RustfmtVersion {
|
||||
$version = [regex]::matches($(rustfmt --version), "\d+\.\d+\.\d+").Value
|
||||
return $version
|
||||
}
|
||||
|
||||
function Get-RustClippyVersion {
|
||||
$version = [regex]::matches($(cargo clippy --version), "\d+\.\d+\.\d+").Value
|
||||
return $version
|
||||
}
|
||||
|
||||
function Get-BindgenVersion {
|
||||
return bindgen --version
|
||||
}
|
||||
|
||||
@@ -116,14 +116,19 @@ $markdown += New-MDList -Style Unordered -Lines @(
|
||||
|
||||
$markdown += New-MDHeader "Rust Tools" -Level 3
|
||||
$markdown += New-MDList -Style Unordered -Lines @(
|
||||
"Rust $(Get-RustVersion)"
|
||||
"Rust $(Get-RustVersion)",
|
||||
"Rustup $(Get-RustupVersion)",
|
||||
"Cargo $(Get-RustCargoVersion)",
|
||||
"Rustdoc $(Get-RustdocVersion)"
|
||||
)
|
||||
$markdown += New-MDHeader "Packages" -Level 4
|
||||
$markdown += New-MDList -Style Unordered -Lines @(
|
||||
(Get-BindgenVersion),
|
||||
(Get-CbindgenVersion),
|
||||
(Get-CargoAuditVersion),
|
||||
(Get-CargoOutdatedVersion)
|
||||
(Get-CargoOutdatedVersion),
|
||||
"Rustfmt $(Get-RustfmtVersion)",
|
||||
"Clippy $(Get-RustClippyVersion)"
|
||||
)
|
||||
|
||||
$markdown += New-MDHeader "Browsers and webdrivers" -Level 3
|
||||
|
||||
Reference in New Issue
Block a user