Comments (4)
looks like it is impossible to do: http://stackoverflow.com/questions/16028904/bash-resolving-variables-in-literal-value-for-ps1, some variants exists if use PROMPT_COMMAND variable, but I failed to make them work.
from bash-git-prompt.
Fixed:
It is now possible to override PROMPT_START and PROMPT_END by exporting the variables GIT_PROMPT_START and GIT_PROMPT_END
from bash-git-prompt.
still a problem or I miss something, my "~/.bashrc":
export GIT_PROMPT_START="${White}${Time12a} ${Yellow}${PathShort}${ResetColor}"
export GIT_PROMPT_END=" $ "
source /home/rivanov/java/git-others/bash-git-prompt/gitprompt.sh
Detected:
[master|✔] $
Expected:
11:23 ~/java/git-others/bash-git-prompt [master|✚ 1] $
from bash-git-prompt.
You can't use the variables declared in the gitprompt.sh (like White or Time12a) because at the time you use them, they are not declared yet. You have to declare them before using it in GIT_PROMPT_START or GIT_PROMPT_END. Or you use the values directly.
from bash-git-prompt.
Related Issues (20)
- readarray: command not found HOT 2
- Discontinuation of the fish-shell features
- Line highlighting: useful when scrolling and I need to find my ex prompts HOT 1
- Superseded? HOT 1
- Looking for maintainers HOT 15
- would love new release versions that we can watch for as changes come out HOT 3
- Not starting automatically from within .bashrc HOT 6
- Sometimes "git pull" errors with "fatal: Cannot rebase onto multiple branches." but is fine immediately afterwards HOT 4
- Solarized_UserHost showing up as 'root@localhost #️ {ResetColor}' and keeping red color HOT 3
- zsh HOT 1
- brew update
- git clone https://github.com/magicmonty/bash-git-prompt.git ~/.bash-git-prompt --depth=1
- Unstaged type changes and deletions are misrecognized as staged changes
- Prompt shows "_LAST_COMMAND_INDICATOR_" when leaving git repo HOT 1
- origin/master : nombre entier attendu comme expression HOT 1
- working with multiple remotes HOT 2
- _LAST_COMMAND_INDICATOR_ not replaced when not in a git repo HOT 2
- _LAST_COMMAND_INDICATOR_ on standard user
- Is there a way to make bash-git-prompt skipping one or more repos?
- Displaying folder in non-git folders
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 bash-git-prompt.