install: add comment explaining why we're creating these files.

This commit is contained in:
Mike McQuaid 2019-09-18 09:43:29 +01:00
parent 8d6ac3869c
commit 704ea4b4bb
No known key found for this signature in database
GPG Key ID: 48A898132FD8EE70

View File

@ -25,6 +25,9 @@ module Homebrew
begin
FileUtils.mkdir_p(dir) unless dir.exist?
# Create these files to ensure that these directories aren't removed
# by the Catalina installer.
# (https://github.com/Homebrew/brew/issues/6263)
keep_file = dir/".keepme"
FileUtils.touch(keep_file) unless keep_file.exist?
rescue