aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorMike McQuaid2016-09-20 10:58:55 +0100
committerGitHub2016-09-20 10:58:55 +0100
commit5b9a43a370120a76883e79b82a9a8e06441680fe (patch)
treee1e2a4a5416a88cbbdd808132c246d61d4da7e83 /Library
parentf87e3626bb241bc88bead4ed6448a76c1bf49f56 (diff)
parent3099d126d7b57d9a4eee82bdd87ef5e77e86346b (diff)
downloadbrew-5b9a43a370120a76883e79b82a9a8e06441680fe.tar.bz2
Merge pull request #1031 from MikeMcQuaid/rearrange-repo
Rearrange repository
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/README.md2
-rw-r--r--Library/Homebrew/cask/README.md2
-rw-r--r--Library/Homebrew/cmd/help.rb2
-rw-r--r--Library/Homebrew/cmd/info.rb2
-rw-r--r--Library/Homebrew/cmd/list.rb6
-rw-r--r--Library/Homebrew/cmd/tap-info.rb2
-rw-r--r--Library/Homebrew/cmd/update-report.rb10
-rw-r--r--Library/Homebrew/dev-cmd/create.rb2
-rw-r--r--Library/Homebrew/dev-cmd/man.rb4
-rw-r--r--Library/Homebrew/dev-cmd/tap-readme.rb2
-rw-r--r--Library/Homebrew/formula.rb4
-rw-r--r--Library/Homebrew/manpages/brew.1.md.erb6
-rw-r--r--Library/Homebrew/test/test_bash.rb2
-rw-r--r--Library/Homebrew/utils.rb7
-rw-r--r--Library/Homebrew/utils/analytics.rb2
-rw-r--r--Library/Homebrew/utils/analytics.sh2
16 files changed, 30 insertions, 27 deletions
diff --git a/Library/Homebrew/README.md b/Library/Homebrew/README.md
index ccf0a02d7..b8bf5fd99 100644
--- a/Library/Homebrew/README.md
+++ b/Library/Homebrew/README.md
@@ -3,6 +3,6 @@ This is the (partially) documented public API for Homebrew.
The main class you should look at is the {Formula} class (and classes linked from there). That's the class that's used to create Homebrew formulae (i.e. package descriptions). Assume anything else you stumble upon is private.
-You may also find the [Formula Cookbook](https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/Formula-Cookbook.md) and [Ruby Style Guide](https://github.com/styleguide/ruby) helpful in creating formulae.
+You may also find the [Formula Cookbook](https://github.com/Homebrew/brew/blob/master/docs/Formula-Cookbook.md) and [Ruby Style Guide](https://github.com/styleguide/ruby) helpful in creating formulae.
Good luck!
diff --git a/Library/Homebrew/cask/README.md b/Library/Homebrew/cask/README.md
index 1d0dc5882..0dc494af1 100644
--- a/Library/Homebrew/cask/README.md
+++ b/Library/Homebrew/cask/README.md
@@ -6,7 +6,7 @@ Homebrew-Cask extends [Homebrew](http://brew.sh) and brings its elegance, simpli
We do this by providing a friendly Homebrew-style CLI workflow for the administration of macOS applications distributed as binaries.
-It’s implemented as a `homebrew` [external command](https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/External-Commands.md) called `cask`.
+It’s implemented as a `homebrew` [external command](https://github.com/Homebrew/brew/blob/master/docs/External-Commands.md) called `cask`.
[![Join the chat at https://gitter.im/caskroom/homebrew-cask](https://img.shields.io/badge/gitter-join%20chat-blue.svg)](https://gitter.im/caskroom/homebrew-cask)
diff --git a/Library/Homebrew/cmd/help.rb b/Library/Homebrew/cmd/help.rb
index 0bf3d0d8d..2a814b90b 100644
--- a/Library/Homebrew/cmd/help.rb
+++ b/Library/Homebrew/cmd/help.rb
@@ -16,7 +16,7 @@ Troubleshooting:
Developers:
brew create [URL [--no-fetch]]
brew edit [FORMULA...]
- https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/Formula-Cookbook.md
+ https://github.com/Homebrew/brew/blob/master/docs/Formula-Cookbook.md
Further help:
man brew
diff --git a/Library/Homebrew/cmd/info.rb b/Library/Homebrew/cmd/info.rb
index 0310ab624..2474aad57 100644
--- a/Library/Homebrew/cmd/info.rb
+++ b/Library/Homebrew/cmd/info.rb
@@ -14,7 +14,7 @@
#: information on all installed formulae.
#:
#: See the docs for examples of using the JSON:
-#: <https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/Querying-Brew.md>
+#: <https://github.com/Homebrew/brew/blob/master/docs/Querying-Brew.md>
require "blacklist"
require "caveats"
diff --git a/Library/Homebrew/cmd/list.rb b/Library/Homebrew/cmd/list.rb
index ba236068d..4fdd8a85e 100644
--- a/Library/Homebrew/cmd/list.rb
+++ b/Library/Homebrew/cmd/list.rb
@@ -64,6 +64,8 @@ module Homebrew
UNBREWED_EXCLUDE_PATHS = %w[
.github/*
bin/brew
+ completions/zsh/_brew
+ docs/*
lib/gdk-pixbuf-2.0/*
lib/gio/*
lib/node_modules/*
@@ -73,13 +75,11 @@ module Homebrew
lib/ruby/gems/[12].*
lib/ruby/site_ruby/[12].*
lib/ruby/vendor_ruby/[12].*
+ manpages/brew.1
share/pypy/*
share/pypy3/*
- share/doc/homebrew/*
share/info/dir
- share/man/man1/brew.1
share/man/whatis
- share/zsh/site-functions/_brew
].freeze
def list_unbrewed
diff --git a/Library/Homebrew/cmd/tap-info.rb b/Library/Homebrew/cmd/tap-info.rb
index b599cb591..432d51287 100644
--- a/Library/Homebrew/cmd/tap-info.rb
+++ b/Library/Homebrew/cmd/tap-info.rb
@@ -13,7 +13,7 @@
#: Pass `--installed` to get information on installed taps.
#:
#: See the docs for examples of using the JSON:
-#: <https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/Querying-Brew.md>
+#: <https://github.com/Homebrew/brew/blob/master/docs/Querying-Brew.md>
require "tap"
diff --git a/Library/Homebrew/cmd/update-report.rb b/Library/Homebrew/cmd/update-report.rb
index b096dfc3b..1e9c8ccd3 100644
--- a/Library/Homebrew/cmd/update-report.rb
+++ b/Library/Homebrew/cmd/update-report.rb
@@ -294,15 +294,15 @@ module Homebrew
end
def link_completions_and_docs(repository = HOMEBREW_REPOSITORY)
- return if HOMEBREW_PREFIX.to_s == repository.to_s
command = "brew update"
- link_src_dst_dirs(repository/"etc/bash_completion.d",
+ link_src_dst_dirs(repository/"completions/bash",
HOMEBREW_PREFIX/"etc/bash_completion.d", command)
- link_src_dst_dirs(repository/"share/doc/homebrew",
+ link_src_dst_dirs(repository/"docs",
HOMEBREW_PREFIX/"share/doc/homebrew", command, link_dir: true)
- link_src_dst_dirs(repository/"share/zsh/site-functions",
+ link_src_dst_dirs(repository/"completions/zsh",
HOMEBREW_PREFIX/"share/zsh/site-functions", command)
- link_path_manpages(repository/"share", command)
+ link_src_dst_dirs(repository/"manpages",
+ HOMEBREW_PREFIX/"share/man/man1", command)
rescue => e
ofail <<-EOS.undent
Failed to link all completions, docs and manpages:
diff --git a/Library/Homebrew/dev-cmd/create.rb b/Library/Homebrew/dev-cmd/create.rb
index 1667fdfc7..19fd251b7 100644
--- a/Library/Homebrew/dev-cmd/create.rb
+++ b/Library/Homebrew/dev-cmd/create.rb
@@ -154,7 +154,7 @@ class FormulaCreator
end
def template; <<-EOS.undent
- # Documentation: https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/Formula-Cookbook.md
+ # Documentation: https://github.com/Homebrew/brew/blob/master/docs/Formula-Cookbook.md
# http://www.rubydoc.info/github/Homebrew/brew/master/Formula
# PLEASE REMOVE ALL GENERATED COMMENTS BEFORE SUBMITTING YOUR PULL REQUEST!
diff --git a/Library/Homebrew/dev-cmd/man.rb b/Library/Homebrew/dev-cmd/man.rb
index f90aa6d2a..0627241a3 100644
--- a/Library/Homebrew/dev-cmd/man.rb
+++ b/Library/Homebrew/dev-cmd/man.rb
@@ -7,8 +7,8 @@ require "ostruct"
module Homebrew
SOURCE_PATH = HOMEBREW_LIBRARY_PATH/"manpages"
- TARGET_MAN_PATH = HOMEBREW_REPOSITORY/"share/man/man1"
- TARGET_DOC_PATH = HOMEBREW_REPOSITORY/"share/doc/homebrew"
+ TARGET_MAN_PATH = HOMEBREW_REPOSITORY/"manpages"
+ TARGET_DOC_PATH = HOMEBREW_REPOSITORY/"docs"
def man
raise UsageError unless ARGV.named.empty?
diff --git a/Library/Homebrew/dev-cmd/tap-readme.rb b/Library/Homebrew/dev-cmd/tap-readme.rb
index f88d43389..e1a3e0eb4 100644
--- a/Library/Homebrew/dev-cmd/tap-readme.rb
+++ b/Library/Homebrew/dev-cmd/tap-readme.rb
@@ -24,7 +24,7 @@ module Homebrew
```
## Documentation
- `brew help`, `man brew` or check [Homebrew's documentation](https://github.com/Homebrew/brew/tree/master/share/doc/homebrew#readme).
+ `brew help`, `man brew` or check [Homebrew's documentation](https://github.com/Homebrew/brew/tree/master/docs#readme).
EOS
puts template if ARGV.verbose?
diff --git a/Library/Homebrew/formula.rb b/Library/Homebrew/formula.rb
index 4a48a5749..4cff28d8e 100644
--- a/Library/Homebrew/formula.rb
+++ b/Library/Homebrew/formula.rb
@@ -26,7 +26,7 @@ require "migrator"
# @see SharedEnvExtension
# @see FileUtils
# @see Pathname
-# @see http://www.rubydoc.info/github/Homebrew/brew/file/share/doc/homebrew/Formula-Cookbook.md Formula Cookbook
+# @see http://www.rubydoc.info/github/Homebrew/brew/file/docs/Formula-Cookbook.md Formula Cookbook
# @see https://github.com/styleguide/ruby Ruby Style Guide
#
# <pre>class Wget < Formula
@@ -1973,7 +1973,7 @@ class Formula
# and you haven't passed or previously used any options on this formula.
#
# If you maintain your own repository, you can add your own bottle links.
- # https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/Bottles.md
+ # https://github.com/Homebrew/brew/blob/master/docs/Bottles.md
# You can ignore this block entirely if submitting to Homebrew/Homebrew, It'll be
# handled for you by the Brew Test Bot.
#
diff --git a/Library/Homebrew/manpages/brew.1.md.erb b/Library/Homebrew/manpages/brew.1.md.erb
index f856b50ee..e44dc2658 100644
--- a/Library/Homebrew/manpages/brew.1.md.erb
+++ b/Library/Homebrew/manpages/brew.1.md.erb
@@ -62,7 +62,7 @@ scripts that reside somewhere in the `PATH`, named `brew-`<cmdname> or
to create your own commands without modifying Homebrew's internals.
Instructions for creating your own commands can be found in the docs:
-<https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/External-Commands.md>
+<https://github.com/Homebrew/brew/blob/master/docs/External-Commands.md>
## SPECIFYING FORMULAE
@@ -183,7 +183,7 @@ can take several different forms:
*Default:* the number of available CPU cores.
* `HOMEBREW_NO_ANALYTICS`:
- If set, Homebrew will not send analytics. See: <https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/Analytics.md#analytics>
+ If set, Homebrew will not send analytics. See: <https://github.com/Homebrew/brew/blob/master/docs/Analytics.md#analytics>
* `HOMEBREW_NO_AUTO_UPDATE`:
If set, Homebrew will not auto-update before running `brew install`,
@@ -249,7 +249,7 @@ If your proxy requires authentication:
## SEE ALSO
-Homebrew Documentation: <https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/>
+Homebrew Documentation: <https://github.com/Homebrew/brew/blob/master/docs/>
`git`(1), `git-log`(1)
diff --git a/Library/Homebrew/test/test_bash.rb b/Library/Homebrew/test/test_bash.rb
index e965aaf21..ff418c787 100644
--- a/Library/Homebrew/test/test_bash.rb
+++ b/Library/Homebrew/test/test_bash.rb
@@ -19,7 +19,7 @@ class BashTests < Homebrew::TestCase
end
def test_bash_completion
- script = HOMEBREW_LIBRARY_PATH.parent.parent/"etc/bash_completion.d/brew"
+ script = HOMEBREW_LIBRARY_PATH.parent.parent/"completions/bash/brew"
assert_valid_bash_syntax script
end
diff --git a/Library/Homebrew/utils.rb b/Library/Homebrew/utils.rb
index 8121b7146..e466f8a08 100644
--- a/Library/Homebrew/utils.rb
+++ b/Library/Homebrew/utils.rb
@@ -605,8 +605,11 @@ def link_src_dst_dirs(src_dir, dst_dir, command, link_dir: false)
src_paths = link_dir ? [src_dir] : src_dir.find
src_paths.each do |src|
next if src.directory? && !link_dir
- dst = dst_dir.parent/src.relative_path_from(src_dir.parent)
- next if dst.symlink? && src == dst.resolved_path
+ dst = dst_dir/src.relative_path_from(src_dir)
+ if dst.symlink?
+ next if src == dst.resolved_path
+ dst.unlink
+ end
if dst.exist?
conflicts << dst
next
diff --git a/Library/Homebrew/utils/analytics.rb b/Library/Homebrew/utils/analytics.rb
index e176f0566..9066cce73 100644
--- a/Library/Homebrew/utils/analytics.rb
+++ b/Library/Homebrew/utils/analytics.rb
@@ -35,7 +35,7 @@ module Utils
end
# Send analytics. Don't send or store any personally identifiable information.
- # https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/Analytics.md
+ # https://github.com/Homebrew/brew/blob/master/docs/Analytics.md
# https://developers.google.com/analytics/devguides/collection/protocol/v1/devguide
# https://developers.google.com/analytics/devguides/collection/protocol/v1/parameters
if ENV["HOMEBREW_ANALYTICS_DEBUG"]
diff --git a/Library/Homebrew/utils/analytics.sh b/Library/Homebrew/utils/analytics.sh
index 0bc58c0be..24839709e 100644
--- a/Library/Homebrew/utils/analytics.sh
+++ b/Library/Homebrew/utils/analytics.sh
@@ -104,7 +104,7 @@ report-analytics-screenview-command() {
)
# Send analytics. Don't send or store any personally identifiable information.
- # https://github.com/Homebrew/brew/blob/master/share/doc/homebrew/Analytics.md
+ # https://github.com/Homebrew/brew/blob/master/docs/Analytics.md
# https://developers.google.com/analytics/devguides/collection/protocol/v1/devguide#screenView
# https://developers.google.com/analytics/devguides/collection/protocol/v1/parameters
if [[ -z "$HOMEBREW_ANALYTICS_DEBUG" ]]