CI: Add zsh-based build framework files for macOS
This commit is contained in:
parent
c33fa8bfa2
commit
1cfa06a2aa
31 changed files with 554 additions and 100 deletions
22
.github/scripts/utils.zsh/check_macos
vendored
Normal file
22
.github/scripts/utils.zsh/check_macos
vendored
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
autoload -Uz is-at-least log_group log_info log_error log_status
|
||||
|
||||
local macos_version=$(sw_vers -productVersion)
|
||||
|
||||
log_group 'Install macOS build requirements'
|
||||
log_info 'Checking macOS version...'
|
||||
if ! is-at-least 11.0 ${macos_version}; then
|
||||
log_error "Minimum required macOS version is 11.0, but running on macOS ${macos_version}"
|
||||
return 2
|
||||
else
|
||||
log_status "macOS ${macos_version} is recent"
|
||||
fi
|
||||
|
||||
log_info 'Checking for Homebrew...'
|
||||
if (( ! ${+commands[brew]} )) {
|
||||
log_error 'No Homebrew command found. Please install Homebrew (https://brew.sh)'
|
||||
return 2
|
||||
}
|
||||
|
||||
brew bundle --file ${SCRIPT_HOME}/.Brewfile
|
||||
rehash
|
||||
log_group
|
||||
Loading…
Add table
Add a link
Reference in a new issue