-
-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to change the start mark from '%' to another? #15
Comments
I have noticed that a lot of people want to change the prompt character. Give me a couple of days and I'll come up with a way to set it to whatever you like using a simple variable. |
The solution right now would be to have a custom left prompt in your
Give that a try. But I do mean to come up with a simpler way of changing the setting. |
thank you, please support config for changing the start mark at the beginning of the first line and second line, as well as git status sign, and auto-compare the git remote/local to show if we already push or need to pull like pure-prompt |
I'm not quite sure what you mean by that. Could you explain? Thanks! |
Hi @agkozak , I mean For now the '%' mark is on the second line, and there is no mark at the beginning of first line. So it would be great if you could make it easy to change the mark at the beginning of both line like the picture below: |
All right, @sandangel. You might like to try what I’ve now got on the
If you’d always like to see a lambda, you can just do the following. First, get rid of the
Play around with it a bit. You can even use colors, if you like, e.g.
Let me know if that addresses your needs. I’ll continue to work on your other requests. |
@sandangel I just added a feature to the
You can edit the items in that array to be the Git symbols you want: diverged, behind, ahead, new, deleted, modified, renamed, untracked. See if you like this feature. |
@agkozak wow thank you. This is how my current prompt looks like after customize (I'm using AGKOZAK_CUSTOM_PROMPT and master branch) AGKOZAK_CUSTOM_PROMPT=$'\n%F{yellow}λ %(!.%S%B.%B%F{green})%n%1v%(!.%b%s.%f%b) '
AGKOZAK_CUSTOM_PROMPT+='%B%F{blue}%2v%f%b'
AGKOZAK_CUSTOM_PROMPT+='%(3V.%F{yellow}%3v%f.)'
AGKOZAK_CUSTOM_PROMPT+=$' %(?..%B%F{red}(%?%)%f%b )'
AGKOZAK_CUSTOM_PROMPT+=$'%F{magenta}%*\n'
AGKOZAK_CUSTOM_PROMPT+='%(4V.:.%F{cyan}→%f) '
AGKOZAK_CUSTOM_RPROMPT=''
This prompt is still not possible in the develop branch right? Is it possible to only input only the colour that you want for the character instead of having to put between |
Nice prompt! You can accomplish a lot, but not all, of what you’ve got in your prompt using these features:
You’re very right to ask about a simpler way of specifying the color of the “prompt character” (such as % # : $ or →). I’m still working on it. I’d like to make it simple, but I imagine some people will want to have that character change color if they’re switching between insert and For now, I’m not going to include a setting for prepending a character such as your lambda to the prompt. If it were the only customization that you needed, you could always just put AGKOZAK_CUSTOM_PROMPT="%F{yellow}λ%f $PROMPT" at the end of your prompt setup. Likewise with the time of day — anyone who wants that might want it anywhere in the prompt — I can’t predict where they’ll want it, so I’ll just continue making I agree with you about getting information about the remote branch. It’s something I intend to add, and I like how pure does it, but implementing it will be a little complex. I support more systems than pure, and I have to use more than one asynchronous method to do that. Rest assured that I’ll continue to work towards having this feature. |
Thanks. I really appreciate that. I will try out the develop branch and let you know if I have more feedback. |
Any plans to merge it to main branch? |
@lfromanini Yes, I plan to do that in the next few days. Thanks for showing interest. Are you happy with the two new features ( |
@sandangel I just added a feature,
See what you think. The changes are on the |
@agkozak , I really like it a lot, specially the AGKOZAK_PROMPT_CHAR! I'd added a thumbs up on your message from 14 days ago because, IMHO, it's a killer feature. Thanks for the initiative and for sharing it with community, by the way. |
I notice the prompt startup is very slow. Could we call the prompt on zsh async hook precmd? |
@sandangel What operating system are you using? |
I'm using macos mojave. The prompt becomes slower when I enable the time prompt. |
@sandangel Try typing
and see what it says. |
@sandangel I don’t have access to a Mac myself, so I’ve never been able to benchmark the prompt for MacOS. The prompt should be using the If you want to try the other systems, try initiating
See if either of those seems considerably faster. But if the problem only arises when you add the time ( |
@agkozak hmm, I figured out it's because I'm using antigen. Switched to zplugins and lazy load the prompt and it's working well now.
Great!!, I will try it. Please notify me when you release that on master |
How would one change the vi mode char? Because my config currently is like this: _agkozak_vi_mode_indicator() {
case $KEYMAP in
vicmd) print -n '>' ;;
*) print -Pn '%(!.#.$)' ;;
esac
}
PROMPT='%(?..%B%F{red}(%?%)%f%b )'
PROMPT+='%(!.%S%B.%B%F{green})%n@%m%1v%(!.%b%s.%f%b):'
PROMPT+=$'%B%F{blue}%2v%f%b'
PROMPT+='$(_agkozak_vi_mode_indicator) '
RPROMPT='%(3V.%F{yellow}%3v%f.)' Which outputs my prompt char as |
@AGitBoy Nice prompt! What you've got will continue to work. For a while now, though, I've been using
with
which basically means "If The new |
All right. I've released v3.1 and it's now on the |
Thanks for all your work on this, it's my second favorite plugin, only behind fzf! That said, would it be possible to support emojis in |
@Brantron Glad to hear it! Thanks. I think emojis do work in Why don't you tell me what it is that you're trying to do and what isn't working? Try to include information about your operating system, terminal, font, etc. |
ahh, it's unrelated to this plugin, most emojis work but the ones that don't work I also can't echo :( thanks again for this plugin! |
I want to change the start mark from '%' to another mark (lambda mark), how could I do that
The text was updated successfully, but these errors were encountered: