A community Bash framework.
Go to file
Terminal for Life 921ea9ac76
Optimizations to reloader.bash (#1749)
* Optimized statement with REGEX by using `case`

REGEX is a great feature of BASH, but in this case it was energy
needlessly spent. A `case` statement suffices. Bring in REGEX when
you're going to make good use of it, otherwise it's just going to bog
down your code.

I also wanted to strip the ` || exit 1` on the last line, but I wasn't
sure if this file is meant to be sourced or not; if not, then exiting
like that is redundant because it will already exit with whichever
status the last command provides, unless `popd` specifically offers
unhelpful or no exit statuses.

* Optimize as before but with 2nd REGEX instance

This time is much like the last commit, so I won't repeat, but I will
say that you're using a double- or even triple-negative, which
obfuscates your goal. Where you were doing...

[ ! -n VAR ] &&

You were basically saying this convolution:

If it's true that it's not true that VAR is not empty.

Very confusing. Instead, I've opted for:

If it's true that Var is empty.

Makes immediate sense and is easier to parse, visually speaking.
2020-12-27 17:14:50 +02:00
.github Merge pull request #1727 from NoahGorny/add-issue-and-pr-templates 2020-12-18 11:48:02 +02:00
aliases/available feat(git-aliases): add checkout with username (fixes #1712) (#1732) 2020-12-13 22:58:01 +02:00
completion/available complete cleanup of the knife completion file 2020-12-07 18:06:27 +02:00
custom Fix bogus bash binary location 2012-04-17 00:24:58 -04:00
docs docs: Add lint_clean_files instructions 2020-12-20 23:29:01 +02:00
lib Improve bash-it version output 2020-10-27 20:01:50 +02:00
plugins/available Fix EOF 2020-10-29 19:57:14 +02:00
scripts Optimizations to reloader.bash (#1749) 2020-12-27 17:14:50 +02:00
template lib: Add BASH_IT_DEVELOPMENT_BRANCH variable 2020-10-13 14:42:02 +03:00
test Add option to append template to existing config (#1723) 2020-12-11 16:32:23 +02:00
test_lib Updated to bats-core v1.2.0 2020-04-29 16:03:30 +02:00
themes Merge pull request #1721 from NoahGorny/docs-remove-themes-readmes 2020-12-14 00:01:30 +02:00
.ackrc Ignore the enabled directories when running ack 2016-03-25 15:29:10 -05:00
.editorconfig Allow trailing spaces in md/rst files 2020-12-17 01:42:25 +02:00
.gitattributes Allow trailing spaces in md/rst files 2020-12-17 01:42:25 +02:00
.gitignore Completely ignore enabled-dir in root to support symlinking. 2019-07-22 16:42:29 +02:00
.gitmodules Updated to bats-core v1.2.0 2020-04-29 16:03:30 +02:00
.pre-commit-config.yaml Allow trailing spaces in md/rst files 2020-12-17 01:42:25 +02:00
.readthedocs.yml Add readthedocs configuration 2020-10-31 23:07:02 +02:00
.shellcheckrc Add simple shellcheckrc 2020-10-28 11:51:04 +02:00
bash_it.sh Added missing colon and space while loading custom files 2020-07-07 13:17:17 +02:00
clean_files.txt complete cleanup of the knife completion file 2020-12-07 18:06:27 +02:00
install.sh Merge pull request #1730 from NoahGorny/fix-1037 2020-12-16 20:08:06 +02:00
lint_clean_files.sh Explain Bash-it variable clearing in lint script 2020-11-05 08:30:33 -08:00
uninstall.sh Fixed some shellcheck warnings 2018-05-31 18:05:25 +02:00

docs/README.md

Bash-it

Build Status Docs Status Join the chat at https://webchat.freenode.net/?channel=#bash-it

Bash-it is a collection of community Bash commands and scripts for Bash 3.2+. (And a shameless ripoff of oh-my-zsh 😃)

Includes autocompletion, themes, aliases, custom functions, a few stolen pieces from Steve Losh, and more.

Bash-it provides a solid framework for using, developing and maintaining shell scripts and custom commands for your daily work. If you're using the Bourne Again Shell (Bash) regularly and have been looking for an easy way on how to keep all of these nice little scripts and aliases under control, then Bash-it is for you! Stop polluting your ~/bin directory and your .bashrc file, fork/clone Bash-it and start hacking away.

Installation

  1. Check out a clone of this repo to a location of your choice, such as git clone --depth=1 https://github.com/Bash-it/bash-it.git ~/.bash_it
  2. Run ~/.bash_it/install.sh

Thats it! 😃
You can check out more components of Bash-it, and customize it to your desire.
For more information, see detailed instructions here.

Contributing

Please take a look at the Contribution Guidelines before reporting a bug or providing a new feature.

The Development Guidelines have more information on some of the internal workings of Bash-it, please feel free to read through this page if you're interested in how Bash-it loads its components.

Contributors