Merge pull request #341 from skywinder/Fix/return-not-allowed-in-block

Update Rakefile to avoid install-breaking bug
This commit is contained in:
Olle Jonsson 2016-02-29 17:34:52 +01:00
commit 7d92087f4a

View File

@ -16,14 +16,14 @@ task :copy_man_page_to_manpath do |_t|
path.file? && path.readable? path.file? && path.readable?
end end
return unless manpath next unless manpath
writable_man_path = Pathname(manpath).each_line.find do |line| writable_man_path = Pathname(manpath).each_line.find do |line|
path = Pathname(line.chomp) path = Pathname(line.chomp)
path.directory? && path.writable? path.directory? && path.writable?
end end
return unless writable_man_path next unless writable_man_path
man_prefix = Pathname("#{writable_man_path.chomp}/man1") man_prefix = Pathname("#{writable_man_path.chomp}/man1")
man_pages = "man/git-*.1" man_pages = "man/git-*.1"