26 lines
910 B
Ruby
26 lines
910 B
Ruby
cask 'inspec' do
|
|
version '1.7.1-1'
|
|
sha256 'f6864c80146c1867d47e14014a1ba8e8733819890789106b3e8f57cae963d47e'
|
|
|
|
# packages.chef.io was verified as official when first introduced to the cask
|
|
url "https://packages.chef.io/files/stable/inspec/#{version.major_minor_patch}/mac_os_x/10.12/inspec-#{version}.dmg"
|
|
appcast 'https://github.com/chef/inspec/releases.atom',
|
|
checkpoint: '435f1d336ebd4def62c9c7e110a76bd94a140974c80347d401c306e332166cb4'
|
|
name 'InSpec by Chef'
|
|
homepage 'http://inspec.io/'
|
|
|
|
pkg "inspec-#{version}.pkg"
|
|
|
|
# As suggested in https://docs.chef.io/install_dk.html#mac-os-x
|
|
uninstall_postflight do
|
|
system_command '/usr/bin/find',
|
|
args: ['/usr/local/bin', '-lname', '/opt/inspec/*', '-delete'],
|
|
sudo: true
|
|
end
|
|
|
|
uninstall pkgutil: 'com.getchef.pkg.inspec',
|
|
delete: '/opt/inspec/'
|
|
|
|
zap delete: '~/.inspec/'
|
|
end
|