mirror of
https://github.com/actions/runner-images-sangeeth.git
synced 2025-12-14 22:09:26 +00:00
[Ubuntu] Get toolset value function. (#2435)
* [macOS] Fail Pester tests on error * return it back * [Ubuntu] add get_toolset_values function * added fix * fix all nitpicks * try to get rid brackets * removed brackets. * pipx-package fix
This commit is contained in:
@@ -47,4 +47,14 @@ function IsPackageInstalled {
|
||||
verlte() {
|
||||
sortedVersion=$(echo -e "$1\n$2" | sort -V | head -n1)
|
||||
[ "$1" = "$sortedVersion" ]
|
||||
}
|
||||
|
||||
get_toolset_path() {
|
||||
echo "/imagegeneration/installers/toolset.json"
|
||||
}
|
||||
|
||||
get_toolset_value() {
|
||||
local toolset_path=$(get_toolset_path)
|
||||
local query=$1
|
||||
echo "$(jq -r "$query" $toolset_path)"
|
||||
}
|
||||
Reference in New Issue
Block a user