Add HOMEBREW_NO_DEV_CMD_MESSAGE
This commit is contained in:
parent
9f15432742
commit
564a207bad
@ -93,7 +93,7 @@ begin
|
||||
internal_cmd ||= begin
|
||||
internal_dev_cmd = Commands.valid_internal_dev_cmd?(cmd)
|
||||
if internal_dev_cmd && !Homebrew::EnvConfig.developer?
|
||||
if ENV["HOMEBREW_DEV_CMD_RUN"].blank? && ENV["HOMEBREW_TEST"].blank?
|
||||
if ENV["HOMEBREW_DEV_CMD_RUN"].blank? && !Homebrew::EnvConfig.no_dev_cmd_message?
|
||||
opoo <<~MESSAGE
|
||||
#{Tty.bold}#{cmd}#{Tty.reset} is a developer command, so
|
||||
Homebrew's developer mode has been automatically turned on.
|
||||
|
||||
@ -645,7 +645,7 @@ elif [[ -f "${HOMEBREW_LIBRARY}/Homebrew/dev-cmd/${HOMEBREW_COMMAND}.sh" ]]
|
||||
then
|
||||
if [[ -z "${HOMEBREW_DEVELOPER}" ]]
|
||||
then
|
||||
if [[ -z "${HOMEBREW_DEV_CMD_RUN}" ]] && [[ -z "${HOMEBREW_TEST}" ]]
|
||||
if [[ -z "${HOMEBREW_DEV_CMD_RUN}" ]] && [[ -z "${HOMEBREW_NO_DEV_CMD_MESSAGE}" ]]
|
||||
then
|
||||
message="$(bold "${HOMEBREW_COMMAND}") is a developer command, so
|
||||
Homebrew's developer mode has been automatically turned on.
|
||||
|
||||
@ -87,7 +87,7 @@ module Homebrew
|
||||
ENV.delete(env)
|
||||
end
|
||||
|
||||
ENV["HOMEBREW_TEST"] = "1"
|
||||
ENV["HOMEBREW_NO_DEV_CMD_MESSAGE"] = "1"
|
||||
ENV["HOMEBREW_NO_ANALYTICS_THIS_RUN"] = "1"
|
||||
ENV["HOMEBREW_NO_COMPAT"] = "1" if args.no_compat?
|
||||
ENV["HOMEBREW_TEST_GENERIC_OS"] = "1" if args.generic?
|
||||
|
||||
@ -235,6 +235,10 @@ module Homebrew
|
||||
description: "If set, disable all use of legacy compatibility code.",
|
||||
boolean: true,
|
||||
},
|
||||
HOMEBREW_NO_DEV_CMD_MESSAGE: {
|
||||
description: "If set, do not display a warning message when running a developer command for the first time.",
|
||||
boolean: true,
|
||||
},
|
||||
HOMEBREW_NO_EMOJI: {
|
||||
description: "If set, do not print `HOMEBREW_INSTALL_BADGE` on a successful build." \
|
||||
"\n\n *Note:* Will only try to print emoji on OS X Lion or newer.",
|
||||
|
||||
@ -2027,6 +2027,9 @@ example, run `export HOMEBREW_NO_INSECURE_REDIRECT=1` rather than just
|
||||
- `HOMEBREW_NO_COMPAT`
|
||||
<br>If set, disable all use of legacy compatibility code.
|
||||
|
||||
- `HOMEBREW_NO_DEV_CMD_MESSAGE`
|
||||
<br>If set, do not display a warning message when running a developer command for the first time.
|
||||
|
||||
- `HOMEBREW_NO_EMOJI`
|
||||
<br>If set, do not print `HOMEBREW_INSTALL_BADGE` on a successful build.
|
||||
|
||||
|
||||
@ -2923,6 +2923,12 @@ If set, do not print text with colour added\.
|
||||
If set, disable all use of legacy compatibility code\.
|
||||
.
|
||||
.TP
|
||||
\fBHOMEBREW_NO_DEV_CMD_MESSAGE\fR
|
||||
.
|
||||
.br
|
||||
If set, do not display a warning message when running a developer command for the first time\.
|
||||
.
|
||||
.TP
|
||||
\fBHOMEBREW_NO_EMOJI\fR
|
||||
.
|
||||
.br
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user