Live data from Hacker News

Starship.rs: minimal, fast prompt for any shell

starship.rs

61–70 of 160 posts

Re: Starship.rs: minimal, fast prompt for any shell

#63
post #47

Since this is now a share your prompt thread, here's mine: https://github.com/rollcat/etc/tree/master/cmd/prompter It's quite portable (didn't test on Windows though); ~170 lines of Go; no dependencies outside of stdlib; calls no external commands; supports SSH, git, Docker, nix, and virtualenv; extremely simple to hack on.

points for the FAQ

Re: Starship.rs: minimal, fast prompt for any shell

#64

Is this like a competitor for power10k type stuff and zsh? What makes this "infinitely customizable" aside from being turing complete? I don't see anything but ... a prompt.

this is a visual performance comparison between spaceship and p10k: https://asciinema.org/a/253094

Re: Starship.rs: minimal, fast prompt for any shell

#65

Earlier quoted context omitted.

I think a huge amount of these prompts are just fiddling with things because people think they are clever, not because they are actually useful. My prompt for years has been: : ▶ I add the hostname if it’s an SSH session and change ▶ to # if I’m root because those are both important contexts that should be omnipresent, but aside from that, I haven’t felt like I’m missing anything at all. The CWD is in the window / ta…

Git information is extremely useful to me. I notice colleagues who don't have that tend to struggle using git on the command line and use git status nearly every other command (much as I tend to do when I'm remoting into a shell with a plain prompt). Python venvs are useful too if you have a shell for running the program and other shells that just happen to be within that directory.

Yes, having the git project displayed is useful.

To a lesser extent, I've done a few Java version migrations so it can be useful for the Java version to be printed so it's obvious if I've got the wrong JDK enabled. Python fell under this, but I don't think I'll have to worry about having one project be Python 2 while the others are 3 anymore.

Re: Starship.rs: minimal, fast prompt for any shell

#66
post #3

Starship's an excellent prompt replacement. I think it goes well with the fish shell: it's much nicer than the default, without requiring customisation.

Switching to Starship was actually what inspired me to also switch from Bash to Fish. Purely because of the transient prompt feature, which is not supported for Bash.

With the transient prompt, you can have things like Git or Kubernetes status on your “main prompt”, but without always printing them in the terminal for the commands you ran previously. It keeps the history much cleaner, and therefore more pleasant to scroll back up. I've also configured it to print the time when the commands were executed to the start of the lines.

Re: Starship.rs: minimal, fast prompt for any shell

#67
post #58

Am I the only one who is getting tired of "It's X in rust" type projects? It's making me dislike the community. Rust is not a user feature, it's an implementation detail.

Stating the technology makes you dislike the community. >.> Why are you on HN?

Re: Starship.rs: minimal, fast prompt for any shell

#68
I spend so little time relatively on my own machine’s terminal and even when I do I don’t want it to be totally different from the boxes I SSH into every day. That context switch would be frustrating. Nor do I have the desire to push for something like this to be installed on our fleet of servers.

Do the people who use this (along with terminal emulators that require you install things on the host to get the full power) just not use other machines and/or install stuff like this on them? Just seems odd to me personally but I’m interested in how others use it. Do you only use your own computer/terminal so it’s not an issue?

Re: Starship.rs: minimal, fast prompt for any shell

#70
post #58

Am I the only one who is getting tired of "It's X in rust" type projects? It's making me dislike the community. Rust is not a user feature, it's an implementation detail.

It's a marketing tactic, there is a non-insignificant people who will check out a project just because of Rust.
Post reply on HN