Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
B
brew
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to JiHu GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
KMSCAKKSCFKA AKFACAMADCAS
brew
Commits
d4c8f833
Commit
d4c8f833
authored
9 years ago
by
Jack Nagel
Browse files
Options
Downloads
Patches
Plain Diff
Inline error message
parent
d85f2dab
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Library/Homebrew/global.rb
+0
-6
0 additions, 6 deletions
Library/Homebrew/global.rb
Library/brew.rb
+6
-1
6 additions, 1 deletion
Library/brew.rb
with
6 additions
and
7 deletions
Library/Homebrew/global.rb
+
0
−
6
View file @
d4c8f833
...
...
@@ -107,9 +107,3 @@ HOMEBREW_PULL_OR_COMMIT_URL_REGEX = %r[https://github\.com/([\w-]+)/homebrew(-[\
require
'compat'
unless
ARGV
.
include?
"--no-compat"
or
ENV
[
'HOMEBREW_NO_COMPAT'
]
ORIGINAL_PATHS
=
ENV
[
'PATH'
].
split
(
File
::
PATH_SEPARATOR
).
map
{
|
p
|
Pathname
.
new
(
p
).
expand_path
rescue
nil
}.
compact
.
freeze
SUDO_BAD_ERRMSG
=
<<-
EOS
.
undent
You can use brew with sudo, but only if the brew executable is owned by root.
However, this is both not recommended and completely unsupported so do so at
your own risk.
EOS
This diff is collapsed.
Click to expand it.
Library/brew.rb
+
6
−
1
View file @
d4c8f833
...
...
@@ -102,7 +102,12 @@ begin
if
sudo_check
.
include?
cmd
if
Process
.
uid
.
zero?
and
not
File
.
stat
(
HOMEBREW_BREW_FILE
).
uid
.
zero?
raise
"Cowardly refusing to `sudo brew
#{
cmd
}
`
\n
#{
SUDO_BAD_ERRMSG
}
"
raise
<<-
EOS
.
undent
Cowardly refusing to `sudo brew
#{
cmd
}
`
You can use brew with sudo, but only if the brew executable is owned by root.
However, this is both not recommended and completely unsupported so do so at
your own risk.
EOS
end
end
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment