Skip to content

Commit

Permalink
Merge pull request #1384 from chef/darwin_detection
Browse files Browse the repository at this point in the history
Make sure macOS detection works even if the string changes
  • Loading branch information
marcparadise authored Jul 31, 2020
2 parents abd9f55 + 50684f9 commit 791c7e2
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion omnibus/files/uninstall-scripts/uninstall_chef_workstation
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ error_exit()

is_darwin()
{
uname -v | grep "^Darwin" 2>&1 >/dev/null
uname -a | grep "^Darwin" 2>&1 >/dev/null
}

if is_darwin; then
Expand Down
2 changes: 1 addition & 1 deletion omnibus/omnibus-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ version="${VERSION:-latest}"

is_darwin()
{
uname -v | grep "^Darwin" >/dev/null 2>&1
uname -a | grep "^Darwin" 2>&1 >/dev/null
}

echo "--- Installing $channel $product $version"
Expand Down
2 changes: 1 addition & 1 deletion omnibus/package-scripts/chef-workstation/postinst
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ error_exit()

is_darwin()
{
uname -v | grep "^Darwin" >/dev/null 2>&1
uname -a | grep "^Darwin" 2>&1 >/dev/null
}

if is_darwin; then
Expand Down
2 changes: 1 addition & 1 deletion omnibus/package-scripts/chef-workstation/postrm
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

is_darwin()
{
uname -v | grep "^Darwin" 2>&1 >/dev/null
uname -a | grep "^Darwin" 2>&1 >/dev/null
}

cleanup_symlinks() {
Expand Down
2 changes: 1 addition & 1 deletion omnibus/package-scripts/chef-workstation/preinst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ error_exit()

is_darwin()
{
uname -v | grep "^Darwin" 2>&1 >/dev/null
uname -a | grep "^Darwin" 2>&1 >/dev/null
}

if is_darwin; then
Expand Down

0 comments on commit 791c7e2

Please sign in to comment.