Issy Long
b78028b9c2
Auto-fix Performance/RegexpMatch offenses
2019-10-13 16:04:26 +01:00
Mike McQuaid
4759ffb88f
reinstall: handle remove/rename permission errors.
2019-05-24 16:46:54 +01:00
Mike McQuaid
8908dc51d6
keg: tell people what command will remove keg.
...
This will work regardless of permissions.
2019-05-23 10:19:34 +02:00
Mike McQuaid
c4f72312ce
Fixup brew style
failures.
2019-04-30 09:19:18 +01:00
Mike McQuaid
36dbad3922
Add frozen_string_literal to all files.
2019-04-20 13:27:36 +09:00
Mike McQuaid
d1ea6f38d3
Fix mutable constants violations.
2019-04-19 21:46:20 +09:00
Mike McQuaid
d64429a736
rubocop: enable Style/IfUnlessModifier.
2019-02-21 12:55:49 +00:00
Mike McQuaid
d5adf87cf4
cleanup: better handle edge cases.
...
- don't complain about "skipping" kegs when `brew cleanup` runs
automatically
- better handle orphaned directories
- output a better error message when a keg cannot be removed
Fixes #4989
Fixes #5627
Fixes https://github.com/Homebrew/homebrew-core/pull/35958#issuecomment-458031634
2019-01-28 16:08:23 +00:00
Mike McQuaid
737b84b54b
brew style --fix
fixes.
2018-11-02 17:29:23 +00:00
Shaun Jackman
4cbcf3ef2a
Keg::MUST_EXIST_DIRECTORIES: Frameworks is for macOS
2018-10-23 21:51:29 -07:00
EricFromCanada
20167e5f1b
Adjust comments to tidy API docs output.
2018-10-18 21:42:43 -04:00
Mike McQuaid
fe6b78a3f3
Use cache_store for descriptions
...
This makes use of both the existing interfaces and could use the
existing cache file but we'll create a new one and cleanup the old one
to avoid issues and use a more consistent name.
2018-10-13 08:22:52 -07:00
Mike McQuaid
ed9cf2ade6
keg: remove TOP_LEVEL_DIRECTORIES.
...
No longer needed in `brew test-bot` as of
https://github.com/Homebrew/homebrew-test-bot/pull/192
2018-09-27 08:19:47 +01:00
Mike McQuaid
9a698d2130
keg: further tweak directory constants.
...
- ensure that `HOMEBREW_CELLAR` is always created on `install`.
- remove the need for a special `PRUNEABLE_DIRECTORIES` variable
- reuse values from existing variables and get `uniq`s.
2018-09-25 22:03:29 +01:00
Markus Reiter
e9b9ea49a1
Update to RuboCop 0.59.1.
2018-09-17 03:45:59 +02:00
Mike McQuaid
2d71299675
keg: don't require Caskroom to be writable.
...
This isn't the case on our CI for now.
2018-09-07 09:39:32 +01:00
Mike McQuaid
7615d3a812
Improve writable directory handling
...
Consolidate the handling of which directories need to exist and which
need to be writable. Additionally, add a fatal check for formula
installations to ensure that any directories that need to be writable
are so before attempting an installation.
Fixes #4626 .
2018-09-06 18:38:43 +01:00
Mike McQuaid
80d75bc0d8
Homebrew/.rubocop: tweak rules.
...
Adjust the rules based on the current codebase. Remove various enable,
disables and default values that are unnecessary. Add more comments
explaining why. Make minor changes needed to enable a few more rules.
2018-09-02 20:15:09 +01:00
Mike McQuaid
bcb1ec5499
Improve Homebrew/brew line length.
...
Use 124 max line length everywhere. Also, reduce tap max line length to
189 as Homebrew/homebrew-core has that as a maximum now. In future
Homebrew/homebrew-core will also be reduced to 124 maximum line length.
2018-09-02 16:15:09 +01:00
Andrew Janke
e0a8a79921
Style fixes for Rubocop 0.57.1
2018-06-30 19:40:14 -04:00
Mike McQuaid
05568420c0
linkage_checker: fix cache invalidation.
...
Rather than using the name of the keg for the key use the full path.
This provides several advantages:
- there's no need to invalidate the cache on a `brew upgrade` or
`brew switch`
- it's easier to figure out what cache entries can be removed and this
can be done whenever a keg is removed by `brew uninstall` or
`brew cleanup`.
Also, ensure that an `install` (or `reinstall`, `upgrade`) always
results in the cache being rebuilt for that keg (in case different
options were used).
2018-06-06 13:30:45 +01:00
Mike McQuaid
0a00312b71
Autocorrect new RuboCop 0.55.0 style violations.
2018-04-17 10:54:58 +01:00
Mike McQuaid
3994d5937d
keg: don't remove versioned aliases on unlink.
...
Fixes #4030 .
2018-04-08 16:02:02 -07:00
Mike McQuaid
9fca172d03
Fix HOMEBREW_RUBY_WARNINGS="-w"
...
Fix various circular requirements, method redefinitions, etc.
2018-04-07 20:28:56 +01:00
Mike McQuaid
5dfa0cf622
keg: delete bad tap opt non-symlink directories.
...
But don't delete them if they are a symlink to a directory i.e. a normal
opt link.
Handles the issue mentioned in
1651647a3d (r28360427)
2018-04-01 09:27:49 +01:00
Mike McQuaid
8975bf0d5b
keg: use Formula#runtime_dependencies.
2018-03-27 14:52:48 +01:00
Mike McQuaid
a7727b66b3
keg: add tab, runtime_dependencies methods.
2018-03-27 14:52:47 +01:00
Mike McQuaid
9c8adb4ac0
keg: delete __pycache__ directory.
2018-03-18 18:48:43 +00:00
Mike McQuaid
6788e78c03
Revert "keg: tweak delete_pyc_files!"
...
This reverts commit 8e928992f5d2a1bbc39b295e2d2a9a2565ecec2a.
2018-03-08 09:18:52 +00:00
Mike McQuaid
e906ec374b
Revert "keg: fix delete_pyc_files path typo."
...
This reverts commit 948b1b8dbeb7bce35d5b0ecc45b14ac50d4eee93.
2018-03-08 09:18:49 +00:00
Mike McQuaid
1d708d77cb
Merge pull request #3892 from lembacon/pycache
...
keg: `delete_pyc_files!` should also remove `__pycache__`
2018-03-08 09:02:09 +00:00
Mike McQuaid
948b1b8dbe
keg: fix delete_pyc_files path typo.
2018-03-08 08:37:34 +00:00
Mike McQuaid
8e928992f5
keg: tweak delete_pyc_files!
2018-03-08 08:17:57 +00:00
ilovezfs
f87a589129
keg: don't delete main opt links of other formulae.
...
If an old alias, according to the tab, of a formula being upgraded (e.g.
python) has the same name as the main opt link of some other formula
(e.g. python@2), don't remove the main opt link of that other formula.
Specifically,
brew install python@2
brew upgrade python
should not accidentally delete /usr/local/opt/python@2 even though
python@2 used to be an alias of python.
2018-03-07 22:35:23 -08:00
Chongyu Zhu
3db033ca89
keg: delete_pyc_files!
should also remove __pycache__
2018-03-08 13:02:03 +08:00
Mike McQuaid
1f48e17f1b
rubocop: fix brew style warnings.
2018-01-17 10:42:43 +00:00
Markus Reiter
9bee9ca575
Use “squiggly” heredocs.
2017-10-18 14:39:09 +02:00
Mike McQuaid
01e9ec9a9f
Rubocop: automatic rule fixes.
2017-09-24 21:23:59 +01:00
Mike McQuaid
e862bcbc32
keg: cleanup aliases correctly.
...
This was missed when I was focused on cleaning up versioned aliases.
Fixes #2992 .
2017-08-05 18:03:04 +01:00
Mike McQuaid
1651647a3d
keg: correctly cleanup old aliases.
...
Cleanup old, versioned aliases and tap aliases folders when unlinking
or uninstalling a keg.
2017-07-28 11:41:12 +01:00
Markus Reiter
2d6ae61314
Re-revert "Fix operator spacing."
2017-06-02 19:22:05 +02:00
ilovezfs
197392b56d
Revert "Fix operator spacing."
2017-06-01 04:06:40 -07:00
Markus Reiter
d34ba7395b
Fix operator spacing.
2017-05-31 19:53:41 +02:00
Mike McQuaid
7a38bab333
Fixup all RuboCop warnings.
2017-05-29 18:43:18 +01:00
Markus Reiter
060af0a26a
Rename FormulaLock
to LockFile
.
2017-05-25 06:18:52 +02:00
Mike McQuaid
76f48d338e
keg: skip opt versioned aliases for devel/head.
...
These versioned aliases don’t correspond to the correct version if not
Installed from stable.
Fixes #2596 .
2017-05-09 15:10:57 +01:00
Mike McQuaid
82858176f0
keg: correctly remove alias symlinks.
...
Fixes #2427 .
2017-04-01 16:33:24 +01:00
Alex Dunn
00af5250f0
caveats: combine completion and function messages
...
Fixes https://github.com/Homebrew/homebrew-core/issues/10338 .
Closes #2287 .
Signed-off-by: Alex Dunn <dunn.alex@gmail.com>
2017-03-19 16:32:23 -07:00
Mike McQuaid
4991039809
keg: resolve rack aliases correctly.
...
Don't use the basename but instead use the Formulary logic for rack
formula resolution.
Fixes #2288 .
2017-03-08 08:51:41 +00:00
Naoto Kaneko
ccc9b2dc6d
Check for metafiles only in the root directory
2017-02-24 17:44:27 +09:00