diff --git a/README.md b/README.md index 2ff6ac4..ea842ab 100644 --- a/README.md +++ b/README.md @@ -247,67 +247,11 @@ more details. |`BULLETTRAIN_EXEC_TIME_BG`|`yellow`|Background color |`BULLETTRAIN_EXEC_TIME_FG`|`black`|Foreground color -## Tips - -### BULLETTRAIN_PROMPT_ORDER - -This gives ability to customize order and put user-defined segment on prompt. - -```bash -prompt_say_hello() { - prompt_segment yellow blue "hello" -} - -BULLETTRAIN_PROMPT_ORDER=( - git - dir - say_hello -) -``` - -![Prompt_Order](./img/tips/prompt_order.png) - -### BULLETTRAIN_GIT_PROMPT_CMD - -Allows you to specify custom git prompt command. This makes it possible to -change: - -![Git_Prompt_Origin](./img/tips/git_prompt_origin.png) - -into: - -![Git_Prompt_Command](./img/tips/git_prompt_command.png) - -with: - -``` bash -BULLETTRAIN_GIT_PROMPT_CMD=\${\$(git_prompt_info)//\\//\ \ } -``` - -Please note we need to delay variable expansion, so we have to escape all -**weird** character - *$*, *\*, *\*, etc. - -You can also use function to get more complex commands: - -``` bash -BULLETTRAIN_GIT_PROMPT_CMD="\$(custom_git_prompt)" - -custom_git_prompt() { - prompt=$(git_prompt_info) - prompt=${prompt//\//\ \ } - prompt=${prompt//_/\ } - echo ${prompt} -} -``` - -which gives: - -![Git_Prompt_Function](./img/tips/git_prompt_function.png) - ## Wiki - [FAQ](https://github.com/caiogondim/bullet-train-oh-my-zsh-theme/wiki/FAQ) - [Screenshots](https://github.com/caiogondim/bullet-train-oh-my-zsh-theme/wiki/Screenshots) +- [Tips](https://github.com/caiogondim/bullet-train-oh-my-zsh-theme/wiki/Tips) ## Contributors