Commit Graph

19 Commits (f2bc6c4e6d421765741bafa2752367177eb7f3cb)

Author SHA1 Message Date
John D Pell 1480cdfa34 completion/system: correctly load version when not linked
- Load the correct version of `bash-completion` even when not "linked".
2022-02-07 15:15:46 -08:00
John D Pell 5fab574bfd completion/system: `shfmt`
My apologies to future `git blame` hunters ♥
2022-01-08 08:33:16 -08:00
John D Pell e7c3263f12 completion/system: load earlier than other completions
I chose `325` so that it's still possible to deliberately place something *before* this component, if needed somehow.
2022-01-08 08:33:16 -08:00
John D Pell a375e7131e Remove executable bit 2021-09-18 22:26:27 -07:00
John D Pell feacd560b6 completion/system: update wording on shell version 2021-09-05 15:43:05 -07:00
John D Pell ecfcaba32e completion/system: accomodate multiple versions
For Homebrew, switch between v1 and v2 of bash-completion based on whether the running Bash shell is new enough to use v2.
2021-09-05 15:43:05 -07:00
John D Pell 0c412442f5 completion/system: give up hope
Give up and accept defeat that bash-completion can't reasonably be audited for unbound parameters. Wrap invocation with disabling strictness, and restore after if it was enabled.
2021-08-26 14:11:41 -07:00
John D Pell 65ef8e2e8b Use _bash_it_homebrew_check() in plugins, completions
Use new function `_bash_it_homebrew_check()` in existing plugins and completions which look for Homebrew.

Alsö, use `$OSTYPE` instead of calling external `uname` binary.
2021-08-22 12:48:48 -07:00
John D Pell 893c8dbb96 completion/system: support $BASH_COMPLETION
Bash-completion supports pre-defining $BASH_COMPLETION as the path to the main script, so use that if it's defined.

Alsö, don't load homebrew's completion if we've successfully loaded one already.
2021-08-08 23:08:39 -04:00
John D Pell 43947e2cbc completion/system: prefer direct invocation
Instead of using the profile.d version, just invoke the script. The profile.d script preemptively short-circuits if it thinks that bash-completions has already been loaded, which it does by using the $BASH_COMPLETION variable, which is expressly supported by upstream to specify the location of the script...so it will entirely be never loaded if this is set.
2021-08-08 23:08:39 -04:00
cornfeedhobo f40bfa80f1
system completion nitpicks
- General cleanup of system completion
- Use homebrew's completion loading script instead
- Deprecate completions covered by system
- Adjust load priority of brew to happen after system
2020-09-21 09:07:09 -05:00
Jason Al-Mansor 2c0bde3a22 fix path to use brew prefix env var 2019-04-26 11:12:53 -04:00
Jason Al-Mansor 15b3281445 adding env var for bash-completion@2 compatibility 2019-04-26 11:03:44 -04:00
Ahmad Assaf c5e8349f69 Fixing Error when starting Terminal after installing Bash-IT 2018-08-29 15:00:46 +01:00
Patrice Ferlet 8161e4e233 Add other bash completion importation for other distribution
Fedora import that script from /etc/bashrc script that can import /etc/profile.d/*.sh

See issue #849
2016-12-07 00:11:29 +01:00
George Wyatt 971f911101 Load bash-completion2 on macOS
This is required for projects completion, otherwise you get this error:
```
_init_completion: command not found
```
2016-11-25 13:51:25 +08:00
Nils Winkler 38bd3a3b99 Loading Homebrew Bash Completion if installed
In addition to the regular /etc/bash_completion, the one from Homebrew
is loaded when running on OS X, and when Homebrew is installed.

Also added the system completion to the default install options, since
this is a feature that's requested frequently.
2016-01-05 07:35:02 +01:00
was4444 25940111e8 fix wrong syntax 2016-01-04 18:42:40 +08:00
wxf 56fdb6333c support system completion 2016-01-01 15:46:53 +08:00