Merge pull request #2043 from reitermarkus/create-caskroom
Small fixes.
This commit is contained in:
commit
a74b7ade66
@ -21,9 +21,10 @@ module Hbc
|
||||
return if Hbc.caskroom.exist?
|
||||
|
||||
ohai "Creating Caskroom at #{Hbc.caskroom}"
|
||||
ohai "We'll set permissions properly so we won't need sudo in the future"
|
||||
sudo = !Hbc.caskroom.parent.writable?
|
||||
|
||||
ohai "We'll set permissions properly so we won't need sudo in the future" if sudo
|
||||
|
||||
SystemCommand.run("/bin/mkdir", args: ["-p", Hbc.caskroom], sudo: sudo)
|
||||
SystemCommand.run("/bin/chmod", args: ["g+rwx", Hbc.caskroom], sudo: sudo)
|
||||
SystemCommand.run("/usr/sbin/chown", args: [Utils.current_user, Hbc.caskroom], sudo: sudo)
|
||||
|
||||
@ -15,6 +15,10 @@ module Hbc
|
||||
end
|
||||
end
|
||||
|
||||
def self.needs_init?
|
||||
true
|
||||
end
|
||||
|
||||
def self.help
|
||||
"downloads remote application files to local cache"
|
||||
end
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user