Live data from Hacker News

Starship.rs: minimal, fast prompt for any shell

starship.rs

101–110 of 160 posts

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

#101
post #51

Earlier quoted context omitted.

It's probably a bell curve and you're only seeing the left side.

Huh? What here is a bell curve? What would be on the "right side" of the bell curve that invalidates the idea that git info in PS1 is useful?

https://s3-alpha.figma.com/hub/file/1263794301/resized/800x4...

Left: confused and no prompt

Middle: proficient and with prompt

Right: proficient and no prompt

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

#102
post #24

Earlier quoted context omitted.

I also can't understand the two-line prompt. I want my prompt to take as little space as possible.

I agree with the latter point. But I use xonsh as the shell and that has a prompt which can go on the last line of the terminal and does not get repeated each time, so when you scroll back you don't all the information each time. I use that for starship information and the prompt is just the return code p[lus a character.

Oh, that's a great feature, wish it were more widespread

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

#103

Earlier quoted context omitted.

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.

> Git information is extremely useful to me. I could see the case for that if it were accurate. But every implementation I’ve seen doesn’t give you accurate Git information. It gives you the status of the repo as it was when you last ran a command . If you are working on the repo in a separate editor window, then the Git information in your prompt is usually incorrect. Incorrect information is worse than no informati…

I can honestly say that has never once been a problem I have had, and I've had git information in the prompt for over 10 years.

Also how is "enter" less convenient than literally any other command that you'd still have to type and run to get up-to-date information in a command line?

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

#104
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.

I like that go and rust binaries are statically linked. This means that I can build an environment I like using these and bring them almost everywhere, wsl, Mac, Ubuntu, red hat, etc. For me, this is the feature of rust/go.

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

#105

Earlier quoted context omitted.

Who is "they"? Do you imagine all Rust devs as a hive mind?

> for part of the rust community. part is the important term here.

I still don't see your original point. Sounds like you have an axe to grind. I don't see anything negative in saying "written in Rust" or "written in OCaml" or "written in Haskell" or anything else.

Using a particular language signals a certain subset of qualities and broadcasting those helps people filter what they are interested in.

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

#107
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 not only though I don't understand why is this getting you "tired".

Rust has memory safety built in (unless one goes VERY out of their way to nullify it) which to many, myself included, is a selling point. F.ex. I wouldn't be interested in the userland tools rewrite if they weren't in Rust.

> Rust is not a user feature, it's an implementation detail.

It is that, yes, but not only that. Again, memory safety. And as another poster pointed out -- statically linked binaries. That helps a lot with certain deployments.

Also consider that HN might not be the place for you if mentioning implementation details are ticking you off. That's more or less how this forum started in the first place: people discussing implementation details.

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

#108
post #93

Earlier quoted context omitted.

I am cli/vim guy - that’s my daily tools. Starship is very stable and it is useful for me. The only problem I have experienced is with custom extension I wrote myself (problem was slowness not stability).

That's all well and good, but has nothing to do with my argument. If you need to invoke a program for every prompt, when the alternative is to just let the shell do it's thing, it's no longer "minimal", period.

Well, we are arguing about semantics. You say that minimal means that it must be functionally minimal. I say that minimal UX is valid meaning as well.

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

#109

That capability already exists in Zsh, doesn’t it? Why would I need a third-party addon to do this thing?

It's simpler to configure and extend, and also more likely gets support for more exotic information-sources. It's a dedicated tool for this specific job, so following the "Unix-philosophy". And probably more optimized for edge cases like big git-repos and stuff. And you can easily switch shells.

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

#110
post #32

The "minimal" part is a little funny. Historical minimal shell prompts: $ # % >

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…

The GIT status prompt is immensely useful. Not as useful, but still occasionally useful, are the prompts for language / tool versions. And how much time did the last command take. I make a regular use of that when I don't need sub-second timings.

If that makes me "thinking I am clever" then by all means, spend your life believing that. It increases my productivity though.

Post reply on HN