Comments (5)
Another potential option here: given it looks like detection is not really possible maybe these could just be output a single time regardless of how many formulae are installed/upgraded at the end of all installations?
from brew.
Looks like for detection if it has been run in the current shell could be by inspecting BASH_COMPLETION_VERSINFO
. Assuming there's similar vars for zsh
, fish
, etc.
from brew.
Looks like for detection if it has been run in the current shell could be by inspecting
BASH_COMPLETION_VERSINFO
. Assuming there's similar vars forzsh
,fish
, etc.
@jubr Can you investigate this more? If we can automatically detect if this message is redundant I agree it may make sense to remove these messages.
HOMEBREW_CAVEAT_COMPLETIONS
with future values likesuppress
,show
,suppress-when-detected-in-shell
.
Going from "no configuration" to "four different settings" feels excessive. Let's focus on the problem to be solved for now and we can figure out what's best based on what's e.g. possible from the shell.
from brew.
Looks like for detection if it has been run in the current shell could be by inspecting
BASH_COMPLETION_VERSINFO
I don't think that is available in bash-completion
(v1) for system bash
users. This has more installs than bash-completion@2
in last 90 days and last 365 days.
Some tricky parts for shell detection:
brew
is a bash script. Not sure if possible to see correspondingzsh
(e.g.fpath
/FPATH
/_comps
) andfish
(e.g.fish_complete_path
) variables.brew
sanitizes the environment. By the time caveats are printed, theBASH_*
variables have been removed from environment.
From quick glance, a suppress-when-detected-in-shell
feature wouldn't be possible other than maybe brew fish
(since we don't need variables there other than particular shell).
If so, the options would then be a full opt out flag or maybe some sort of show-once-per-formula if we could store info in tab.
from brew.
I just stumbled upon this issue and would like to express my opinion: as a Homebrew user, I really like when I brew install something
and see "zsh completion has been installed". I just really like shell completions. I think it's a good default to print information about installing completion files.
I agree with #2110 that "Caveats" is not maybe the best place for it, though.
from brew.
Related Issues (20)
- `env HOMEBREW_NO_AUTO_UPDATE=1 brew install imagemagick` fails on GitHub Actions macOS 13 runners due to attempted upgrades HOT 3
- Proper XDG_CONFIG_HOME usage HOT 6
- Last digit of formula version number can be omitted when upgrading HOT 4
- brew install mesa fails at link step on Fedora Silverblue (probably not a formula bug) HOT 7
- Error: undefined method `each_with_object' for nil:NilClass HOT 4
- Auto disable hints if already exists the environment variable HOT 8
- Allow checksum on unversioned URL HOT 11
- Allow macos 11 to be used HOT 1
- Allow formulae to set an env for their completion generation HOT 4
- Show disk space in info command HOT 3
- Fine-grained PATs do not work when used as $HOMEBREW_GITHUB_API_TOKEN HOT 3
- `brew upgrade -g` sometime will install old version app HOT 3
- `brew upgrade -g` sometime will install old version app
- @PizzaShift @ligi Hello.
- Support GitHub App installation access tokens HOT 2
- Command "brew update" shows "/dev/stdin: No such file or directory - /tmp/sh-thd-2853475760 (deleted) (Errno::ENOENT)" HOT 8
- How should we store installed cask information? HOT 18
- Integrating attestation verification into `brew install` (and `brew verify`) HOT 17
- `brew bump --open-pr` fails to fetch repology data HOT 5
- Add a RuboCop rule for sorting EnvConfig keys
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from brew.