Cleanup old markdown documenation approach (#979)

This commit is contained in:
Aleksandr Chebotov
2020-06-02 20:07:12 +03:00
committed by GitHub
parent 8c8f384a61
commit 43e26fa96b
72 changed files with 133 additions and 1541 deletions

View File

@@ -41,35 +41,3 @@ $installedMinGWTools | ForEach-Object {
}
}
# Adding description of the software to Markdown
function Get-ToolVersion {
param(
[string] $ToolPath,
[int] $VersionLineNumber
)
$toolRawVersion = Invoke-Expression "$ToolPath --version"
$toolRawVersion.Split([System.Environment]::NewLine)[$VersionLineNumber] -match "\d+\.\d+(\.\d+)?" | Out-Null
$toolVersion = $matches[0]
return $toolVersion
}
$SoftwareName = "MSYS2"
$pacmanVersion = Get-ToolVersion -ToolPath "$msys2BinDir/pacman" -VersionLineNumber 1
$bashVersion = Get-ToolVersion -ToolPath "$msys2BinDir/bash" -VersionLineNumber 0
$gccVersion = Get-ToolVersion -ToolPath "$msys2mingwDir/gcc" -VersionLineNumber 0
$tarVersion = Get-ToolVersion -ToolPath "$msys2BinDir/tar" -VersionLineNumber 0
$Description = @"
> _Note:_ MSYS2 is pre-installed on image but not added to PATH.
_Tool versions_
_pacman:_ $pacmanVersion<br/>
_bash:_ $bashVersion<br/>
_gcc:_ $gccVersion<br/>
_tar:_ $tarVersion<br/>
MSYS2 location: C:\msys64
"@
Add-SoftwareDetailsToMarkdown -SoftwareName $SoftwareName -DescriptionMarkdown $Description