Commit Graph

3548 Commits (c852360a39e5ff3d4248a57781e95df4d6516788)

Author SHA1 Message Date
Noah Gorny c852360a39
Merge pull request #1977 from gaelicWizard/themes-SC2154-A
Themes: fix `shellcheck` (SC2154); Part A
2022-01-01 22:51:35 +02:00
Noah Gorny f534505357
Merge pull request #1969 from gaelicWizard/plugin-jekyll
Plugin/jekyll: lint and stuff
2022-01-01 22:43:36 +02:00
Noah Gorny 475952dbb9
Merge pull request #1928 from gaelicWizard/defaults
Refactor completion for `defaults` command
2022-01-01 16:46:14 +02:00
John D Pell 3fe9c8d6bc plugin/jekyll: try to shorten the flow
Alsö, use `pushd`/`popd` instead of `builtin cd`.

Alsö, SC2153
2021-12-27 12:22:42 -08:00
John D Pell e38eeefc5f plugin/jekyll: second `shellcheck` pass 2021-12-27 12:22:42 -08:00
John D Pell c0aad51afd main: move Jekyll stuff to plugins/jekyll
If the user doesn't load the Jekyll plugin, then don't load any Jeykll stuff.
2021-12-27 12:22:42 -08:00
John D Pell 1c3a7ffdb3 plugin/jekyll: `shfmt` && `shellcheck`
Use bashisms, remove suplerfous variable, use parameter default value replacement
2021-12-27 12:22:42 -08:00
John D Pell 2991aa66ca theme/powerline: SC2154, SC2248 2021-12-27 12:20:46 -08:00
John D Pell c323357067 theme/purity: SC2154
Handle all unbound parameters, even colors!
2021-12-27 12:20:46 -08:00
John D Pell e560e88814 theme/pure: SC2154
Handle all unbound parameters, even colors!
2021-12-27 12:20:46 -08:00
John D Pell 895102edeb theme/codeword: SC2154
Handle all unbound parameters, even colors!
2021-12-27 12:20:46 -08:00
John D Pell 4bc83d7940 theme/bira: SC2154
Handle all unbound parameters, even colors!
2021-12-27 12:20:46 -08:00
John D Pell 2c14a18483 theme/bakke: fix SC2154
Handle all unbound parameters, even colors!
2021-12-27 12:20:46 -08:00
John D Pell c769234350 theme/90210: fix SC2154
Handle all unbound parameters, even colors!
2021-12-27 12:20:46 -08:00
John D Pell 6a41dbc3f6 Add "bash-progcomp" from "https://github.com/gaelicWizard/bash-progcomp@v2.0.1"
git-vendor-name: bash-progcomp
git-vendor-dir: vendor/github.com/gaelicWizard/bash-progcomp
git-vendor-repository: https://github.com/gaelicWizard/bash-progcomp
git-vendor-ref: v2.0.1
2021-12-27 11:36:38 -08:00
John D Pell fdb50aec6b Remove defaults completion v1 2021-12-27 11:36:38 -08:00
Noah Gorny 84383cb46b
Merge pull request #1994 from Novite5/master
"pipenv --completion" is obsoleted
2021-12-18 21:52:29 +02:00
Noah Gorny 8edbdf9bbd
Merge pull request #1992 from davidpfarrell/dirs
plugin(dirs): remove shopt -s cdable_vars
2021-12-18 21:52:18 +02:00
Novite5 1065d98dbe
"pipenv --completion" is obsoleted
Reference: https://buildmedia.readthedocs.org/media/pdf/pipenv/latest/pipenv.pdf 4.2.18 Shell Completion
2021-12-12 18:11:21 +08:00
David Farrell 1bc56b1d8f
plugin(dirs): remove shopt -s cdable_vars 2021-12-02 13:42:29 -08:00
cornfeedhobo 1882f50aa1
Merge pull request #1982 from cornfeedhobo/align-history-plugins
Wholesale cleanup of all history plugins
2021-12-02 09:44:09 -06:00
cornfeedhobo 2c8ee40566
Fix linting errors that snuck in. 2021-12-02 09:14:01 -06:00
cornfeedhobo bdb5289660
Wholesale cleanup of all history plugins
- remove the use of redundant cite
- minor cleanups to history.plugin.bash
- set explicit load orders for history-search and history-substring-search
- add new plugin history-eternal
- replace superfluous trap for managing HISTTIMEFORMAT changes
2021-12-02 09:13:56 -06:00
Noah Gorny 036cf8ada0
Merge pull request #1987 from mikejamestx/dtml-scm_prompt
Themes: Fix doubletime_multiline scm_prompt
2021-11-29 23:59:24 +02:00
Mike James 1273504267 themes: fix doubletime_multiline scm_prompt
Replace doubletime_scm_prompt with scm_prompt.
2021-11-26 13:21:07 -08:00
Noah Gorny 8784ed2785
Merge pull request #1986 from ajeetdsouza/zoxide
plugin: add zoxide
2021-11-24 21:43:39 +02:00
Ajeet D'Souza a89f2f8f13 plugin: add zoxide 2021-11-24 16:49:46 +05:30
Noah Gorny 447c89aa0e
Merge pull request #1981 from william-richard/make-default-branch-match-exactly-main
Look for branches that are literally the word main
2021-11-16 20:09:22 +02:00
William Richard 2a23598873
Make the regex looking for the main branch match the entire line 2021-11-15 12:19:05 -05:00
Noah Gorny 7b4056fdf9
Merge pull request #1984 from NoahGorny/docs-pin-docutils
docs: Pin docutils to 0.17.1
2021-11-13 20:25:33 +02:00
Noah Gorny 1ff2497c9e docs: Pin docutils to 0.17.1
Seems like docutils 0.18 has some problems and it is breaking our docs
build
(https://issues.apache.org/jira/browse/FLINK-24662)

Lets use 0.17.1 for now.
2021-11-12 19:14:22 +02:00
Noah Gorny ab3b8b8f22
Merge pull request #1979 from gaelicWizard/preexec-histcontrol
preexec: work around upstream mangling of `$HISTCONTROL`
2021-11-01 23:25:02 +02:00
William Richard daaab1b73d
Use \s instead of \b
\b matches things like - and _, which is often used in branch names
2021-10-25 11:55:26 -04:00
William Richard 98bd0ae149
Use `/b` to find the default branch, instead of start/end of line 2021-10-25 11:35:19 -04:00
Noah Gorny c90a6283ef
Merge pull request #1976 from gaelicWizard/utilities
Use `_bash-it-egrep()`
2021-10-23 23:33:04 +03:00
William Richard a14d9cb6ea
Look for branches that are literally the word main
I have a repo with many other branches that contain the string `main`,
but our default branch is still master.  This grep was seeing those other branches
and deciding that my default branch was `main`.  This tighter regex
fixes that behavior for me.
2021-10-22 11:19:21 -04:00
John D Pell bdfb987f0c plugin/xterm: don't rely on `$1`
_bash-preexec_ passes the "current" command line as `$1`, but this is unreliable and we explicitly discourage it's use.

Use `$BASH_COMMAND` instead.
2021-10-20 15:50:15 -04:00
John D Pell 9ce199c251 preexec: set options before load
By setting `__bp_delay_install`, we avoid any immediate initialization at all. We then override two troublesome functions before calling `__bp_install_after_session_init()`.

The `__bp_install_after_session_init()` function doesn't enable the DEBUG trap, just sets `$PROMPT_COMMAND` to include `__bp_install()`, so the actual final `$PROMPT_COMMAND` is not finished, and DEBUG trap set, until after the first prompt is displayed.
2021-10-20 15:28:59 -04:00
John D Pell 00f5f2a62e Use `_bash-it-egrep()` 2021-10-18 22:08:56 -04:00
Noah Gorny 2d1bd82575
Merge pull request #1975 from krapshsa/krapshsa-patch-1
Fix save-and-reload-history command not found
2021-10-18 22:22:21 +03:00
Noah Gorny 5e3810ac96
Merge pull request #1973 from gaelicWizard/utilities
lib/utilities: minor improvements
2021-10-18 22:05:05 +03:00
Noah Gorny 5feebcc9d9
Merge pull request #1974 from zou000/patch-1
Fix home dir substitution
2021-10-18 21:59:59 +03:00
krapshsa b0e8729b0f
Fix save-and-reload-history command not found 2021-10-19 00:58:01 +08:00
John D Pell 253d1213e0 lib/utilities: new function `_bash-it-egrep()`
The existing function `_bash-it-grep()` is weird. New function `_bash-it-egrep()` just does the thing without requiring two subshells and manual invocation.
2021-10-18 09:14:32 -04:00
John D Pell b8ee63c67d lib/utilities: quote SC2295
Doesn't show up on my shellcheck 0.7.2, but does for NoahGorny!
2021-10-18 09:14:32 -04:00
John D Pell b986c39040 lib/utilities: XDG_CACHE_HOME
Use $XDG_CACHE_HOME environment constant instead of placing a tmp/cache folder inside the bash-it data repo. If not defined, fall back to current behavior.

This resolves Bash-It/Bash-It#1904.
2021-10-18 09:14:32 -04:00
Noah Gorny 7987e4bfcd
Merge pull request #1883 from seefood/ira/autosave-history-plml
Add history flushes on each command to the powerline themes
2021-10-17 19:51:56 +03:00
zou000 7911f770cf
use `\w` 2021-10-16 22:29:25 -07:00
zou000 bb3a51f742
Update powerline.base.bash 2021-10-16 20:24:07 -07:00
zou000 413d7a1326
Fix home dir substitution
See the discussions in 953e422bed (commitcomment-58148656) . Tested with bash 5.1 and  bash 3.2
2021-10-16 19:15:00 -07:00